Fix stack pointer handling in ms_hook_prologue functions for i386 target.
authorJeff Law <law@torsion.usersys.redhat.com>
Fri, 6 Nov 2020 22:38:00 +0000 (17:38 -0500)
committerJeff Law <law@torsion.usersys.redhat.com>
Fri, 6 Nov 2020 22:38:00 +0000 (17:38 -0500)
commit659ba632e440280e8d61e1ae870e917765db5ae5
treee26a7bc6f985ac3236c89b7d1d5252cde0094fa0
parente5502ae72f784470019de5850017ad0c87ffacef
Fix stack pointer handling in ms_hook_prologue functions for i386 target.

gcc/
PR target/91489
* config/i386/i386.md (simple_return): Also check
for ms_hook_prologue function attribute.
* config/i386/i386.c (ix86_can_use_return_insn_p):
Also check for ms_hook_prologue function attribute.
* config/i386/i386-protos.h (ix86_function_ms_hook_prologue): Declare.

gcc/testsuite
PR target/91489
* gcc.target/i386/ms_hook_prologue.c: Expand testcase
to reproduce PR target/91489 issue.
gcc/config/i386/i386-protos.h
gcc/config/i386/i386.c
gcc/config/i386/i386.md
gcc/testsuite/gcc.target/i386/ms_hook_prologue.c