1 /* { dg-do compile } */
2 /* { dg-options "-O2" } */
3
4 /* PR rtl-optimization/78038.
5 Make sure ree can gracefully handle extensions of the global
6 variable register after a call. */
7
8 typedef void (*test_fptr_t) (void);
9 void
10 test_f (void)
11 {
12 }
13 test_fptr_t test_fptr = test_f;
14
15 struct test2_s
16 {
17 int f;
18 };
19
20 register struct test2_s *g __asm__("x28");
21
22 void
23 do_something ()
24 {
25 test_fptr ();
26 struct test2_s *p1 = 0;
27 *p1 = *g;
28 }