[PATCH] D122776: [NFC][LoopCacheAnalysis] Add a motivating test case for improved loop cache analysis cost calculation

Bardia Mahjour via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue May 3 07:20:38 PDT 2022


bmahjour added inline comments.


================
Comment at: llvm/test/Analysis/LoopCacheAnalysis/PowerPC/single-store.ll:78
 
+; Loop i is supposed to have the largest cost and be placed
+; as the outermost loop.
----------------
Could you please make it more clear how this test is different from the one above (ie add a comment to say that this is testing to make sure the analysis prints the loops in the expected order despite the original loop nest being in suboptimal order)?


================
Comment at: llvm/test/Analysis/LoopCacheAnalysis/PowerPC/single-store.ll:88-90
+; CHECK-DAG: Loop 'for.i' has cost = 100000000
+; CHECK-DAG: Loop 'for.j' has cost = 1000000
+; CHECK-DAG: Loop 'for.k' has cost = 60000
----------------
Use CHECK and CHECK-NEXT


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

https://reviews.llvm.org/D122776



More information about the llvm-commits mailing list