From: Eric Botcazou Date: Sat, 23 Mar 2013 11:13:39 +0000 (+0000) Subject: calls.c (expand_call): Add missing guard to code handling return of non-BLKmode struc... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=66de4d7c91fca7d178f619761565fed9826cd05c;p=gcc.git calls.c (expand_call): Add missing guard to code handling return of non-BLKmode structures in MSB. * calls.c (expand_call): Add missing guard to code handling return of non-BLKmode structures in MSB. * function.c (expand_function_end): Likewise. From-SVN: r197003 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 1f04a1db8ec..ee8685b8e85 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2013-03-23 Eric Botcazou + + * calls.c (expand_call): Add missing guard to code handling return + of non-BLKmode structures in MSB. + * function.c (expand_function_end): Likewise. + 2013-03-23 Eric Botcazou * combine.c (try_combine): Adjust comment. Do not add the set of diff --git a/gcc/calls.c b/gcc/calls.c index dd034b40099..a585390be5f 100644 --- a/gcc/calls.c +++ b/gcc/calls.c @@ -3171,7 +3171,9 @@ expand_call (tree exp, rtx target, int ignore) group load/store machinery below. */ if (!structure_value_addr && !pcc_struct_value + && TYPE_MODE (rettype) != VOIDmode && TYPE_MODE (rettype) != BLKmode + && REG_P (valreg) && targetm.calls.return_in_msb (rettype)) { if (shift_return_value (TYPE_MODE (rettype), false, valreg)) diff --git a/gcc/function.c b/gcc/function.c index e673f21a57d..5419b88593d 100644 --- a/gcc/function.c +++ b/gcc/function.c @@ -5093,6 +5093,7 @@ expand_function_end (void) amount. BLKmode results are handled using the group load/store machinery. */ if (TYPE_MODE (TREE_TYPE (decl_result)) != BLKmode + && REG_P (real_decl_rtl) && targetm.calls.return_in_msb (TREE_TYPE (decl_result))) { emit_move_insn (gen_rtx_REG (GET_MODE (decl_rtl),