------- Comment #1 from kkojima at gcc dot gnu dot org 2009-11-11 21:59 -------
All 4.x sh compilers fail with similar way. Looks only when unoptimized.
Does the patch below work for you?
--- ORIG/trunk/gcc/mode-switching.c 2009-02-21 09:26:24.000000000 +0900
+++ trunk/gcc/mode-switching.c 2009-11-11 11:03:04.000000000 +0900
@@ -325,7 +325,14 @@ create_pre_exit (int n_entities, int *en
else
break;
if (copy_start >= FIRST_PSEUDO_REGISTER)
- break;
+ {
+ if (!optimize)
+ {
+ last_insn = return_copy;
+ continue;
+ }
+ break;
+ }
copy_num
= hard_regno_nregs[copy_start][GET_MODE (copy_reg)];
BTW, I guess that __builtin_apply/__builtin_return may be a bit obsolete.
If my memory is correct, there was an argument on the list for dropping
them from the compiler.
--
kkojima at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |kkojima at gcc dot gnu dot
| |org
Status|UNCONFIRMED |NEW
Ever Confirmed|0 |1
Keywords| |ice-on-valid-code
Known to fail| |4.0.4 4.1.3 4.2.4 4.3.4
| |4.4.2 4.5.0
Known to work| |3.4.6
Priority|P3 |P4
Last reconfirmed|0000-00-00 00:00:00 |2009-11-11 21:59:45
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41993