[PATCH] D47694: [CUDA][HIP] Do not emit type info when compiling for device

John McCall via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Jun 4 08:41:57 PDT 2018


rjmccall added a comment.

In https://reviews.llvm.org/D47694#1120375, @yaxunl wrote:

> In https://reviews.llvm.org/D47694#1120367, @rjmccall wrote:
>
> > Why not just have the driver disable RTTI in the frontend invocation?
>
>
> CUDA/HIP uses single source for device and host. The host code may depend on RTTI,
>  e.g., an application may include some boost headers which will fail if RTTI is disabled,
>  therefore RTTI cannot be disabled when compiling device code.


It's a single source file, yes, but behind the scenes you do a separate invocation of the compiler to re-parse that file for device code-generation, right?


https://reviews.llvm.org/D47694





More information about the cfe-commits mailing list