* [Bug middle-end/45234] [4.4/4.5/4.6 Regression] ICE in expand_call, at calls.c:2845 when passing aligned function argument from unaligned stack after alloca
[not found] <bug-45234-4@http.gcc.gnu.org/bugzilla/>
@ 2010-09-24 14:57 ` jakub at gcc dot gnu.org
2010-09-24 15:08 ` jakub at gcc dot gnu.org
` (6 subsequent siblings)
7 siblings, 0 replies; 18+ messages in thread
From: jakub at gcc dot gnu.org @ 2010-09-24 14:57 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45234
--- Comment #24 from Jakub Jelinek <jakub at gcc dot gnu.org> 2010-09-24 14:37:06 UTC ---
Author: jakub
Date: Fri Sep 24 14:37:02 2010
New Revision: 164593
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=164593
Log:
PR middle-end/45234
* rtl.h (enum global_rtl_index): Add
GR_VIRTUAL_PREFERRED_STACK_BOUNDARY.
(LAST_VIRTUAL_POINTER_REGISTER): Define.
(virtual_preferred_stack_boundary_rtx,
VIRTUAL_PREFERRED_STACK_BOUNDARY_REGNUM): Define.
(LAST_VIRTUAL_REGISTER): Increase by one.
(REGNO_PTR_FRAME_P): Use LAST_VIRTUAL_POINTER_REGISTER
instead of LAST_VIRTUAL_REGISTER.
* function.c (instantiate_new_reg): Handle
virtual_preferred_stack_boundary_rtx.
* emit-rtl.c (init_virtual_regs): Handle
VIRTUAL_PREFERRED_STACK_BOUNDARY_REGNUM.
(init_emit_regs): Initialize virtual_preferred_stack_boundary_rtx.
* explow.c (round_push): If crtl->preferred_stack_boundary
is smaller than MAX_SUPPORTED_STACK_ALIGNMENT, use
virtual_preferred_stack_boundary_rtx alignment instead of
crtl->preferred_stack_boundary alignment.
(allocate_dynamic_stack_space): Use CONST_INT_P and REG_P
macros. Never decrease crtl->preferred_stack_boundary,
use crtl->preferred_stack_boundary or MAX_SUPPORTED_STACK_ALIGNMENT
instead of PREFERRED_STACK_BOUNDARY. Don't modify
stack_pointer_delta in dynamic allocation, even when size
is constant.
(probe_stack_range, anti_adjust_stack_and_probe): Use CONST_INT_P
macro.
* print-rtl.c (print_rtx): Handle
VIRTUAL_PREFERRED_STACK_BOUNDARY_REGNUM.
* config/alpha/alpha.h (NONSTRICT_REG_OK_FP_BASE_P): Use
LAST_VIRTUAL_POINTER_REGISTER instead of LAST_VIRTUAL_REGISTER.
* config/frv/frv.c (frv_emit_movsi): Likewise.
* config/arm/arm.c (thumb1_legitimate_address_p): Likewise.
* config/rs6000/rs6000.c (virtual_stack_registers_memory_p):
Likewise.
* gcc.dg/torture/stackalign/alloca-6.c: New test.
* gcc.target/i386/pr45234.c: New test.
Revert:
2010-09-17 H.J. Lu <hongjiu.lu@intel.com>
PR middle-end/45234
* calls.c (expand_call): Make sure that all variable sized
adjustments are multiple of preferred stack boundary after
stack alignment.
Added:
trunk/gcc/testsuite/gcc.dg/torture/stackalign/alloca-6.c
trunk/gcc/testsuite/gcc.target/i386/pr45234.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/calls.c
trunk/gcc/config/alpha/alpha.h
trunk/gcc/config/arm/arm.c
trunk/gcc/config/frv/frv.c
trunk/gcc/config/rs6000/rs6000.c
trunk/gcc/emit-rtl.c
trunk/gcc/explow.c
trunk/gcc/function.c
trunk/gcc/print-rtl.c
trunk/gcc/rtl.h
trunk/gcc/testsuite/ChangeLog
--
Configure bugmail: http://gcc.gnu.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug middle-end/45234] [4.4/4.5/4.6 Regression] ICE in expand_call, at calls.c:2845 when passing aligned function argument from unaligned stack after alloca
[not found] <bug-45234-4@http.gcc.gnu.org/bugzilla/>
2010-09-24 14:57 ` [Bug middle-end/45234] [4.4/4.5/4.6 Regression] ICE in expand_call, at calls.c:2845 when passing aligned function argument from unaligned stack after alloca jakub at gcc dot gnu.org
@ 2010-09-24 15:08 ` jakub at gcc dot gnu.org
2010-09-24 15:11 ` jakub at gcc dot gnu.org
` (5 subsequent siblings)
7 siblings, 0 replies; 18+ messages in thread
From: jakub at gcc dot gnu.org @ 2010-09-24 15:08 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45234
--- Comment #25 from Jakub Jelinek <jakub at gcc dot gnu.org> 2010-09-24 15:02:06 UTC ---
Author: jakub
Date: Fri Sep 24 15:01:53 2010
New Revision: 164595
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=164595
Log:
Revert:
2010-09-17 H.J. Lu <hongjiu.lu@intel.com>
PR middle-end/45234
* calls.c (expand_call): Make sure that all variable sized
adjustments are multiple of preferred stack boundary after
stack alignment.
* gcc.dg/torture/stackalign/alloca-5.c: Remove.
Removed:
branches/gcc-4_5-branch/gcc/testsuite/gcc.dg/torture/stackalign/alloca-5.c
Modified:
branches/gcc-4_5-branch/gcc/ChangeLog
branches/gcc-4_5-branch/gcc/calls.c
branches/gcc-4_5-branch/gcc/testsuite/ChangeLog
--
Configure bugmail: http://gcc.gnu.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug middle-end/45234] [4.4/4.5/4.6 Regression] ICE in expand_call, at calls.c:2845 when passing aligned function argument from unaligned stack after alloca
[not found] <bug-45234-4@http.gcc.gnu.org/bugzilla/>
2010-09-24 14:57 ` [Bug middle-end/45234] [4.4/4.5/4.6 Regression] ICE in expand_call, at calls.c:2845 when passing aligned function argument from unaligned stack after alloca jakub at gcc dot gnu.org
2010-09-24 15:08 ` jakub at gcc dot gnu.org
@ 2010-09-24 15:11 ` jakub at gcc dot gnu.org
2010-09-24 15:33 ` [Bug middle-end/45234] [4.4/4.5 " jakub at gcc dot gnu.org
` (4 subsequent siblings)
7 siblings, 0 replies; 18+ messages in thread
From: jakub at gcc dot gnu.org @ 2010-09-24 15:11 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45234
--- Comment #26 from Jakub Jelinek <jakub at gcc dot gnu.org> 2010-09-24 15:07:40 UTC ---
Author: jakub
Date: Fri Sep 24 15:07:36 2010
New Revision: 164596
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=164596
Log:
Revert:
2010-09-17 H.J. Lu <hongjiu.lu@intel.com>
PR middle-end/45234
* calls.c (expand_call): Make sure that all variable sized
adjustments are multiple of preferred stack boundary after
stack alignment.
* gcc.dg/torture/stackalign/alloca-5.c: Remove.
Removed:
branches/gcc-4_4-branch/gcc/testsuite/gcc.dg/torture/stackalign/alloca-5.c
Modified:
branches/gcc-4_4-branch/gcc/ChangeLog
branches/gcc-4_4-branch/gcc/calls.c
branches/gcc-4_4-branch/gcc/testsuite/ChangeLog
--
Configure bugmail: http://gcc.gnu.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug middle-end/45234] [4.4/4.5 Regression] ICE in expand_call, at calls.c:2845 when passing aligned function argument from unaligned stack after alloca
[not found] <bug-45234-4@http.gcc.gnu.org/bugzilla/>
` (2 preceding siblings ...)
2010-09-24 15:11 ` jakub at gcc dot gnu.org
@ 2010-09-24 15:33 ` jakub at gcc dot gnu.org
2010-10-01 11:50 ` jakub at gcc dot gnu.org
` (3 subsequent siblings)
7 siblings, 0 replies; 18+ messages in thread
From: jakub at gcc dot gnu.org @ 2010-09-24 15:33 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45234
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Priority|P1 |P2
CC| |jakub at gcc dot gnu.org
Known to work| |4.6.0
Summary|[4.4/4.5/4.6 Regression] |[4.4/4.5 Regression] ICE in
|ICE in expand_call, at |expand_call, at
|calls.c:2845 when passing |calls.c:2845 when passing
|aligned function argument |aligned function argument
|from unaligned stack after |from unaligned stack after
|alloca |alloca
Known to fail|4.6.0 |
--- Comment #27 from Jakub Jelinek <jakub at gcc dot gnu.org> 2010-09-24 15:11:33 UTC ---
Should be fixed now on the trunk, on 4.4 and 4.5 I've so far reverted the old
patch, will wait some time before backporting the new patch.
--
Configure bugmail: http://gcc.gnu.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug middle-end/45234] [4.4/4.5 Regression] ICE in expand_call, at calls.c:2845 when passing aligned function argument from unaligned stack after alloca
[not found] <bug-45234-4@http.gcc.gnu.org/bugzilla/>
` (3 preceding siblings ...)
2010-09-24 15:33 ` [Bug middle-end/45234] [4.4/4.5 " jakub at gcc dot gnu.org
@ 2010-10-01 11:50 ` jakub at gcc dot gnu.org
2011-04-16 10:10 ` jakub at gcc dot gnu.org
` (2 subsequent siblings)
7 siblings, 0 replies; 18+ messages in thread
From: jakub at gcc dot gnu.org @ 2010-10-01 11:50 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45234
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|4.4.5 |4.4.6
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug middle-end/45234] [4.4/4.5 Regression] ICE in expand_call, at calls.c:2845 when passing aligned function argument from unaligned stack after alloca
[not found] <bug-45234-4@http.gcc.gnu.org/bugzilla/>
` (4 preceding siblings ...)
2010-10-01 11:50 ` jakub at gcc dot gnu.org
@ 2011-04-16 10:10 ` jakub at gcc dot gnu.org
2012-03-13 14:24 ` [Bug middle-end/45234] [4.5 " jakub at gcc dot gnu.org
2012-07-02 10:42 ` rguenth at gcc dot gnu.org
7 siblings, 0 replies; 18+ messages in thread
From: jakub at gcc dot gnu.org @ 2011-04-16 10:10 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45234
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|4.4.6 |4.4.7
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug middle-end/45234] [4.5 Regression] ICE in expand_call, at calls.c:2845 when passing aligned function argument from unaligned stack after alloca
[not found] <bug-45234-4@http.gcc.gnu.org/bugzilla/>
` (5 preceding siblings ...)
2011-04-16 10:10 ` jakub at gcc dot gnu.org
@ 2012-03-13 14:24 ` jakub at gcc dot gnu.org
2012-07-02 10:42 ` rguenth at gcc dot gnu.org
7 siblings, 0 replies; 18+ messages in thread
From: jakub at gcc dot gnu.org @ 2012-03-13 14:24 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45234
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|4.4.7 |4.5.4
--- Comment #28 from Jakub Jelinek <jakub at gcc dot gnu.org> 2012-03-13 12:47:00 UTC ---
4.4 branch is being closed, moving to 4.5.4 target.
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug middle-end/45234] [4.5 Regression] ICE in expand_call, at calls.c:2845 when passing aligned function argument from unaligned stack after alloca
[not found] <bug-45234-4@http.gcc.gnu.org/bugzilla/>
` (6 preceding siblings ...)
2012-03-13 14:24 ` [Bug middle-end/45234] [4.5 " jakub at gcc dot gnu.org
@ 2012-07-02 10:42 ` rguenth at gcc dot gnu.org
7 siblings, 0 replies; 18+ messages in thread
From: rguenth at gcc dot gnu.org @ 2012-07-02 10:42 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45234
Richard Guenther <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|REOPENED |RESOLVED
Resolution| |FIXED
Target Milestone|4.5.4 |4.6.0
--- Comment #29 from Richard Guenther <rguenth at gcc dot gnu.org> 2012-07-02 10:41:54 UTC ---
Fixed in 4.6.0, the 4.5 branch is being closed.
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug middle-end/45234] [4.4/4.5/4.6 Regression] ICE in expand_call, at calls.c:2845 when passing aligned function argument from unaligned stack after alloca
2010-08-08 21:04 [Bug c/45234] New: " truedfx at gentoo dot org
@ 2010-08-10 13:37 ` hjl dot tools at gmail dot com
2010-08-30 15:53 ` rguenth at gcc dot gnu dot org
` (8 subsequent siblings)
9 siblings, 0 replies; 18+ messages in thread
From: hjl dot tools at gmail dot com @ 2010-08-10 13:37 UTC (permalink / raw)
To: gcc-bugs
------- Comment #15 from hjl dot tools at gmail dot com 2010-08-10 13:36 -------
A patch is posted at
http://gcc.gnu.org/ml/gcc-patches/2010-08/msg00734.html
--
hjl dot tools at gmail dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
URL| |http://gcc.gnu.org/ml/gcc-
| |patches/2010-
| |08/msg00734.html
Component|target |middle-end
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45234
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug middle-end/45234] [4.4/4.5/4.6 Regression] ICE in expand_call, at calls.c:2845 when passing aligned function argument from unaligned stack after alloca
2010-08-08 21:04 [Bug c/45234] New: " truedfx at gentoo dot org
2010-08-10 13:37 ` [Bug middle-end/45234] [4.4/4.5/4.6 Regression] " hjl dot tools at gmail dot com
@ 2010-08-30 15:53 ` rguenth at gcc dot gnu dot org
2010-09-06 18:40 ` howarth at nitro dot med dot uc dot edu
` (7 subsequent siblings)
9 siblings, 0 replies; 18+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2010-08-30 15:53 UTC (permalink / raw)
To: gcc-bugs
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Priority|P3 |P2
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45234
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug middle-end/45234] [4.4/4.5/4.6 Regression] ICE in expand_call, at calls.c:2845 when passing aligned function argument from unaligned stack after alloca
2010-08-08 21:04 [Bug c/45234] New: " truedfx at gentoo dot org
2010-08-10 13:37 ` [Bug middle-end/45234] [4.4/4.5/4.6 Regression] " hjl dot tools at gmail dot com
2010-08-30 15:53 ` rguenth at gcc dot gnu dot org
@ 2010-09-06 18:40 ` howarth at nitro dot med dot uc dot edu
2010-09-17 18:01 ` hjl at gcc dot gnu dot org
` (6 subsequent siblings)
9 siblings, 0 replies; 18+ messages in thread
From: howarth at nitro dot med dot uc dot edu @ 2010-09-06 18:40 UTC (permalink / raw)
To: gcc-bugs
------- Comment #16 from howarth at nitro dot med dot uc dot edu 2010-09-06 18:40 -------
Still present for x86_64-unknown-gnu-linux with -m32 at r163927 when tested on
x86_64 Fedora 10
using the new gcc/gcc/testsuite/gcc.dg/torture/stackalign/alloca-5.c test case
only from gcc-pr45234-2.patch.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45234
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug middle-end/45234] [4.4/4.5/4.6 Regression] ICE in expand_call, at calls.c:2845 when passing aligned function argument from unaligned stack after alloca
2010-08-08 21:04 [Bug c/45234] New: " truedfx at gentoo dot org
` (2 preceding siblings ...)
2010-09-06 18:40 ` howarth at nitro dot med dot uc dot edu
@ 2010-09-17 18:01 ` hjl at gcc dot gnu dot org
2010-09-18 20:51 ` sezeroz at gmail dot com
` (5 subsequent siblings)
9 siblings, 0 replies; 18+ messages in thread
From: hjl at gcc dot gnu dot org @ 2010-09-17 18:01 UTC (permalink / raw)
To: gcc-bugs
------- Comment #17 from hjl at gcc dot gnu dot org 2010-09-17 18:00 -------
Subject: Bug 45234
Author: hjl
Date: Fri Sep 17 18:00:40 2010
New Revision: 164377
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=164377
Log:
Make sure that all variable sized adjustments are multiple of preferred
stack boundary after stack alignment.
gcc/
2010-09-17 H.J. Lu <hongjiu.lu@intel.com>
PR middle-end/45234
* calls.c (expand_call): Make sure that all variable sized
adjustments are multiple of preferred stack boundary after
stack alignment.
gcc/testsuite/
2010-09-17 H.J. Lu <hongjiu.lu@intel.com>
PR middle-end/45234
* gcc.dg/torture/stackalign/alloca-5.c: New.
Added:
trunk/gcc/testsuite/gcc.dg/torture/stackalign/alloca-5.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/calls.c
trunk/gcc/testsuite/ChangeLog
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45234
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug middle-end/45234] [4.4/4.5/4.6 Regression] ICE in expand_call, at calls.c:2845 when passing aligned function argument from unaligned stack after alloca
2010-08-08 21:04 [Bug c/45234] New: " truedfx at gentoo dot org
` (3 preceding siblings ...)
2010-09-17 18:01 ` hjl at gcc dot gnu dot org
@ 2010-09-18 20:51 ` sezeroz at gmail dot com
2010-09-20 20:33 ` hjl at gcc dot gnu dot org
` (4 subsequent siblings)
9 siblings, 0 replies; 18+ messages in thread
From: sezeroz at gmail dot com @ 2010-09-18 20:51 UTC (permalink / raw)
To: gcc-bugs
------- Comment #18 from sezeroz at gmail dot com 2010-09-18 20:51 -------
Are 4.4 and 4.5 going to be fixed?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45234
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug middle-end/45234] [4.4/4.5/4.6 Regression] ICE in expand_call, at calls.c:2845 when passing aligned function argument from unaligned stack after alloca
2010-08-08 21:04 [Bug c/45234] New: " truedfx at gentoo dot org
` (4 preceding siblings ...)
2010-09-18 20:51 ` sezeroz at gmail dot com
@ 2010-09-20 20:33 ` hjl at gcc dot gnu dot org
2010-09-20 20:39 ` hjl at gcc dot gnu dot org
` (3 subsequent siblings)
9 siblings, 0 replies; 18+ messages in thread
From: hjl at gcc dot gnu dot org @ 2010-09-20 20:33 UTC (permalink / raw)
To: gcc-bugs
------- Comment #19 from hjl at gcc dot gnu dot org 2010-09-20 20:32 -------
Subject: Bug 45234
Author: hjl
Date: Mon Sep 20 20:32:41 2010
New Revision: 164453
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=164453
Log:
Make sure that all variable sized adjustments are multiple of preferred
stack boundary after stack alignment.
gcc/
2010-09-20 H.J. Lu <hongjiu.lu@intel.com>
Backport from mainline
2010-09-17 H.J. Lu <hongjiu.lu@intel.com>
PR middle-end/45234
* calls.c (expand_call): Make sure that all variable sized
adjustments are multiple of preferred stack boundary after
stack alignment.
gcc/testsuite/
2010-09-20 H.J. Lu <hongjiu.lu@intel.com>
Backport from mainline
2010-09-17 H.J. Lu <hongjiu.lu@intel.com>
PR middle-end/45234
* gcc.dg/torture/stackalign/alloca-5.c: New.
Added:
branches/gcc-4_4-branch/gcc/testsuite/gcc.dg/torture/stackalign/alloca-5.c
Modified:
branches/gcc-4_4-branch/gcc/ChangeLog
branches/gcc-4_4-branch/gcc/calls.c
branches/gcc-4_4-branch/gcc/testsuite/ChangeLog
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45234
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug middle-end/45234] [4.4/4.5/4.6 Regression] ICE in expand_call, at calls.c:2845 when passing aligned function argument from unaligned stack after alloca
2010-08-08 21:04 [Bug c/45234] New: " truedfx at gentoo dot org
` (5 preceding siblings ...)
2010-09-20 20:33 ` hjl at gcc dot gnu dot org
@ 2010-09-20 20:39 ` hjl at gcc dot gnu dot org
2010-09-20 20:40 ` hjl dot tools at gmail dot com
` (2 subsequent siblings)
9 siblings, 0 replies; 18+ messages in thread
From: hjl at gcc dot gnu dot org @ 2010-09-20 20:39 UTC (permalink / raw)
To: gcc-bugs
------- Comment #20 from hjl at gcc dot gnu dot org 2010-09-20 20:39 -------
Subject: Bug 45234
Author: hjl
Date: Mon Sep 20 20:39:18 2010
New Revision: 164455
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=164455
Log:
Make sure that all variable sized adjustments are multiple of preferred
stack boundary after stack alignment.
gcc/
2010-09-20 H.J. Lu <hongjiu.lu@intel.com>
Backport from mainline
2010-09-17 H.J. Lu <hongjiu.lu@intel.com>
PR middle-end/45234
* calls.c (expand_call): Make sure that all variable sized
adjustments are multiple of preferred stack boundary after
stack alignment.
gcc/testsuite/
2010-09-20 H.J. Lu <hongjiu.lu@intel.com>
Backport from mainline
2010-09-17 H.J. Lu <hongjiu.lu@intel.com>
PR middle-end/45234
* gcc.dg/torture/stackalign/alloca-5.c: New.
Added:
branches/gcc-4_5-branch/gcc/testsuite/gcc.dg/torture/stackalign/alloca-5.c
Modified:
branches/gcc-4_5-branch/gcc/ChangeLog
branches/gcc-4_5-branch/gcc/calls.c
branches/gcc-4_5-branch/gcc/testsuite/ChangeLog
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45234
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug middle-end/45234] [4.4/4.5/4.6 Regression] ICE in expand_call, at calls.c:2845 when passing aligned function argument from unaligned stack after alloca
2010-08-08 21:04 [Bug c/45234] New: " truedfx at gentoo dot org
` (6 preceding siblings ...)
2010-09-20 20:39 ` hjl at gcc dot gnu dot org
@ 2010-09-20 20:40 ` hjl dot tools at gmail dot com
2010-09-22 17:24 ` jakub at gcc dot gnu dot org
2010-09-22 21:36 ` hjl dot tools at gmail dot com
9 siblings, 0 replies; 18+ messages in thread
From: hjl dot tools at gmail dot com @ 2010-09-20 20:40 UTC (permalink / raw)
To: gcc-bugs
------- Comment #21 from hjl dot tools at gmail dot com 2010-09-20 20:40 -------
Fixed.
--
hjl dot tools at gmail dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45234
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug middle-end/45234] [4.4/4.5/4.6 Regression] ICE in expand_call, at calls.c:2845 when passing aligned function argument from unaligned stack after alloca
2010-08-08 21:04 [Bug c/45234] New: " truedfx at gentoo dot org
` (7 preceding siblings ...)
2010-09-20 20:40 ` hjl dot tools at gmail dot com
@ 2010-09-22 17:24 ` jakub at gcc dot gnu dot org
2010-09-22 21:36 ` hjl dot tools at gmail dot com
9 siblings, 0 replies; 18+ messages in thread
From: jakub at gcc dot gnu dot org @ 2010-09-22 17:24 UTC (permalink / raw)
To: gcc-bugs
------- Comment #22 from jakub at gcc dot gnu dot org 2010-09-22 17:24 -------
The 4.5/4.4 backports of this patch break:
/* { dg-do compile } */
/* { dg-options "-march=i586" { target ilp32 } } */
struct S { union { double b[4]; } a[18]; } s, a[5];
void foo (struct S);
struct S bar (struct S, struct S *, struct S);
void
foo (struct S arg)
{
}
void
baz (void)
{
foo (bar (s, &a[1], a[2]));
}
(distilled from struct-layout-1.exp tests, many of them fail). Please either
fix soon, or revert the patch. I'd like to roll 4.4.5 RC1 soon, but with this
kind of regression it is not possible.
--
jakub at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |REOPENED
Priority|P2 |P1
Resolution|FIXED |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45234
^ permalink raw reply [flat|nested] 18+ messages in thread
* [Bug middle-end/45234] [4.4/4.5/4.6 Regression] ICE in expand_call, at calls.c:2845 when passing aligned function argument from unaligned stack after alloca
2010-08-08 21:04 [Bug c/45234] New: " truedfx at gentoo dot org
` (8 preceding siblings ...)
2010-09-22 17:24 ` jakub at gcc dot gnu dot org
@ 2010-09-22 21:36 ` hjl dot tools at gmail dot com
9 siblings, 0 replies; 18+ messages in thread
From: hjl dot tools at gmail dot com @ 2010-09-22 21:36 UTC (permalink / raw)
To: gcc-bugs
------- Comment #23 from hjl dot tools at gmail dot com 2010-09-22 21:36 -------
(In reply to comment #22)
> The 4.5/4.4 backports of this patch break:
> /* { dg-do compile } */
> /* { dg-options "-march=i586" { target ilp32 } } */
>
> struct S { union { double b[4]; } a[18]; } s, a[5];
> void foo (struct S);
> struct S bar (struct S, struct S *, struct S);
>
> void
> foo (struct S arg)
> {
> }
>
> void
> baz (void)
> {
> foo (bar (s, &a[1], a[2]));
> }
We are trying to adjust stacking when calling builtin functions. This patch
works for me:
index aef823f..0c7588a 100644
--- a/gcc/calls.c
+++ b/gcc/calls.c
@@ -2369,7 +2369,7 @@ expand_call (tree exp, rtx target, int ignore)
preferred_unit_stack_boundary = preferred_stack_boundary / BITS_PER_UNIT;
- if (SUPPORTS_STACK_ALIGNMENT)
+ if (SUPPORTS_STACK_ALIGNMENT && fndecl && !DECL_IS_BUILTIN (fndecl))
{
/* All variable sized adjustments must be multiple of preferred
stack boundary. Stack alignment may change preferred stack
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45234
^ permalink raw reply [flat|nested] 18+ messages in thread