PR/27458 highlights that the MIPS backend does not have well formed
MIR for atomic operations (among other errors).
This patch adds expands and corrects the LL/SC descriptions and uses
for MIPS(64).
Paths
| Differential D19719
[mips][atomics] Fix atomic instruction descriptions and uses. ClosedPublic Authored by sdardis on Apr 29 2016, 5:03 AM.
Details
Summary PR/27458 highlights that the MIPS backend does not have well formed This patch adds expands and corrects the LL/SC descriptions and uses
Diff Detail Event Timelinedsanders edited edge metadata. dsanders added inline comments.
This revision now requires changes to proceed.Apr 29 2016, 9:41 AM
dsanders edited edge metadata. Comment ActionsLGTM
This revision is now accepted and ready to land.May 17 2016, 3:15 AM sdardis edited edge metadata. Comment ActionsAddressed comments. Precommit testing caught using PTR_32/PTR_64 were InsnPredicates which clobber the ISA_MIPS* family of predicates. I've changed it to GPRPredicates, that ok? Comment Actions
It will need to be a new sub-list. Putting it in GPRPredicates will clobber GPR_32/GPR_64. Comment Actions Remove PTR_32 / PTR_64 and used IsPTR32bit / IsPTR64bit like we use InMicroMipsMode rather than having AdditionalPredicates and YetMorePredicates. Thanks, dsanders edited edge metadata. Comment Actions
AdditionalPredicates is just for predicates we haven't got around to sorting out yet so we shouldn't add new predicates to it. We should also be removing any uses of Predicates or AdditionalPredicates where they remain. The intent of the PredicateControl class was to have a sub-list for each mutually exclusive group of predicates with the final Predicates field being the concatenation of all the sub-lists. This allowed us to override specific groups of predicates which fixed a recurring problem where careless use of a 'let Predicates = ...' statement would accidentally remove predicates from an instruction. If we've got a new mutually exclusive group then we should add a new sub-list to PredicateControl. This revision now requires changes to proceed.Jun 6 2016, 7:40 AM dsanders edited edge metadata. Comment ActionsLGTM with PTRPredicates in the listconcat and a couple nits.
This revision is now accepted and ready to land.Jun 13 2016, 3:00 AM Comment Actions
Thanks for trying. Hopefully we'll figure out why tablegen can't see that an instruction with FeaturePTR64Bit can't conflict with an instruction with !FeaturePTR64Bit.
Revision Contents
Diff 55574 lib/Target/Mips/Mips32r6InstrInfo.td
lib/Target/Mips/Mips64InstrInfo.td
lib/Target/Mips/Mips64r6InstrInfo.td
lib/Target/Mips/MipsISelLowering.cpp
lib/Target/Mips/MipsInstrInfo.td
test/CodeGen/Mips/atomic.ll
|
I think this and the other mayLoad/mayStores are redundant. According to tablegen's comments, both mayLoad and mayStore default to false (unless the pattern contains a load or store).