From patchwork Sat Apr 23 07:35:38 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [i386] : Fix PR target/48723 From: Uros Bizjak X-Patchwork-Id: 92607 Message-Id: To: Eric Botcazou Cc: gcc-patches@gcc.gnu.org Date: Sat, 23 Apr 2011 09:35:38 +0200 On Fri, Apr 22, 2011 at 11:38 PM, Eric Botcazou wrote: >> Attached one-liner fixes PR target/48723, ICE in >> ix86_expand_prologue() with -fstack-check + function returning struct, >> on corei7-avx. The problem was, that we forgot to update accounting >> info when ix86_adjust_stack_and_probe adjusted stack pointer (in this >> particular case, m->fs.sp_offset was set by stack realignment code for >> AVX 32byte stack alignment. > > Take a look at line 10165 of config/i386/i386.c. Uros. Index: i386.c =================================================================== --- i386.c (revision 172866) +++ i386.c (working copy) @@ -10149,7 +10149,7 @@ ix86_adjust_stack_and_probe (const HOST_ /* Even if the stack pointer isn't the CFA register, we need to correctly describe the adjustments made to it, in particular differentiate the frame-related ones from the frame-unrelated ones. */ - if (size > 0) + if (size != 0) { rtx expr = gen_rtx_SEQUENCE (VOIDmode, rtvec_alloc (2)); XVECEXP (expr, 0, 0)