[llvm-bugs] [Bug 45469] New: Omitting the optional variable-category of defaultmap clause causes Clang to abort

via llvm-bugs llvm-bugs at lists.llvm.org
Tue Apr 7 16:21:43 PDT 2020


https://bugs.llvm.org/show_bug.cgi?id=45469

            Bug ID: 45469
           Summary: Omitting the optional variable-category of defaultmap
                    clause causes Clang to abort
           Product: clang
           Version: 10.0
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: OpenMP
          Assignee: unassignedclangbugs at nondot.org
          Reporter: jennifer.yu at intel.com
                CC: llvm-bugs at lists.llvm.org

In OMP spec 5.0:

The syntax of the defaultmap clause is as follows:

defaultmap(implicit-behavior[:variable-category])

But current clang give error when omitting variable-category

cmplrllvm-11546>clang  -cc1 -fopenmp  -fopenmp-version=50 x.cpp
x.cpp:4:45: warning: missing ':' after defaultmap modifier - ignoring
  #pragma omp target defaultmap(firstprivate)
                                            ^
x.cpp:4:45: error: expected 'scalar', 'aggregate', 'pointer' in OpenMP clause
'defaultmap'
1 warning and 1 error generated.

cmplrllvm-11546>cat x.cpp
void implicit_maps_double_complex (int a){
  double _Complex dc = (double)a;

  #pragma omp target defaultmap(firstprivate)
  {
    dc *= dc;
  }
}

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20200407/3b675874/attachment-0001.html>


More information about the llvm-bugs mailing list