[PATCH] D99432: [OPENMP]Fix PR48851: the locals are not globalized in SPMD mode.

Alexey Bataev via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Mar 26 11:40:51 PDT 2021


ABataev added a comment.

In D99432#2653474 <https://reviews.llvm.org/D99432#2653474>, @jdoerfert wrote:

> Can we please always do the globalization, even in the `target teams distribute parallel for` case you need it if a thread shares the address of a local variable with the team and another thread uses it.

Could you give a small example so I could better understand the problem? Shall we globalize the variable in SPMD mode if we pass it by reference/take address in any case?

> There is no argument other than "doesn't escape" that Clang can make to disprove globalization is needed, IMHO.




Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D99432/new/

https://reviews.llvm.org/D99432



More information about the cfe-commits mailing list