[PATCH] D108112: [LoopIdiom] Let LIR fold memset pointer / stride SCEV regarding loop guards

Bardia Mahjour via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Dec 13 07:09:59 PST 2021


bmahjour added a comment.

LGTM



================
Comment at: llvm/test/Transforms/LoopIdiom/memset-runtime.ll:110-140
+; The C code to generate this testcase:
+; void test(int n, int m, int o, int *ar)
+; {
+;   for (int i=0; i<n; ++i) {
+;     for (int j=0; j<m; ++j) {
+;       int *arr = ar + i * m * o + j * o;
+;       memset(arr, 0, o * sizeof(int));
----------------
eopXD wrote:
> bmahjour wrote:
> > Why is this test removed?
> The test file is split into 2 files, `memset-runtime-32bit.ll` and `memset-runtime-64bit.ll` to test on 32-bit mode and 64-bit mode in D108507. So `memset-runtime.ll` is gone.
If you could put the comment, describing what these tests are meant for (ie lines 120-125), at the beginning of memset-runtime-32bit.ll and/or memset-runtime-64bit.ll it would be helpful.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D108112



More information about the llvm-commits mailing list