Summary: | asm goto may leave stack pointer invalid | ||
---|---|---|---|
Product: | gcc | Reporter: | Richard Henderson <rth> |
Component: | rtl-optimization | Assignee: | Richard Henderson <rth> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | jakub |
Priority: | P2 | Keywords: | wrong-code |
Version: | 4.5.1 | ||
Target Milestone: | 4.5.2 | ||
Host: | Target: | ||
Build: | Known to work: | ||
Known to fail: | Last reconfirmed: | 2010-10-29 15:58:07 | |
Attachments: | Failing test case |
Forgot to mention the compilation flags: gcc -m32 --save-temps -Os -march=i486 -fomit-frame-pointer z.c Author: rth Date: Fri Oct 29 16:56:18 2010 New Revision: 166067 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=166067 Log: PR rtl-opt/46226 * stmt.c (expand_asm_operands): Call do_pending_stack_adjust for asm goto. Added: trunk/gcc/testsuite/gcc.dg/pr46226.c Modified: trunk/gcc/ChangeLog trunk/gcc/stmt.c Author: rth Date: Fri Oct 29 16:58:36 2010 New Revision: 166068 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=166068 Log: PR rtl-opt/46226 * stmt.c (expand_asm_operands): Call do_pending_stack_adjust for asm goto. Added: branches/gcc-4_5-branch/gcc/testsuite/gcc.dg/pr46226.c Modified: branches/gcc-4_5-branch/gcc/ChangeLog branches/gcc-4_5-branch/gcc/stmt.c Fixed. Jakub, I know that you've back-ported asm-goto to several redhat branches, but I don't recall which ones. Obviously the patch will need inclusion there too. Author: rth Date: Fri Oct 29 17:12:46 2010 New Revision: 166069 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=166069 Log: PR rtl-opt/46226 Move test case to x86 test directory. Added: trunk/gcc/testsuite/gcc.target/i386/pr46226.c - copied, changed from r166067, trunk/gcc/testsuite/gcc.dg/pr46226.c Removed: trunk/gcc/testsuite/gcc.dg/pr46226.c Author: rth Date: Fri Oct 29 17:16:11 2010 New Revision: 166070 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=166070 Log: PR rtl-opt/46226 Move test case to x86 test directory. Added: branches/gcc-4_5-branch/gcc/testsuite/gcc.target/i386/pr46226.c - copied, changed from r166068, branches/gcc-4_5-branch/gcc/testsuite/gcc.dg/pr46226.c Removed: branches/gcc-4_5-branch/gcc/testsuite/gcc.dg/pr46226.c |
Created attachment 22199 [details] Failing test case The following test case shows how do_pending_stack_adjust is not properly called before the new kind of control flow insn is emitted.