blob: 3bbb101ef47f96c717fdbe8b88e2fe1c3511c74d [file] [log] [blame]
Dan Gohmanf17a25c2007-07-18 16:29:46 +00001; This test ensures that the simplifycfg pass continues to constant fold
2; terminator instructions.
3
4; RUN: llvm-upgrade < %s | llvm-as | opt -simplifycfg | not grep br
5
6int %test(int %A, int %B) {
7J:
8 %C = add int %A, 12
9 br bool true, label %L, label %K ; K is dead!
10L:
11 %D = add int %C, %B
12 ret int %D
13K:
14 %E = add int %C, %B
15 ret int %E
16}