diff options
author | amacleod <amacleod@138bc75d-0d04-0410-961f-82ee72b054a4> | 2001-08-01 21:40:43 +0000 |
---|---|---|
committer | amacleod <amacleod@138bc75d-0d04-0410-961f-82ee72b054a4> | 2001-08-01 21:40:43 +0000 |
commit | d2d242b43cc22ff4b9a45cbd0527334f51b1d335 (patch) | |
tree | 12aceb7d22a94c9c2c37a7ffda9fa08b77c49f3b /gcc/regclass.c | |
parent | db8c5fb53bd223a419ef202e2216c35863e1d5da (diff) | |
download | gcc-d2d242b43cc22ff4b9a45cbd0527334f51b1d335.tar.gz |
2001-08-01 Andrew MacLeod <amacleod@redhat.com>
* regclass.c (call_really_used_regs): New array for registers which
are actually used by a call.
(init_reg_sets_1): Initialize regs_invalidated_by_call with the
new array.
(fix_register): Set call_really_used too.
* config/ia64/ia64.h (CALL_REALLY_USED_REGISTERS): Initialize.
* doc/tm.texi (CALL_REALLY_USED_REGISTERS): Document.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@44558 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/regclass.c')
-rw-r--r-- | gcc/regclass.c | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/gcc/regclass.c b/gcc/regclass.c index b16a677d805..9d1fe55b4b5 100644 --- a/gcc/regclass.c +++ b/gcc/regclass.c @@ -94,6 +94,18 @@ HARD_REG_SET losing_caller_save_reg_set; /* Data for initializing the above. */ static char initial_call_used_regs[] = CALL_USED_REGISTERS; + +/* This is much like call_used_regs, except it doesn't have to + be a superset of FIXED_REGISTERS. This vector indicates + what is really call clobbered, and is used when defining + regs_invalidated_by_call. */ + +char call_really_used_regs[] = +#ifdef CALL_REALLY_USED_REGISTERS + CALL_REALLY_USED_REGISTERS; +#else + CALL_USED_REGISTERS; +#endif /* Indexed by hard register number, contains 1 for registers that are fixed use or call used registers that cannot hold quantities across @@ -464,7 +476,7 @@ init_reg_sets_1 () else if (i == PIC_OFFSET_TABLE_REGNUM && flag_pic) ; #endif - else if (call_used_regs[i] || global_regs[i]) + else if (call_really_used_regs[i] || global_regs[i]) SET_HARD_REG_BIT (regs_invalidated_by_call, i); } @@ -747,6 +759,8 @@ fix_register (name, fixed, call_used) { fixed_regs[i] = fixed; call_used_regs[i] = call_used; + if (fixed == 0) + call_really_used_regs[i] = call_used; } } else |