diff options
author | Matthew Malcomson <matthew.malcomson@arm.com> | 2019-11-15 12:10:56 +0000 |
---|---|---|
committer | Matthew Malcomson <matmal01@gcc.gnu.org> | 2019-11-15 12:10:56 +0000 |
commit | 6239665976be7829cb973b4b59f7575d7079058e (patch) | |
tree | 8dbd3ba7dd436ede97a53b55f801e2307dbcf136 /gcc/passes.c | |
parent | 8916ba874dae00edc04face497360ce4eb3ea95b (diff) | |
download | gcc-6239665976be7829cb973b4b59f7575d7079058e.zip gcc-6239665976be7829cb973b4b59f7575d7079058e.tar.gz gcc-6239665976be7829cb973b4b59f7575d7079058e.tar.bz2 |
[mid-end][__RTL] Set global epilogue_completed in skip_pass
Set global epilogue_completed when skipping pro_and_epilogue pass
When compiling RTL functions marked to start at a pass after the reload
pass, `skip_pass` is used to mark the reload pass as having completed
since many patterns use the `reload_completed` variable to determine
whether to run or not.
Here we do the same for the `epilogue_completed` variable and the
pro_and_epilogue pass.
Also include a testcase that relies on the availability of a
define_split in the aarch64 backend that is conditioned on this
`epilogue_completed` variable.
regtest done on native aarch64
regtest done on native x64_86
gcc/ChangeLog:
2019-11-15 Matthew Malcomson <matthew.malcomson@arm.com>
* passes.c (skip_pass): Set epilogue_completed if skipping the
pro_and_epilogue pass.
gcc/testsuite/ChangeLog:
2019-11-15 Matthew Malcomson <matthew.malcomson@arm.com>
* gcc.dg/rtl/aarch64/test-epilogue-set.c: New test.
From-SVN: r278285
Diffstat (limited to 'gcc/passes.c')
-rw-r--r-- | gcc/passes.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/passes.c b/gcc/passes.c index b77356d..331570e 100644 --- a/gcc/passes.c +++ b/gcc/passes.c @@ -2400,6 +2400,11 @@ skip_pass (opt_pass *pass) if (strcmp (pass->name, "reload") == 0) reload_completed = 1; + /* Similar for pass "pro_and_epilogue" and the "epilogue_completed" global + variable. */ + if (strcmp (pass->name, "pro_and_epilogue") == 0) + epilogue_completed = 1; + /* The INSN_ADDRESSES vec is normally set up by shorten_branches; set it up for the benefit of passes that run after this. */ |