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

Shubham Narlawar via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 29 00:32:14 PDT 2022


gsocshubham added inline comments.


================
Comment at: llvm/test/Transforms/LICM/promote-sink-store-capture.ll:83
+entry:
+  %n.addr = alloca i32, align 4
+  %u.addr = alloca i32, align 4
----------------
C testcase which is used to generate below IR -

```
void f(int n, int u) {
    for (int i = 0, x = u; i < n; ++i) {
    x = i;
    }
}
```

Note - For capture case, store promotion happens irrespective of flag `-licm-force-thread-model-single` i.e. with just `-licm` with current state of LICM. 

In my last to last revision, without that flag captured store promotion was not happening, maybe some other patches in between have caused it.


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

https://reviews.llvm.org/D130466



More information about the llvm-commits mailing list