1 ! Test the MLIR pass pipeline
3 ! RUN: bbc --mlir-pass-statistics --mlir-pass-statistics-display=pipeline %s 2>&1 | FileCheck %s
9 ! CHECK: Pass statistics report
11 ! CHECK: Fortran::lower::VerifierPass
13 ! Ideally, we need an output with only the pass names, but
14 ! there is currently no way to get that, so in order to
15 ! guarantee that the passes are in the expected order
16 ! (i.e. use -NEXT) we have to check the statistics output as well.
17 ! CHECK-NEXT: (S) 0 num-cse'd - Number of operations CSE'd
18 ! CHECK-NEXT: (S) 0 num-dce'd - Number of operations DCE'd
20 ! CHECK-NEXT: 'func.func' Pipeline
21 ! CHECK-NEXT: ArrayValueCopy
22 ! CHECK-NEXT: CharacterConversion
24 ! CHECK-NEXT: Canonicalizer
25 ! CHECK-NEXT: SimplifyRegionLite
26 ! CHECK-NEXT: SimplifyIntrinsics
27 ! CHECK-NEXT: AlgebraicSimplification
29 ! CHECK-NEXT: (S) 0 num-cse'd - Number of operations CSE'd
30 ! CHECK-NEXT: (S) 0 num-dce'd - Number of operations DCE'd
32 ! CHECK-NEXT: 'func.func' Pipeline
33 ! CHECK-NEXT: MemoryAllocationOpt
36 ! CHECK-NEXT: SimplifyRegionLite
38 ! CHECK-NEXT: (S) 0 num-cse'd - Number of operations CSE'd
39 ! CHECK-NEXT: (S) 0 num-dce'd - Number of operations DCE'd
41 ! CHECK-NEXT: 'func.func' Pipeline
42 ! CHECK-NEXT: CFGConversion
44 ! CHECK-NEXT: SCFToControlFlow
45 ! CHECK-NEXT: Canonicalizer
46 ! CHECK-NEXT: SimplifyRegionLite
48 ! CHECK-NEXT: (S) 0 num-cse'd - Number of operations CSE'd
49 ! CHECK-NEXT: (S) 0 num-dce'd - Number of operations DCE'd
50 ! CHECK-NOT: LLVMIRLoweringPass