[Openmp-commits] [PATCH] D64217: [OpenMP][NFCI] Cleanup the target state queue implementation

Johannes Doerfert via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Mon Jul 22 14:43:37 PDT 2019


jdoerfert added a comment.

In D64217#1591812 <https://reviews.llvm.org/D64217#1591812>, @ABataev wrote:

> > If they are uninitialized in LLVM-IR, it doesn't matter what happens at the PTX level and lower, LLVM could simply get rid of the accesses.
>
> They are initialized in LLVM IR, by zeroinitializer, they are not initialized in PTX file explicitly. But it is ok for PTX since, according to the documents, the memory implicitly initialized by zeros.
>
> > Why do you fight so hard against zero-cost initialization that *might be* needed for correctness?
>
>
>
>   I'm not fighting against `zero-cost` initialization. Just it is not possible to implement `zero-cost` initialization. 


There are only two possibilities:

1. It is zero initialized, which you claim but which I failed to validate so far.
2. It is not zero initialized.

In case 1, initializing with zero is free as it is already happening. We cannot have two zero initializers after all.
In case 2, initializing with zero is *necessary* as it can otherwise be transformed by LLVM in a way that would break the behavior we need.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D64217





More information about the Openmp-commits mailing list