[PATCH] D77001: GlobalISel: Add accessor to known bits to CombinerHelper

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat Mar 28 17:12:10 PDT 2020


arsenm created this revision.
arsenm added reviewers: dsanders, paquette, aemerson, aditya_nandakumar.
Herald added subscribers: rovka, wdng.

I need to pass known bits to a target combine matcher (which for some
reason aren't methods in a subclass of CombinerHelper?)


https://reviews.llvm.org/D77001

Files:
  llvm/include/llvm/CodeGen/GlobalISel/CombinerHelper.h


Index: llvm/include/llvm/CodeGen/GlobalISel/CombinerHelper.h
===================================================================
--- llvm/include/llvm/CodeGen/GlobalISel/CombinerHelper.h
+++ llvm/include/llvm/CodeGen/GlobalISel/CombinerHelper.h
@@ -62,6 +62,10 @@
                  GISelKnownBits *KB = nullptr,
                  MachineDominatorTree *MDT = nullptr);
 
+  GISelKnownBits *getKnownBits() const {
+    return KB;
+  }
+
   /// MachineRegisterInfo::replaceRegWith() and inform the observer of the changes
   void replaceRegWith(MachineRegisterInfo &MRI, Register FromReg, Register ToReg) const;
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D77001.253386.patch
Type: text/x-patch
Size: 611 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200329/a61bb9d7/attachment-0001.bin>


More information about the llvm-commits mailing list