Details
Details
- Reviewers
craig.topper pengfei RKSimon LiuChen3 skan
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Comment Actions
Did you consider other patches like this which will sort everything X86InstrAVX512.td after X86InstrSSE.td? The current sorting is done by the instruction name I think so VCVTSD2SIZrm_Int sorts before VCVTSD2SIrm_Int.
diff --git a/llvm/utils/TableGen/AsmMatcherEmitter.cpp b/llvm/utils/TableGen/AsmMatcherEmitter.cpp index 00bdd127e3c2..aaf90aa13272 100644 --- a/llvm/utils/TableGen/AsmMatcherEmitter.cpp +++ b/llvm/utils/TableGen/AsmMatcherEmitter.cpp @@ -636,7 +636,7 @@ struct MatchableInfo { if (RequiredFeatures.size() != RHS.RequiredFeatures.size()) return RequiredFeatures.size() > RHS.RequiredFeatures.size(); - return false; + return TheDef->getID() < RHS.TheDef->getID(); } /// couldMatchAmbiguouslyWith - Check whether this matchable could
Comment Actions
Great. I once seek to reorder the matching table, but I didn't realize "TheDef->getID()" can achieve it.
Comment Actions
Change back the order of checkAsmTiedOperandConstraints() and checkTargetMatchPredicate().
Comment Actions
The Match_NotPerfect mechanism slows down the match process. I think D111576 is better.
clang-format not found in user’s local PATH; not linting file.