2 ; RUN: opt -regions -analyze -enable-new-pm=0 < %s | FileCheck %s
3 ; RUN: opt -passes='print<regions>' -disable-output < %s 2>&1 | FileCheck %s
5 ; While working on improvements to the region info analysis, this test
6 ; case caused an incorrect region 3 => 8 to be detected.
8 define internal i8 @wibble() {
10 br i1 true, label %bb1, label %bb8
13 switch i32 0, label %bb2 [
30 bb6: ; preds = %bb5, %bb4
33 bb7: ; preds = %bb6, %bb1
36 bb8: ; preds = %bb7, %bb
40 ; CHECK: [0] bb => <Function Return>
41 ; CHECK-NEXT: [1] bb => bb8
42 ; CHECK-NEXT: [2] bb1 => bb7
43 ; CHECK-NEXT: End region tree