[testsuite] require sqrt_insn effective target where needed
[official-gcc.git] / gcc / testsuite / gcc.target / powerpc / 20050603-1.c
blobf801c43b35181a6878882557a4f5eb67e1459a7b
1 /* { dg-do run { target powerpc*-*-* } } */
2 /* { dg-options "-O2" } */
3 #include <locale.h>
4 #include <stdlib.h>
5 register int *testreg asm ("r29");
7 int x;
8 int y;
9 int *ext_func (int *p) { return p; }
11 void test_reg_save_restore (int*) __attribute__((noinline));
12 void
13 test_reg_save_restore (int *p)
15 setlocale (LC_ALL, "C");
16 testreg = ext_func(p);
18 int
19 main() {
20 testreg = &x;
21 test_reg_save_restore (&y);
22 if (testreg != &y)
23 abort ();
24 return 0;