1 ; The %A getelementptr instruction should be eliminated here
3 ; RUN: if as < %s | opt -instcombine -dce | dis | grep getelementptr | grep '%A'
10 int *"foo1"(int * %I) { ; Test noop elimination
11 %A = getelementptr int* %I, uint 0
15 int* %foo2(int* %I) { ; Test noop elimination
16 %A = getelementptr int* %I
19 int* %foo3(int * %I) { ; Test that two array indexing geps fold
20 %A = getelementptr int* %I, uint 17
21 %B = getelementptr int* %A, uint 4
25 int* %foo4({int} *%I) { ; Test that two getelementptr insts fold
26 %A = getelementptr {int}* %I, uint 1
27 %B = getelementptr {int}* %A, uint 0, ubyte 0