* [Bug bootstrap/45206] [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc
2010-08-06 6:20 [Bug bootstrap/45206] New: [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc ebotcazou at gcc dot gnu dot org
@ 2010-08-06 6:21 ` ebotcazou at gcc dot gnu dot org
2010-08-06 11:06 ` rguenth at gcc dot gnu dot org
` (11 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: ebotcazou at gcc dot gnu dot org @ 2010-08-06 6:21 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from ebotcazou at gcc dot gnu dot org 2010-08-06 06:21 -------
Created an attachment (id=21420)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=21420&action=view)
Preprocessed file.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45206
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug bootstrap/45206] [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc
2010-08-06 6:20 [Bug bootstrap/45206] New: [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc ebotcazou at gcc dot gnu dot org
2010-08-06 6:21 ` [Bug bootstrap/45206] " ebotcazou at gcc dot gnu dot org
@ 2010-08-06 11:06 ` rguenth at gcc dot gnu dot org
2010-08-07 7:10 ` ebotcazou at gcc dot gnu dot org
` (10 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2010-08-06 11:06 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from rguenth at gcc dot gnu dot org 2010-08-06 11:06 -------
Confirmed.
struct _Unwind_Context { void *ra; };
void _Unwind_RaiseException(void)
{
struct _Unwind_Context this_context, cur_context;
long offset = uw_install_context_1 ((&this_context), (&cur_context));
void *handler = __builtin_frob_return_addr ((&cur_context)->ra);
__builtin_eh_return (offset, handler);
}
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |rth at gcc dot gnu dot org
Status|UNCONFIRMED |NEW
Ever Confirmed|0 |1
Last reconfirmed|0000-00-00 00:00:00 |2010-08-06 11:06:16
date| |
Target Milestone|--- |4.6.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45206
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug bootstrap/45206] [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc
2010-08-06 6:20 [Bug bootstrap/45206] New: [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc ebotcazou at gcc dot gnu dot org
2010-08-06 6:21 ` [Bug bootstrap/45206] " ebotcazou at gcc dot gnu dot org
2010-08-06 11:06 ` rguenth at gcc dot gnu dot org
@ 2010-08-07 7:10 ` ebotcazou at gcc dot gnu dot org
2010-08-08 15:15 ` kargl at gcc dot gnu dot org
` (9 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: ebotcazou at gcc dot gnu dot org @ 2010-08-07 7:10 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from ebotcazou at gcc dot gnu dot org 2010-08-07 07:09 -------
*** Bug 45222 has been marked as a duplicate of this bug. ***
--
ebotcazou at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |kargl at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45206
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug bootstrap/45206] [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc
2010-08-06 6:20 [Bug bootstrap/45206] New: [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc ebotcazou at gcc dot gnu dot org
` (2 preceding siblings ...)
2010-08-07 7:10 ` ebotcazou at gcc dot gnu dot org
@ 2010-08-08 15:15 ` kargl at gcc dot gnu dot org
2010-08-10 2:54 ` kargl at gcc dot gnu dot org
` (8 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: kargl at gcc dot gnu dot org @ 2010-08-08 15:15 UTC (permalink / raw)
To: gcc-bugs
------- Comment #4 from kargl at gcc dot gnu dot org 2010-08-08 15:15 -------
Change severity to blocker.
--
kargl at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Severity|critical |blocker
Priority|P3 |P2
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45206
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug bootstrap/45206] [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc
2010-08-06 6:20 [Bug bootstrap/45206] New: [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc ebotcazou at gcc dot gnu dot org
` (3 preceding siblings ...)
2010-08-08 15:15 ` kargl at gcc dot gnu dot org
@ 2010-08-10 2:54 ` kargl at gcc dot gnu dot org
2010-08-10 5:49 ` ebotcazou at gcc dot gnu dot org
` (7 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: kargl at gcc dot gnu dot org @ 2010-08-10 2:54 UTC (permalink / raw)
To: gcc-bugs
------- Comment #5 from kargl at gcc dot gnu dot org 2010-08-10 02:54 -------
Does anyone know which combination of recent commits
is causing this problem? I've tried individually backing
out several of the likely offenders, but I still can't
bootstrap. So, I'm guessing that I need to back out
some set of commits.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45206
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug bootstrap/45206] [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc
2010-08-06 6:20 [Bug bootstrap/45206] New: [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc ebotcazou at gcc dot gnu dot org
` (4 preceding siblings ...)
2010-08-10 2:54 ` kargl at gcc dot gnu dot org
@ 2010-08-10 5:49 ` ebotcazou at gcc dot gnu dot org
2010-08-11 3:48 ` sgk at troutmask dot apl dot washington dot edu
` (6 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: ebotcazou at gcc dot gnu dot org @ 2010-08-10 5:49 UTC (permalink / raw)
To: gcc-bugs
------- Comment #6 from ebotcazou at gcc dot gnu dot org 2010-08-10 05:49 -------
> Does anyone know which combination of recent commits is causing this problem?
The set of RTH's patches. Configure --with-tune=i686 to work around it.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45206
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug bootstrap/45206] [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc
2010-08-06 6:20 [Bug bootstrap/45206] New: [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc ebotcazou at gcc dot gnu dot org
` (5 preceding siblings ...)
2010-08-10 5:49 ` ebotcazou at gcc dot gnu dot org
@ 2010-08-11 3:48 ` sgk at troutmask dot apl dot washington dot edu
2010-08-14 14:01 ` [Bug target/45206] [4.6 regression] ICE on __builtin_eh_return at -Os ebotcazou at gcc dot gnu dot org
` (5 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: sgk at troutmask dot apl dot washington dot edu @ 2010-08-11 3:48 UTC (permalink / raw)
To: gcc-bugs
------- Comment #7 from sgk at troutmask dot apl dot washington dot edu 2010-08-11 03:48 -------
Subject: Re: [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc
On Tue, Aug 10, 2010 at 05:49:40AM -0000, ebotcazou at gcc dot gnu dot org
wrote:
> > Does anyone know which combination of recent commits is causing this problem?
>
> The set of RTH's patches. Configure --with-tune=i686 to work around it.
>
Thanks, Eric. The --with-tune=i686 has me back in the
hacking business.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45206
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug target/45206] [4.6 regression] ICE on __builtin_eh_return at -Os
2010-08-06 6:20 [Bug bootstrap/45206] New: [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc ebotcazou at gcc dot gnu dot org
` (6 preceding siblings ...)
2010-08-11 3:48 ` sgk at troutmask dot apl dot washington dot edu
@ 2010-08-14 14:01 ` ebotcazou at gcc dot gnu dot org
2010-08-14 22:23 ` hjl dot tools at gmail dot com
` (4 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: ebotcazou at gcc dot gnu dot org @ 2010-08-14 14:01 UTC (permalink / raw)
To: gcc-bugs
------- Comment #8 from ebotcazou at gcc dot gnu dot org 2010-08-14 14:01 -------
Recategorizing after:
2010-08-12 H.J. Lu <hongjiu.lu@intel.com>
Uros Bizjak <ubizjak@gmail.com>
* config.gcc: Handle --enable-frame-pointer.
* configure.ac: Add --enable-frame-pointer.
* configure: Regenerated.
* config/i386/i386.c (USE_IX86_FRAME_POINTER): Default to 0.
(override_options): If not configured with --enable-frame-pointer,
enable -fomit-frame-pointer (but not for TARGET_MACHO or when
optimizing for size), -fasynchronous-unwind-tables and
-maccumulate-outgoing-args by default.
The option -Os (or -mno-accumulate-outgoing-args) is now needed:
eric@new-host:~/gnat/gnat-head/native32> gcc/xgcc -Bgcc -S pr45206.c -Os
pr45206.c: In function '_Unwind_RaiseException':
pr45206.c:8:1: internal compiler error: in ix86_expand_epilogue, at
config/i386/i386.c:10177
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.
--
ebotcazou at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Severity|blocker |major
Component|bootstrap |target
GCC build triplet|i586-*-* |ix86-*-*
GCC host triplet|i586-*-* |ix86-*-*
GCC target triplet|i586-*-* |ix86-*-*
Last reconfirmed|2010-08-06 11:06:16 |2010-08-14 14:01:27
date| |
Summary|[4.6 regression] ICE in |[4.6 regression] ICE on
|ix86_expand_epilogue |__builtin_eh_return at -Os
|compiling libgcc |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45206
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug target/45206] [4.6 regression] ICE on __builtin_eh_return at -Os
2010-08-06 6:20 [Bug bootstrap/45206] New: [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc ebotcazou at gcc dot gnu dot org
` (7 preceding siblings ...)
2010-08-14 14:01 ` [Bug target/45206] [4.6 regression] ICE on __builtin_eh_return at -Os ebotcazou at gcc dot gnu dot org
@ 2010-08-14 22:23 ` hjl dot tools at gmail dot com
2010-09-07 9:25 ` ubizjak at gmail dot com
` (3 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: hjl dot tools at gmail dot com @ 2010-08-14 22:23 UTC (permalink / raw)
To: gcc-bugs
------- Comment #9 from hjl dot tools at gmail dot com 2010-08-14 22:23 -------
assert is too strong as shown in the testcase.
This patch works for me:
--
diff --git a/gcc/config/i386/i386.c b/gcc/config/i386/i386.c
index b925122..863c9bf 100644
--- a/gcc/config/i386/i386.c
+++ b/gcc/config/i386/i386.c
@@ -10030,7 +10030,11 @@ ix86_expand_epilogue (int style)
rtx t;
if (frame.nregs)
- ix86_emit_restore_regs_using_mov (frame.reg_save_offset, style == 2);
+ {
+ ix86_emit_restore_regs_using_mov (frame.reg_save_offset,
+ style == 2);
+ m->fs.sp_valid = true;
+ }
/* eh_return epilogues need %ecx added to the stack pointer. */
if (style == 2)
--
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45206
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug target/45206] [4.6 regression] ICE on __builtin_eh_return at -Os
2010-08-06 6:20 [Bug bootstrap/45206] New: [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc ebotcazou at gcc dot gnu dot org
` (8 preceding siblings ...)
2010-08-14 22:23 ` hjl dot tools at gmail dot com
@ 2010-09-07 9:25 ` ubizjak at gmail dot com
2010-09-07 14:42 ` ubizjak at gmail dot com
` (2 subsequent siblings)
12 siblings, 0 replies; 14+ messages in thread
From: ubizjak at gmail dot com @ 2010-09-07 9:25 UTC (permalink / raw)
To: gcc-bugs
------- Comment #10 from ubizjak at gmail dot com 2010-09-07 09:25 -------
We just calculated SP in the code following the comment:
"/* eh_return epilogues need %ecx added to the stack pointer. */"
So, stack pointer should be valid at the end.
I'm testing following patch:
Index: i386.c
===================================================================
--- i386.c (revision 163940)
+++ i386.c (working copy)
@@ -10118,6 +10118,7 @@ ix86_expand_epilogue (int style)
}
}
m->fs.sp_offset = UNITS_PER_WORD;
+ m->fs.sp_valid = true;
}
}
else
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45206
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug target/45206] [4.6 regression] ICE on __builtin_eh_return at -Os
2010-08-06 6:20 [Bug bootstrap/45206] New: [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc ebotcazou at gcc dot gnu dot org
` (9 preceding siblings ...)
2010-09-07 9:25 ` ubizjak at gmail dot com
@ 2010-09-07 14:42 ` ubizjak at gmail dot com
2010-09-07 15:40 ` uros at gcc dot gnu dot org
2010-09-07 15:42 ` ubizjak at gmail dot com
12 siblings, 0 replies; 14+ messages in thread
From: ubizjak at gmail dot com @ 2010-09-07 14:42 UTC (permalink / raw)
To: gcc-bugs
------- Comment #11 from ubizjak at gmail dot com 2010-09-07 14:38 -------
Patch at [1].
[1] http://gcc.gnu.org/ml/gcc-patches/2010-09/msg00563.html
--
ubizjak at gmail dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|unassigned at gcc dot gnu |ubizjak at gmail dot com
|dot org |
URL| |http://gcc.gnu.org/ml/gcc-
| |patches/2010-
| |09/msg00563.html
Status|NEW |ASSIGNED
Last reconfirmed|2010-08-14 14:01:27 |2010-09-07 14:38:00
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45206
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug target/45206] [4.6 regression] ICE on __builtin_eh_return at -Os
2010-08-06 6:20 [Bug bootstrap/45206] New: [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc ebotcazou at gcc dot gnu dot org
` (10 preceding siblings ...)
2010-09-07 14:42 ` ubizjak at gmail dot com
@ 2010-09-07 15:40 ` uros at gcc dot gnu dot org
2010-09-07 15:42 ` ubizjak at gmail dot com
12 siblings, 0 replies; 14+ messages in thread
From: uros at gcc dot gnu dot org @ 2010-09-07 15:40 UTC (permalink / raw)
To: gcc-bugs
------- Comment #12 from uros at gcc dot gnu dot org 2010-09-07 15:39 -------
Subject: Bug 45206
Author: uros
Date: Tue Sep 7 15:38:59 2010
New Revision: 163955
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=163955
Log:
PR target/45206
* config/i386/i386.c (ix86_expand_epilogue): Mark SP valid after
eh_return fixup sequence.
testsuite/ChangeLog:
PR target/45206
* gcc.target/i386/pr45206.c: New test.
Added:
trunk/gcc/testsuite/gcc.target/i386/pr45206.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/config/i386/i386.c
trunk/gcc/testsuite/ChangeLog
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45206
^ permalink raw reply [flat|nested] 14+ messages in thread
* [Bug target/45206] [4.6 regression] ICE on __builtin_eh_return at -Os
2010-08-06 6:20 [Bug bootstrap/45206] New: [4.6 regression] ICE in ix86_expand_epilogue compiling libgcc ebotcazou at gcc dot gnu dot org
` (11 preceding siblings ...)
2010-09-07 15:40 ` uros at gcc dot gnu dot org
@ 2010-09-07 15:42 ` ubizjak at gmail dot com
12 siblings, 0 replies; 14+ messages in thread
From: ubizjak at gmail dot com @ 2010-09-07 15:42 UTC (permalink / raw)
To: gcc-bugs
------- Comment #13 from ubizjak at gmail dot com 2010-09-07 15:42 -------
Fixed.
--
ubizjak at gmail dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45206
^ permalink raw reply [flat|nested] 14+ messages in thread