diff options
author | rsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4> | 2011-11-27 10:09:15 +0000 |
---|---|---|
committer | rsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4> | 2011-11-27 10:09:15 +0000 |
commit | 9fbe215970e0761ad1caa16657085dbb4ddb8a6d (patch) | |
tree | 550c92021f891ad0b45cc382f700d0d14027acd1 /gcc/hard-reg-set.h | |
parent | 75a3db74ca989a33534bcaf88215a09741e13929 (diff) | |
download | gcc-9fbe215970e0761ad1caa16657085dbb4ddb8a6d.tar.gz |
gcc/
* hard-reg-set.h (target_hard_regs): Add x_accessible_reg_set
and x_operand_reg_set.
(accessible_reg_set, operand_reg_set): New macros.
* reginfo.c (init_reg_sets): Initialize accessible_reg_set and
operand_reg_set.
(saved_accessible_reg_set, saved_operand_reg_set): New variables.
(save_register_info): Save them.
(restore_register_info): Restore them.
(init_reg_sets_1): Limit operand_reg_set to accessible_reg_set.
Remove NO_REGS registers from operand_reg_set. Treat members
of operand_reg_set as fixed.
* recog.c (general_operand): Check operand_reg_set rather than
NO_REGS.
(register_operand, nonmemory_operand): Likewise.
* varasm.c (make_decl_rtl): Always use DECL_MODE as the mode of
register variables. Check accessible_reg_set and operand_reg_set.
* config/mips/mips.c (mips_conditional_register_usage): Remove
inaccessible register from accessible_reg_set, rather than just
making them fixed.
gcc/testsuite/
* gcc.target/mips/mips.exp (mips-dg-options): Make -mno-dsp
imply -mno-dspr2.
* gcc.target/mips/no-dsp-1.c: New test.
* gcc.target/mips/soft-float-1.c: Likewise.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@181760 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/hard-reg-set.h')
-rw-r--r-- | gcc/hard-reg-set.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/gcc/hard-reg-set.h b/gcc/hard-reg-set.h index 9cd7c8bb962..9823a5b3441 100644 --- a/gcc/hard-reg-set.h +++ b/gcc/hard-reg-set.h @@ -583,6 +583,13 @@ hard_reg_set_iter_next (hard_reg_set_iterator *iter, unsigned *regno) extern char global_regs[FIRST_PSEUDO_REGISTER]; struct target_hard_regs { + /* The set of registers that actually exist on the current target. */ + HARD_REG_SET x_accessible_reg_set; + + /* The set of registers that should be considered to be register + operands. It is a subset of x_accessible_reg_set. */ + HARD_REG_SET x_operand_reg_set; + /* Indexed by hard register number, contains 1 for registers that are fixed use (stack pointer, pc, frame pointer, etc.;. These are the registers that cannot be used to allocate @@ -659,6 +666,10 @@ extern struct target_hard_regs *this_target_hard_regs; #define this_target_hard_regs (&default_target_hard_regs) #endif +#define accessible_reg_set \ + (this_target_hard_regs->x_accessible_reg_set) +#define operand_reg_set \ + (this_target_hard_regs->x_operand_reg_set) #define fixed_regs \ (this_target_hard_regs->x_fixed_regs) #define fixed_reg_set \ |