[PATCH] D101017: [NewPM] Make GlobalsAA available earlier in the pipeline
Arthur Eubanks via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Apr 22 21:55:02 PDT 2021
aeubanks added a comment.
Looking at one of the examples in llvm-test-suite that regressed, this seems to be regressing some very simple code:
void f(double *a) {
double c[20] = {
0.1051, 0.0157, 0.0185, 0.0089, 0.0219, 0.0141, 0.0097,
0.0758, 0.0168, 0.1188, 0.1635, 0.0112, 0.0333, 0.0777,
0.0260, 0.0568, 0.0523, 0.0223, 0.0324, 0.1195,
};
for (int i = 0; i < 20; i++)
a[i] = c[i];
}
Before, it would just turn it into a memcpy.
With this change, it becomes a bunch of individual stores.
Looks like [1] is to blame. The extra AA causes it to fire and introduce the individual stores.
[1]: https://github.com/llvm/llvm-project/blob/53673fd1bf6f2dd94d8bb6ced49cc54ec5fc866b/llvm/lib/Transforms/InstCombine/InstCombineLoadStoreAlloca.cpp#L422
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D101017/new/
https://reviews.llvm.org/D101017
More information about the cfe-commits
mailing list