[PATCH] D130466: [LICM] - Add option to allow data races

Shubham Narlawar via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Sep 7 04:23:56 PDT 2022


gsocshubham updated this revision to Diff 458416.
gsocshubham added a comment.

Address review comments.

Run -instnamer on lit tests.

TODO - Add a negative test for the constant memory case.

I am thinking on what changes needs to be done on below testcase to become it as negative test -

int u, v;

void f(int a[restrict], int b[restrict], int n) {

  for (int i = 0; i < n; ++i) {
      if (a[i]) {
          ++u;
          break;
      }
      ++u;
      if (b[i])
          ++v;
  }

}


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

https://reviews.llvm.org/D130466

Files:
  llvm/include/llvm/Analysis/TargetTransformInfo.h
  llvm/include/llvm/Analysis/TargetTransformInfoImpl.h
  llvm/include/llvm/CodeGen/BasicTTIImpl.h
  llvm/include/llvm/Transforms/Utils/LoopUtils.h
  llvm/lib/Analysis/TargetTransformInfo.cpp
  llvm/lib/Transforms/Scalar/LICM.cpp
  llvm/test/Transforms/LICM/promote-sink-store.ll
  llvm/test/Transforms/LICM/without-force-thread-model-single.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D130466.458416.patch
Type: text/x-patch
Size: 16188 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220907/047eddb4/attachment.bin>


More information about the llvm-commits mailing list