diff options
author | Joseph Myers <joseph@codesourcery.com> | 2011-11-29 23:37:06 +0000 |
---|---|---|
committer | Joseph Myers <jsm28@gcc.gnu.org> | 2011-11-29 23:37:06 +0000 |
commit | a4f71b01d1b274eedffc236b4823036142fa89b7 (patch) | |
tree | f3edde7f6d273183ea9cbcbd479858a503295ff4 | |
parent | b740cb6335fd36e5847f2abd3c890b7f14d1ef30 (diff) | |
download | gcc-a4f71b01d1b274eedffc236b4823036142fa89b7.zip gcc-a4f71b01d1b274eedffc236b4823036142fa89b7.tar.gz gcc-a4f71b01d1b274eedffc236b4823036142fa89b7.tar.bz2 |
* config/sh/sh.h (enum reg_class, REG_CLASS_NAMES)
(REG_CLASS_CONTENTS): Add NON_SP_REGS.
(REGCLASS_HAS_GENERAL_REG): Handle NON_SP_REGS.
* config/sh/constraints.md (u): New constraint.
From-SVN: r181825
-rw-r--r-- | gcc/ChangeLog | 7 | ||||
-rw-r--r-- | gcc/config/sh/constraints.md | 3 | ||||
-rw-r--r-- | gcc/config/sh/sh.h | 6 |
3 files changed, 15 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 587a627..fcd1390 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2011-11-29 Joseph Myers <joseph@codesourcery.com> + + * config/sh/sh.h (enum reg_class, REG_CLASS_NAMES) + (REG_CLASS_CONTENTS): Add NON_SP_REGS. + (REGCLASS_HAS_GENERAL_REG): Handle NON_SP_REGS. + * config/sh/constraints.md (u): New constraint. + 2011-11-29 Oleg Endo <oleg.endo@t-online.de> PR target/51337 diff --git a/gcc/config/sh/constraints.md b/gcc/config/sh/constraints.md index 40d0d0b..59e7de6 100644 --- a/gcc/config/sh/constraints.md +++ b/gcc/config/sh/constraints.md @@ -75,6 +75,9 @@ (define_register_constraint "t" "T_REGS" "T register.") +(define_register_constraint "u" "NON_SP_REGS" + "Non-stack-pointer register.") + (define_register_constraint "w" "FP0_REGS" "Floating-point register 0.") diff --git a/gcc/config/sh/sh.h b/gcc/config/sh/sh.h index 1b98745..8ab1f10 100644 --- a/gcc/config/sh/sh.h +++ b/gcc/config/sh/sh.h @@ -1059,6 +1059,7 @@ enum reg_class MAC_REGS, FPUL_REGS, SIBCALL_REGS, + NON_SP_REGS, GENERAL_REGS, FP0_REGS, FP_REGS, @@ -1084,6 +1085,7 @@ enum reg_class "MAC_REGS", \ "FPUL_REGS", \ "SIBCALL_REGS", \ + "NON_SP_REGS", \ "GENERAL_REGS", \ "FP0_REGS", \ "FP_REGS", \ @@ -1116,6 +1118,8 @@ enum reg_class { 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00400000 }, \ /* SIBCALL_REGS: Initialized in TARGET_CONDITIONAL_REGISTER_USAGE. */ \ { 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000 }, \ +/* NON_SP_REGS: */ \ + { 0xffff7fff, 0xffffffff, 0x00000000, 0x00000000, 0x03020000 }, \ /* GENERAL_REGS: */ \ { 0xffffffff, 0xffffffff, 0x00000000, 0x00000000, 0x03020000 }, \ /* FP0_REGS: */ \ @@ -2072,7 +2076,7 @@ struct sh_args { register information here is not used for SFmode. */ #define REGCLASS_HAS_GENERAL_REG(CLASS) \ - ((CLASS) == GENERAL_REGS || (CLASS) == R0_REGS \ + ((CLASS) == GENERAL_REGS || (CLASS) == R0_REGS || (CLASS) == NON_SP_REGS \ || (! TARGET_SHMEDIA && (CLASS) == SIBCALL_REGS)) #define REGCLASS_HAS_FP_REG(CLASS) \ |