PR inline-asm/84742
[official-gcc.git] / gcc / testsuite / gcc.target / i386 / pr49781-1.c
blob60f9d50d86682470bc54bad398349e6c80b5761a
1 /* { dg-do compile } */
2 /* { dg-options "-O2 -fpic -mtune=generic" } */
3 /* { dg-require-effective-target fpic } */
5 static int heap[2*(256 +1+29)+1];
6 static int heap_len;
7 static int heap_max;
8 void
9 foo (int elems)
11 int n, m;
12 int max_code = -1;
13 int node = elems;
14 heap_len = 0, heap_max = (2*(256 +1+29)+1);
15 for (n = 0; n < elems; n++)
16 heap[++heap_len] = max_code = n;
17 do {
18 n = heap[1];
19 heap[1] = heap[heap_len--];
20 m = heap[1];
21 heap[--heap_max] = n;
22 heap[--heap_max] = m;
23 } while (heap_len >= 2);
26 /* { dg-final { scan-assembler-not "lea\[lq\]?\[ \t\]\\((%|)r\[a-z0-9\]*" } } */