blob: 78cdd43051feff3c032d2af84fca993d065611da [file] [log] [blame]
Dan Gohmanf17a25c2007-07-18 16:29:46 +00001; RUN: llvm-upgrade < %s | llvm-as | opt -basicaa -load-vn -gcse -instcombine | llvm-dis | not grep sub
2declare int %strlen(sbyte*)
3
4int %test(sbyte* %P) {
5 %X = call int %strlen(sbyte* %P)
6 %A = add int %X, 14
7 %Y = call int %strlen(sbyte* %P)
8 %Z = sub int %X, %Y
9 %B = add int %A, %Z
10 ret int %B
11}