blob: 3f1a8e40003216a785a36dfc59a97f364053026f [file] [log] [blame]
Chris Lattner4e6e0ed2002-09-24 16:13:20 +00001; This test ensures that the simplifycfg pass continues to constant fold
2; terminator instructions.
3
Chris Lattnercd1d05a2003-06-28 23:13:12 +00004; RUN: as < %s | opt -simplifycfg | not grep br
Chris Lattner4e6e0ed2002-09-24 16:13:20 +00005
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}