[llvm] 0db9383 - [RISCV] Simplify VPseudoAMOEI multiclass. NFC
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Thu Feb 18 12:41:00 PST 2021
Author: Craig Topper
Date: 2021-02-18T12:40:51-08:00
New Revision: 0db938312a06b8aa3b6c6c0272e7f28167bbd16a
URL: https://github.com/llvm/llvm-project/commit/0db938312a06b8aa3b6c6c0272e7f28167bbd16a
DIFF: https://github.com/llvm/llvm-project/commit/0db938312a06b8aa3b6c6c0272e7f28167bbd16a.diff
LOG: [RISCV] Simplify VPseudoAMOEI multiclass. NFC
lmul was already iterated in one of the loops. We don't need to recreate
it from a string.
Added:
Modified:
llvm/lib/Target/RISCV/RISCVInstrInfoVPseudos.td
Removed:
################################################################################
diff --git a/llvm/lib/Target/RISCV/RISCVInstrInfoVPseudos.td b/llvm/lib/Target/RISCV/RISCVInstrInfoVPseudos.td
index 2b4e9f952b477..4e3a261ba299c 100644
--- a/llvm/lib/Target/RISCV/RISCVInstrInfoVPseudos.td
+++ b/llvm/lib/Target/RISCV/RISCVInstrInfoVPseudos.td
@@ -997,12 +997,10 @@ multiclass VPseudoAMOEI<int eew> {
defvar octuple_emul = !srl(!mul(eew, octuple_lmul), shift_amount<sew>.val);
if !and(!ge(octuple_emul, 1), !le(octuple_emul, 64)) then {
defvar emulMX = octuple_to_str<octuple_emul>.ret;
- defvar lmulMX = octuple_to_str<octuple_lmul>.ret;
defvar emul= !cast<LMULInfo>("V_" # emulMX);
- defvar lmul = !cast<LMULInfo>("V_" # lmulMX);
let VLMul = lmul.value in {
- def "_WD_" # lmulMX # "_" # emulMX : VPseudoAMOWDNoMask<lmul.vrclass, emul.vrclass>;
- def "_WD_" # lmulMX # "_" # emulMX # "_MASK" : VPseudoAMOWDMask<lmul.vrclass, emul.vrclass>;
+ def "_WD_" # lmul.MX # "_" # emulMX : VPseudoAMOWDNoMask<lmul.vrclass, emul.vrclass>;
+ def "_WD_" # lmul.MX # "_" # emulMX # "_MASK" : VPseudoAMOWDMask<lmul.vrclass, emul.vrclass>;
}
}
}
More information about the llvm-commits
mailing list