[PATCH] D66247: [OpenMP] Fix target map for unused variables

Alexey Bataev via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Aug 14 14:05:07 PDT 2019

ABataev added a comment.

In D66247#1630245 <https://reviews.llvm.org/D66247#1630245>, @jdenny wrote:

> In D66247#1630196 <https://reviews.llvm.org/D66247#1630196>, @ABataev wrote:
> > Do we really need to map such variables? According to standard, "The map clause specifies how an original list item is mapped from the current task’s data environment to a corresponding list item in the device data environment of the device identified by the construct.", i.e. it does not map the variable, but "specifies" how to map it.
> What you're asking for now contradicts what you asked for at https://reviews.llvm.org/D65835#1624659 when I asked about the same example of `target map(a)` enclosing `teams private(a)`.

Seems to me I did not expressed my idea absolutely correctly. I meant that if the variable is really mapped, then the maptype must be generated in all cases. If we do not need to map the variable,  just like in these case, there definitely should not be maptype.

  rG LLVM Github Monorepo



More information about the cfe-commits mailing list