[PATCH] D14000: [CUDA] Allow code generation for functions with target attributes that don't match compilation mode.
Artem Belevich via cfe-commits
cfe-commits at lists.llvm.org
Thu Oct 22 15:56:14 PDT 2015
tra created this revision.
tra added reviewers: eliben, jingyue, jpienaar, echristo.
tra added a subscriber: cfe-commits.
Currently -fcuda-disable-target-call-checks option enables parsing of code that calls across host/device boundary.
However, we don't emit any IR for functions that don't have attributes appropriate for the current compilation mode, so such cross-calls always fail at runtime due to unresolved references.
The patch allows CodeGen to emit non-matching functions if they are needed to resolve references in the current module.
This feature is enabled by -fcuda-disable-target-call-checks
The patch makes it possible for device side to use host unmodified includes that provide unattributed functions.
For instance, it allows use of larger subset of standard C++ library headers.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 7530 bytes
Desc: not available
More information about the cfe-commits