diff options
author | jules <jules@138bc75d-0d04-0410-961f-82ee72b054a4> | 2009-12-07 20:34:53 +0000 |
---|---|---|
committer | jules <jules@138bc75d-0d04-0410-961f-82ee72b054a4> | 2009-12-07 20:34:53 +0000 |
commit | 21c5864a06565425827394a1b52b8807042d7cd6 (patch) | |
tree | 5165a40594ed47e37e2264d17ac2f05dd914d583 /gcc/config | |
parent | 8f30f9f62c6c8a8dbce60d7df6ed079c7043cec3 (diff) | |
download | gcc-21c5864a06565425827394a1b52b8807042d7cd6.tar.gz |
gcc/
* config/arm/constraints.md (Ps, Pt): New constraint letters.
* config/arm/thumb2.md (*thumb2_addsi_short): Tighten constraints.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@155054 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/config')
-rw-r--r-- | gcc/config/arm/constraints.md | 11 | ||||
-rw-r--r-- | gcc/config/arm/thumb2.md | 6 |
2 files changed, 14 insertions, 3 deletions
diff --git a/gcc/config/arm/constraints.md b/gcc/config/arm/constraints.md index c40d695f0d8..cb75558984c 100644 --- a/gcc/config/arm/constraints.md +++ b/gcc/config/arm/constraints.md @@ -31,6 +31,7 @@ ;; The following multi-letter normal constraints have been used: ;; in ARM/Thumb-2 state: Da, Db, Dc, Dn, Dl, DL, Dv, Dy ;; in Thumb-1 state: Pa, Pb +;; in Thumb-2 state: Ps, Pt ;; The following memory constraints have been used: ;; in ARM/Thumb-2 state: Q, Ut, Uv, Uy, Un, Um, Us @@ -147,6 +148,16 @@ (match_test "TARGET_THUMB1 && ival >= -262 && ival <= 262 && (ival > 255 || ival < -255)"))) +(define_constraint "Ps" + "@internal In Thumb-2 state a constant in the range -255 to +255" + (and (match_code "const_int") + (match_test "TARGET_THUMB2 && ival >= -255 && ival <= 255"))) + +(define_constraint "Pt" + "@internal In Thumb-2 state a constant in the range -7 to +7" + (and (match_code "const_int") + (match_test "TARGET_THUMB2 && ival >= -7 && ival <= 7"))) + (define_constraint "G" "In ARM/Thumb-2 state a valid FPA immediate constant." (and (match_code "const_double") diff --git a/gcc/config/arm/thumb2.md b/gcc/config/arm/thumb2.md index cd317f1eae9..5e4eeedd1b6 100644 --- a/gcc/config/arm/thumb2.md +++ b/gcc/config/arm/thumb2.md @@ -1197,9 +1197,9 @@ ) (define_insn "*thumb2_addsi_short" - [(set (match_operand:SI 0 "low_register_operand" "=l") - (plus:SI (match_operand:SI 1 "low_register_operand" "l") - (match_operand:SI 2 "low_reg_or_int_operand" "lIL"))) + [(set (match_operand:SI 0 "low_register_operand" "=l,l") + (plus:SI (match_operand:SI 1 "low_register_operand" "l,0") + (match_operand:SI 2 "low_reg_or_int_operand" "lPt,Ps"))) (clobber (reg:CC CC_REGNUM))] "TARGET_THUMB2 && reload_completed" "* |