https://gcc.gnu.org/bugzilla/show_bug.cgi?id=120723

            Bug ID: 120723
           Summary: [13/14/15/16 Regression][OpenACC] '!$acc ...
                    attach(scalar)' – ICE 'unexpected pointer mapping
                    node'
           Product: gcc
           Version: 16.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code, openacc
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: burnus at gcc dot gnu.org
                CC: tschwinge at gcc dot gnu.org
  Target Milestone: ---

I bet the ICE itself it triggered by r13-2661-gb57abd072dd319, "OpenMP 5.0:
Clause ordering for OpenMP 5.0 (topological sorting by base pointer)" - or one
of the follow up patches.

And I have no idea whether it before just had no ICE or did actually work
properly.



The following example uses scalar variables - and fails with:

    6 | !$acc enter data attach(a)
      |                          ^
internal compiler error: unexpected pointer mapping node
0x2575d5f internal_error(char const*, ...)
        ../../../repos/gcc/gcc/diagnostic-global-context.cc:517
0xe86d34 omp_group_base
        ../../../repos/gcc/gcc/gimplify.cc:10748
0xe86d34 omp_index_mapping_groups_1
        ../../../repos/gcc/gcc/gimplify.cc:10784
0xe86db7 omp_index_mapping_groups
        ../../../repos/gcc/gcc/gimplify.cc:10845
0xe8b757 gimplify_scan_omp_clauses
        ../../../repos/gcc/gcc/gimplify.cc:13173


use openacc
implicit none (type, external)
integer,pointer :: a, b(:)
integer,allocatable :: c, d(:)

!$acc enter data attach(a)
!$acc enter data attach(b)
!$acc enter data attach(c)
!$acc enter data attach(d)

!$acc exit data detach(a)
!$acc exit data detach(b)
!$acc exit data detach(c)
!$acc exit data detach(d)
end

Reply via email to