diff options
author | uros <uros@138bc75d-0d04-0410-961f-82ee72b054a4> | 2015-07-17 06:32:58 +0000 |
---|---|---|
committer | uros <uros@138bc75d-0d04-0410-961f-82ee72b054a4> | 2015-07-17 06:32:58 +0000 |
commit | 2d298c9333c94da50b00fd6ee84fcc8bc822b8fe (patch) | |
tree | b66dd17af273533138afe41bc473424fd7487ddb /gcc/calls.c | |
parent | 53f12a4e59d7fa5f4c4d80450cd703d100f023b2 (diff) | |
download | gcc-2d298c9333c94da50b00fd6ee84fcc8bc822b8fe.tar.gz |
PR rtl-optimization/66891
* calls.c (expand_call): Wrap precompute_register_parameters with
NO_DEFER_POP/OK_DEFER_POP to prevent deferred pops.
testsuite/ChangeLog:
PR target/66891
* gcc.target/i386/pr66891.c: New test.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@225918 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/calls.c')
-rw-r--r-- | gcc/calls.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/gcc/calls.c b/gcc/calls.c index 2a297b0dc95..563672512be 100644 --- a/gcc/calls.c +++ b/gcc/calls.c @@ -3144,6 +3144,10 @@ expand_call (tree exp, rtx target, int ignore) compute_argument_addresses (args, argblock, num_actuals); + /* Stack is properly aligned, pops can't safely be deferred during + the evaluation of the arguments. */ + NO_DEFER_POP; + /* Precompute all register parameters. It isn't safe to compute anything once we have started filling any specific hard regs. TLS symbols sometimes need a call to resolve. Precompute @@ -3151,6 +3155,8 @@ expand_call (tree exp, rtx target, int ignore) to avoid unaligned stack in the called function. */ precompute_register_parameters (num_actuals, args, ®_parm_seen); + OK_DEFER_POP; + /* Perform stack alignment before the first push (the last arg). */ if (argblock == 0 && adjusted_args_size.constant > reg_parm_stack_space |