1 ; RUN: opt < %s -lowerswitch -disable-output 2 3 ; This test verify -lowerswitch does not crash after deleting the default block. 4 5 declare i32 @f(i32) 6 7 define i32 @unreachable(i32 %x) { 8 9 entry: 10 switch i32 %x, label %unreachable [ 11 i32 5, label %a 12 i32 6, label %a 13 i32 7, label %a 14 i32 10, label %b 15 i32 20, label %b 16 i32 30, label %b 17 i32 40, label %b 18 ] 19 unreachable: 20 unreachable 21 a: 22 %0 = call i32 @f(i32 0) 23 ret i32 %0 24 b: 25 %1 = call i32 @f(i32 1) 26 ret i32 %1 27 } 28