[PATCH] D150666: [WIP][GlobalISel] Combiner Intrinsic Matching

Pierre van Houtryve via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue May 16 06:10:38 PDT 2023


Pierre-vh added a comment.

It's not quite ready yet, but I need some help, so I'm leaving this as a WIP and just adding a few reviewers until the two issues highlighted are sorted out.
Once these are addressed I will add more reviewers + more testcases (including practical ones, e.g. add patterns using intrinsics in AMDGPU combiner) for a proper review.



================
Comment at: llvm/test/TableGen/GICombinerEmitter/match-tree.td:367
+
+// TODO: This should be merged with the code above. The tree currently emits the same
+// code once for each G_INTRINSIC opcode variant which is useless bloat really.
----------------
Is it possible to de-duplicate this with the current MatchDag?


================
Comment at: llvm/utils/TableGen/GlobalISel/GIMatchTree.cpp:462
+
+        // FIXME: This is needed, but prevents patterns such as
+        //   (match (G_FPTRUNC $fptrunc_dst, $fmed3_dst):$fptrunc,
----------------
This is the most annoying bit at the moment. It's quite restrictive and the example in the github issue doesn't work because of it: https://github.com/llvm/llvm-project/issues/62628


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D150666/new/

https://reviews.llvm.org/D150666



More information about the llvm-commits mailing list