[llvm] Changed stat passes to count instructions before and after optimizations (PR #188837)
Arthur Eubanks via llvm-commits
llvm-commits at lists.llvm.org
Mon Mar 30 10:54:34 PDT 2026
================
@@ -7,15 +7,15 @@
; RUN: opt -stats -enable-detailed-function-properties -disable-output -O3 < %s 2>&1 | FileCheck %s
; RUN: opt -stats -enable-detailed-function-properties -disable-output -O0 < %s 2>&1 | FileCheck %s
-; CHECK-DAG: 10 func-properties-stats - Number of basic blocks
-; CHECK-DAG: 8 func-properties-stats - Number of branch instructions
-; CHECK-DAG: 10 func-properties-stats - Number of branch successors
-; CHECK-DAG: 2 func-properties-stats - Number of conditional branch instructions
-; CHECK-DAG: 6 func-properties-stats - Number of unconditional branch instructions
-; CHECK-DAG: 18 func-properties-stats - Number of instructions (of all types)
-; CHECK-DAG: 14 func-properties-stats - Number of basic block successors
-; CHECK-DAG: 1 func-properties-stats - Number of switch instructions
-; CHECK-DAG: 4 func-properties-stats - Number of switch successors
+; CHECK-DAG: 10 func-properties-stats - Number of basic blocks ({{before|after}} optimizations)
----------------
aeubanks wrote:
testing `before|after` is kinda weird imo, we should be more precise in what we're testing
https://github.com/llvm/llvm-project/pull/188837
More information about the llvm-commits
mailing list