aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorRichard Sandiford <richard.sandiford@arm.com>2019-07-08 06:20:55 +0000
committerRichard Sandiford <rsandifo@gcc.gnu.org>2019-07-08 06:20:55 +0000
commit7ef004023510d0c88e1a8bb718ee2848c1358ea4 (patch)
tree2d19a8ca1f83db5c8d5722de794b8f0b79d5886d /gcc
parent0b1949603c401f6ad07c0641b6db59efe3140c0e (diff)
downloadgcc-7ef004023510d0c88e1a8bb718ee2848c1358ea4.zip
gcc-7ef004023510d0c88e1a8bb718ee2848c1358ea4.tar.gz
gcc-7ef004023510d0c88e1a8bb718ee2848c1358ea4.tar.bz2
[riscv] Fix ambiguous .md attribute uses
This patch is part of a series that fixes ambiguous attribute uses in .md files, i.e. cases in which attributes didn't use <ITER:ATTR> to specify an iterator, and in which <ATTR> could have different values depending on the iterator chosen. No behavioural change -- produces the same code as before. 2019-07-08 Richard Sandiford <richard.sandiford@arm.com> gcc/ * config/riscv/pic.md (*local_pic_load_s<mode>) (*local_pic_load_u<mode>): Explicitly specify the mode iterator referenced by <mode>, giving... (*local_pic_load_s<SUBX:mode>, *local_pic_load_u<SUBX:mode>): ...these. * config/riscv/riscv.md (*sge<u>_<X:mode><GPR:mode>) (*slt<u>_<X:mode><GPR:mode>, *sle<u>_<X:mode><GPR:mode>): Explicitly use <X:MODE> for the mode attribute. From-SVN: r273191
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog10
-rw-r--r--gcc/config/riscv/pic.md4
-rw-r--r--gcc/config/riscv/riscv.md6
3 files changed, 15 insertions, 5 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 9f83f75..96ae53a 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,13 @@
+2019-07-08 Richard Sandiford <richard.sandiford@arm.com>
+
+ * config/riscv/pic.md (*local_pic_load_s<mode>)
+ (*local_pic_load_u<mode>): Explicitly specify the mode iterator
+ referenced by <mode>, giving...
+ (*local_pic_load_s<SUBX:mode>, *local_pic_load_u<SUBX:mode>): ...these.
+ * config/riscv/riscv.md (*sge<u>_<X:mode><GPR:mode>)
+ (*slt<u>_<X:mode><GPR:mode>, *sle<u>_<X:mode><GPR:mode>): Explicitly
+ use <X:MODE> for the mode attribute.
+
2019-07-07 Jeff Law <law@redhat.com>
PR tree-optimization/91090
diff --git a/gcc/config/riscv/pic.md b/gcc/config/riscv/pic.md
index da303e4..f16f054 100644
--- a/gcc/config/riscv/pic.md
+++ b/gcc/config/riscv/pic.md
@@ -29,14 +29,14 @@
"<default_load>\t%0,%1"
[(set (attr "length") (const_int 8))])
-(define_insn "*local_pic_load_s<mode>"
+(define_insn "*local_pic_load_s<SUBX:mode>"
[(set (match_operand:SUPERQI 0 "register_operand" "=r")
(sign_extend:SUPERQI (mem:SUBX (match_operand 1 "absolute_symbolic_operand" ""))))]
"USE_LOAD_ADDRESS_MACRO (operands[1])"
"<SUBX:load>\t%0,%1"
[(set (attr "length") (const_int 8))])
-(define_insn "*local_pic_load_u<mode>"
+(define_insn "*local_pic_load_u<SUBX:mode>"
[(set (match_operand:SUPERQI 0 "register_operand" "=r")
(zero_extend:SUPERQI (mem:SUBX (match_operand 1 "absolute_symbolic_operand" ""))))]
"USE_LOAD_ADDRESS_MACRO (operands[1])"
diff --git a/gcc/config/riscv/riscv.md b/gcc/config/riscv/riscv.md
index 309c109..0f46266 100644
--- a/gcc/config/riscv/riscv.md
+++ b/gcc/config/riscv/riscv.md
@@ -2054,7 +2054,7 @@
""
"slt%i2<u>\t%0,zero,%1"
[(set_attr "type" "slt")
- (set_attr "mode" "<MODE>")])
+ (set_attr "mode" "<X:MODE>")])
(define_insn "*slt<u>_<X:mode><GPR:mode>"
[(set (match_operand:GPR 0 "register_operand" "= r")
@@ -2063,7 +2063,7 @@
""
"slt%i2<u>\t%0,%1,%2"
[(set_attr "type" "slt")
- (set_attr "mode" "<MODE>")])
+ (set_attr "mode" "<X:MODE>")])
(define_insn "*sle<u>_<X:mode><GPR:mode>"
[(set (match_operand:GPR 0 "register_operand" "=r")
@@ -2075,7 +2075,7 @@
return "slt%i2<u>\t%0,%1,%2";
}
[(set_attr "type" "slt")
- (set_attr "mode" "<MODE>")])
+ (set_attr "mode" "<X:MODE>")])
;;
;; ....................