https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102838
--- Comment #11 from Jakub Jelinek <jakub at gcc dot gnu.org> --- Ah, I see, there is still the team->work_shares array where the whole team structure in which it is present is allocated with gomp_malloc. So, either we need to drop the aligned (64) attribute regardless of GOMP_HAVE_EFFICIENT_ALIGNED_ALLOC, or make sure that if GOMP_HAVE_EFFICIENT_ALIGNED_ALLOC we use gomp_aligned_alloc instead of gomp_malloc for team_malloc, or combination of both (GCN has its own separate team_malloc, so perhaps get rid of aligned attribute on GCN too).