Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Disable exceptions when used in CUDA code
NVCC supports neither exceptions nor std::terminate in device code, but silently ignores them. When using Clang to compile CUDA code, "reference to __host__ function" errors are raised when using exceptions or std::terminate. This patch disables exceptions and uses the __trap intrinsic to deliver consistently correct behavior for both NVCC and Clang. MPARK_BUILTIN_UNREACHABLE cannot be used here as it again results in "reference to __host__ function" errors.
- Loading branch information