[PATCH] D35167: [AMDGPU] Add an llvm.amdgcn.wqm intrinsic for WQM

Connor Abbott via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 20 13:14:11 PDT 2017


cwabbott added inline comments.


================
Comment at: include/llvm/IR/IntrinsicsAMDGPU.td:744-748
+// Copies the source value to the destination value, with the guarantee that
+// the source value is computed as if the entire program were executed in WQM.
+def int_amdgcn_wqm : Intrinsic<[llvm_any_ty],
+  [LLVMMatchType<0>], [IntrNoMem, IntrSpeculatable]
+>;
----------------
nhaehnle wrote:
> I believe this should be convergent, due to the way neighboring lanes may disappear due to control flow.
Hmm, I'm not really convinced. All this intrinsic does is to guarantee something about how its source value is computed, which obviously won't change if the instruction itself is moved around. The operation itself is a simple move operation, which normally isn't convergent. Can you give me an example where adding a control dependency to the WQM intrinsic causes problems?


https://reviews.llvm.org/D35167





More information about the llvm-commits mailing list