[llvm] [IPT] Remove ipt.NumInstScanned statistic (PR #168515)

Luke Lau via llvm-commits llvm-commits at lists.llvm.org
Tue Nov 18 03:56:22 PST 2025


lukel97 wrote:

> Seems fine, but curious if you know why this is non-deterministic?

My best guess is that there's users like this, where the blocks iterator() might not always be in the same order

```
void ICFLoopSafetyInfo::computeLoopSafetyInfo(const Loop *CurLoop) {
  assert(CurLoop != nullptr && "CurLoop can't be null");
  ICF.clear();
  MW.clear();
  MayThrow = false;
  // Figure out the fact that at least one block may throw.
  for (const auto &BB : CurLoop->blocks())
    if (ICF.hasICF(&*BB)) {
      MayThrow = true;
      break;
    }
```

But I haven't confirmed.

https://github.com/llvm/llvm-project/pull/168515


More information about the llvm-commits mailing list