[PATCH] D12246: [NVPTX] change threading intrinsics from noduplicate to convergent
Mehdi Amini via llvm-commits
llvm-commits at lists.llvm.org
Mon Aug 31 21:55:31 PDT 2015
> On Aug 31, 2015, at 9:49 PM, Mehdi Amini <mehdi.amini at apple.com> wrote:
>
>
>> On Aug 31, 2015, at 9:24 PM, Owen Anderson <resistor at mac.com <mailto:resistor at mac.com>> wrote:
>>
>>
>>> On Aug 31, 2015, at 5:57 PM, Mehdi Amini <mehdi.amini at apple.com <mailto:mehdi.amini at apple.com>> wrote:
>>>
>>>
>>> if (b) {
>>> for (int i = 0; i < 100; ++i) {
>>> // do something
>>> __syncthreads();
>>> }
>>> } else {
>>> for (int i = 0; i < 100; ++i) {
>>> __syncthreads();
>>> }
>>> }
>>>
>>> I think it would match your constraint, i.e. "they are be executed in under the same set of execution predicates as where the user wrote them”.
>>
>> I would not consider this to match the convergent constraint. Each of the __syncthreads() calls after unswitching executes under a subset of the predicates under which the original executed.
>
> Can you define what you mean by “predicates under which the original executed”?
I think I see what you mean: the syncthreads() call is made control dependent on b while it was not before. Your sentence made me think about something quite different.
—
Mehdi
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150831/31cfccac/attachment.html>
More information about the llvm-commits
mailing list