diff options
author | Qing Zhao <qing.zhao@oracle.com> | 2022-04-01 16:09:43 +0000 |
---|---|---|
committer | Qing Zhao <qing.zhao@oracle.com> | 2022-04-01 16:09:43 +0000 |
commit | 31933f4f788b6cd64cbb7ee42076997f6d0fe212 (patch) | |
tree | 5daa89e8f0c580f945687dc4a47f4eb9d1e7032e /gcc/fold-const.cc | |
parent | 413187b0b3c873333253838e4afbf8463b288b59 (diff) | |
download | gcc-31933f4f788b6cd64cbb7ee42076997f6d0fe212.zip gcc-31933f4f788b6cd64cbb7ee42076997f6d0fe212.tar.gz gcc-31933f4f788b6cd64cbb7ee42076997f6d0fe212.tar.bz2 |
Add an assertion: the zeroed_hardregs set is a subset of all call used regs.
We should make sure that the hard register set that is actually cleared by
the target hook zero_call_used_regs should be a subset of all call used
registers.
At the same time, update documentation for the target hook
TARGET_ZERO_CALL_USED_REGS.
This new assertion identified a bug in the i386 implemenation, which
incorrectly set the zeroed_hardregs for stack registers. Fixed this bug
in i386 implementation.
gcc/ChangeLog:
2022-04-01 Qing Zhao <qing.zhao@oracle.com>
* config/i386/i386.cc (zero_all_st_registers): Return the value of
num_of_st.
(ix86_zero_call_used_regs): Update zeroed_hardregs set according to
the return value of zero_all_st_registers.
* doc/tm.texi: Update the documentation of TARGET_ZERO_CALL_USED_REGS.
* function.cc (gen_call_used_regs_seq): Add an assertion.
* target.def: Update the documentation of TARGET_ZERO_CALL_USED_REGS.
Diffstat (limited to 'gcc/fold-const.cc')
0 files changed, 0 insertions, 0 deletions