[PATCH] D35319: LSE Atomics reorg - Part I
Tim Northover via llvm-commits
llvm-commits at lists.llvm.org
Tue Aug 1 10:40:42 PDT 2017
OK, the bug is in these lines in AArch64InstrAtomics.td:
+ def : Pat<(!cast<SDNode>(op#"_"#size#"_monotonic") GPR64sp:$Rn, SrcRHS),
+ (!cast<Instruction>(inst#suffix) DstRHS, GPR64sp:$Rn)>;
+ def : Pat<(!cast<SDNode>(op#"_"#size#"_acquire") GPR64sp:$Rn, SrcRHS),
+ (!cast<Instruction>(inst#suffix) DstRHS, GPR64sp:$Rn)>;
+ def : Pat<(!cast<SDNode>(op#"_"#size#"_release") GPR64sp:$Rn, SrcRHS),
+ (!cast<Instruction>(inst#suffix) DstRHS, GPR64sp:$Rn)>;
+ def : Pat<(!cast<SDNode>(op#"_"#size#"_acq_rel") GPR64sp:$Rn, SrcRHS),
+ (!cast<Instruction>(inst#suffix) DstRHS, GPR64sp:$Rn)>;
+ def : Pat<(!cast<SDNode>(op#"_"#size#"_seq_cst") GPR64sp:$Rn, SrcRHS),
+ (!cast<Instruction>(inst#suffix) DstRHS, GPR64sp:$Rn)>;
When pasting together the destination instruction you need to add the
A/L modifiers to the non-monotonic cases. E.g.
'!cast<Instruction>(inst # "A" # suffix)' for the acquire operation.
Cheers.
Tim.
More information about the llvm-commits
mailing list