[PATCH] D148254: [OpenMP][Flang][Semantics] Add semantics support for USE_DEVICE_PTR clause on OMP TARGET DATA directive.
Kiran Chandramohan via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sat Apr 22 16:12:16 PDT 2023
kiranchandramohan added a comment.
At the moment a new symbol is not created because `target data` does not create a scope at the moment. We have to modify the `OmpVisitor::NeedsScope` function in resolve-names.cpp file to create a scope.
Please update the document (https://github.com/llvm/llvm-project/blob/main/flang/docs/OpenMP-semantics.md) to include that new scope is created for `target data` and new Symbol is created for `use_device_pointer`. Also include the reason.
================
Comment at: flang/test/Semantics/OpenMP/use_device_ptr.f90:14
+ !$omp target data map(tofrom: a, arrayB) use_device_ptr(b)
+ !CHECK: b (OmpUseDevicePtr)
+ allocate(arrayB)
----------------
The test should check both the original symbol and the host-associated symbol.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D148254/new/
https://reviews.llvm.org/D148254
More information about the llvm-commits
mailing list