[PATCH] D153744: [LoopUnroll] adjust for new `convergent` semantics

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jun 26 04:44:44 PDT 2023


arsenm added a comment.

In D153744#4448078 <https://reviews.llvm.org/D153744#4448078>, @JonChesterfield wrote:

> This looks quite high risk. How is it tested beyond this lit test, specifically with code that runs on the GPU? It's really easy to get broken transforms to pass a lit test where the checks were generated from the implementation.

The fun part is things are



================
Comment at: llvm/lib/Transforms/Utils/LoopUnroll.cpp:402-427
+    bool HasOutsideConvergenceControl = false;
+    for (auto &BB : L->blocks()) {
+      for (auto &I : *BB) {
+        if (auto *CB = dyn_cast<CallBase>(&I)) {
+          if (CB->isConvergent()) {
+            auto control =
+                CB->getOperandBundle(LLVMContext::OB_convergencectrl);
----------------
This is a lot for one LLVM_DEBUG, move this all to a function?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D153744



More information about the llvm-commits mailing list