[PATCH] D32278: [globalisel][tablegen] Import rules containing intrinsic_wo_chain.

Ahmed Bougacha via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 20 10:31:29 PDT 2017


ab added inline comments.


================
Comment at: utils/TableGen/GlobalISelEmitter.cpp:1355
+    Init *SrcChildInit = SrcChild->getLeafValue();
+    if (IntInit *SrcChildIntInit = dyn_cast<IntInit>(SrcChildInit)) {
+      OM.addPredicate<IntOperandMatcher>(SrcChildIntInit->getValue());
----------------
This seems very lax:
- it's not only accepting intrinsic IDs, but also any oddly-typed immediate
- it accepts the oddly-typed immediate in any position, not just the first
right?

Maybe special-case this in createAndImportSelDAGMatcher instead?


https://reviews.llvm.org/D32278





More information about the llvm-commits mailing list