1 /* { dg-options "-mthumb -Os -fpic -fdump-rtl-hoist" } */
2 /* { dg-require-effective-target arm_thumb1_ok } */
3 /* { dg-require-effective-target fpic } */
4 /* Make sure all calculations of gObj's address get hoisted to one location. */
5 /* { dg-final { scan-rtl-dump "PRE/HOIST: end of bb .* copying expression" "hoist" } } */
16 extern struct st_b gObj
;
17 extern void foo(int, struct st_b
*);
19 int goo(struct st_b
* obj
) {
21 if (gObj
.p_a
->data
!= 0) {
22 foo(gObj
.p_a
->data
, obj
);
27 } else if (pa
== gObj
.p_a
) {