* fold-const.c (fold) [EQ_EXPR]: Place both integer and real
[official-gcc.git] / gcc / testsuite / gcc.dg / 20020206-1.c
blobc5367610610048ac72eecdc0f68522ce0e0edb6f
1 /* This code is from the beginning of combine_reloads in reload.c in
2 GCC 3.1-20020117, with simplifications. It compiled incorrectly
3 for -O2 -fprefetch-loop-arrays for ix86 targets. */
5 /* { dg-do run } */
6 /* { dg-options "-O2 -fprefetch-loop-arrays -w" } */
7 /* { dg-options "-O2 -fprefetch-loop-arrays -mcpu=pentium3 -w" { target i?86-*-* } } */
9 struct reload
11 int first_member;
12 int out;
13 int final_member;
16 int n_reloads;
17 struct reload rld[10];
19 static int
20 combine_reloads ()
22 int i;
23 int output_reload = -1;
24 int secondary_out = -1;
26 for (i = 0; i < n_reloads; i++)
27 if (rld[i].out != 0)
29 if (output_reload >= 0)
30 return output_reload;
31 output_reload = i;
33 return output_reload;
36 int
37 main ()
39 n_reloads = 4;
40 rld[2].out = 2;
41 if (combine_reloads () != 2)
42 abort ();
43 exit (0);