This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/34013] callee-save register value sometimes corrupted when __stkchk called
- From: "acn1 at cam dot ac dot uk" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 9 Nov 2007 22:56:05 -0000
- Subject: [Bug target/34013] callee-save register value sometimes corrupted when __stkchk called
- References: <bug-34013-7587@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #1 from acn1 at cam dot ac dot uk 2007-11-09 22:56 -------
Created an attachment (id=14522)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=14522&action=view)
patch to gcc/config/i386/i386.c
This tries to avoid saving regs before allocating the stack frame if the frame
will be bigh enough to need probes (whihc will be a call to __stkchk) when the
save_regs_using_mov option has been selected. With this you will not save the
one cycle in the prologue if your frame is large, but maybe you get the right
answers? My patch does this for all i386 targets and that may not be necessary
since the problem that bugs me only arises if TARGET_STACK_PROBE leads to
generation of a call instruction.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34013