[ree] PR rtl-optimization/78038: Handle global register dataflow definitions in ree
[official-gcc.git] / gcc / testsuite / gcc.target / aarch64 / pr78038.c
blob76d97d3b0ad44cd75afa1e1e45434413421c5afa
1 /* { dg-do compile } */
2 /* { dg-options "-O2" } */
4 /* PR rtl-optimization/78038.
5 Make sure ree can gracefully handle extensions of the global
6 variable register after a call. */
8 typedef void (*test_fptr_t) (void);
9 void
10 test_f (void)
13 test_fptr_t test_fptr = test_f;
15 struct test2_s
17 int f;
20 register struct test2_s *g __asm__("x28");
22 void
23 do_something ()
25 test_fptr ();
26 struct test2_s *p1 = 0;
27 *p1 = *g;