https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119474
--- Comment #7 from rguenther at suse dot de <rguenther at suse dot de> --- On Thu, 27 Mar 2025, ams at gcc dot gnu.org wrote: > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119474 > > --- Comment #6 from Andrew Stubbs <ams at gcc dot gnu.org> --- > The address space has to be introduced "late" because it's done in the > accelerator compiler, so post-IPA. The pass is "oaccdevlow" (currently > no.103). > > The address space is selected via the TARGET_GOACC_ADJUST_PRIVATE_DECL hook. Ugh. I see oacc_rewrite_var_decl copies TYPE_QUALs in incomplete ways. I'll note that in case there are ADDR_EXPRs all uses of such address are not updated it seems? Like _1 = &to_rewrite_decl; _2 = *_1; where do we rewrite *_1? It seems to be a quite fragile machinery^Whack.