[PATCH] D44700: [GlobalISel] Improving InstructionSelect's performance by reducing MatchTable

Quentin Colombet via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 23 14:01:40 PDT 2018


qcolombet accepted this revision.
qcolombet added a comment.
This revision is now accepted and ready to land.
Herald added a reviewer: javed.absar.

Hi Roman,

LGTM.
When you commit, please split the patch between, formatting NFC, fixing of wrong assertion :), adding switch opcode, adding switch types.

Cheers,
-Quentin



================
Comment at: include/llvm/CodeGen/GlobalISel/InstructionSelector.h:154
   GIM_CheckRegBankForClass,
+
   /// Check the operand matches a complex predicate
----------------
Formatting patches, in a different NFC patch please.


================
Comment at: include/llvm/CodeGen/GlobalISel/InstructionSelectorImpl.h:66
       return RejectAndGiveUp;
-    CurrentIdx = OnFailResumeAt.back();
-    OnFailResumeAt.pop_back();
+    CurrentIdx = OnFailResumeAt.pop_back_val();
     DEBUG_WITH_TYPE(TgtInstructionSelector::getName(),
----------------
Ditto


================
Comment at: include/llvm/CodeGen/GlobalISel/InstructionSelectorImpl.h:273
+      assert(State.MIs[InsnID]->getOpcode() == TargetOpcode::G_CONSTANT &&
+             "Expected G_CONSTANT");
       assert(Predicate > GIPFP_APInt_Invalid && "Expected a valid predicate");
----------------
Separate patch


Repository:
  rL LLVM

https://reviews.llvm.org/D44700





More information about the llvm-commits mailing list