Skip to content

error: expected 'scalar', 'aggregate', 'pointer' in OpenMP clause 'defaultmap' #35

Open

Description

@jinz2014

I tried to compile Examples/devices/sources/target_defaultmap.1.c with the amdclang++ compiler

The error message is
target_defaultmap.1.c:96:39: error: expected 'scalar', 'aggregate', 'pointer' in OpenMP clause 'defaultmap'
96 | #pragma omp target defaultmap(to: all) map(from: s3)
| ^
1 error generated.

Activity

  1. HenryJin commented on Sep 16, 2025

    @HenryJin
    Contributor

    The variable category "all" to the defaultmap class was added in OpenMP 5.2 (as indicated by omp_5.2 in the referenced example). The compiler you were using (amdclang++) does not support this particular feature from OpenMP 5.2. Please check with vendor document on feature support.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions