PATCH: Add "noduplicate" property for intrinsics and use it NVPTX synchronization intrinsics

Eli Bendersky eliben at google.com
Mon Mar 17 14:09:19 PDT 2014


Hello,

The "noduplicate" function attribute exists to prevent certain
optimizations from duplicating calls to the function. This is important on
platforms where certain function call duplications are unsafe (for example
execution barriers for CUDA and OpenCL).

This patch make it possible to specify intrinsics as "noduplicate" and
translates that to the appropriate function attribute. It also uses it for
the int_cuda_syncthreads intrinsics. Tests are also added.

Justin: for now I just added it for the intrinsic directly visible from
CUDA source. Should this attribute be added to all int_nvvm_barrier0*
intrinsics as well?

PTAL

Eli
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140317/8f050e55/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: intrinsics-noduplicate.1.patch
Type: text/x-patch
Size: 7347 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140317/8f050e55/attachment.bin>


More information about the llvm-commits mailing list