[PATCH] D24979: [CUDA] Support <complex> and std::min/max on the device.

Eric Christopher via cfe-commits cfe-commits at lists.llvm.org
Tue Sep 27 13:33:43 PDT 2016


echristo accepted this revision.
echristo added a comment.
This revision is now accepted and ready to land.

In https://reviews.llvm.org/D24979#554378, @jlebar wrote:

> > I' personally would prefer to force-include these files. I suspect it will not change things much as we already include a lot.
>
>
> We have already had bugs filed by users whose root cause was that we #included more things than nvcc #includes.  I know exact compatibility with nvcc is not our goal, but unless we have a good reason I don't think we should break compatibility with nvcc *and* the C++ standard by force-including additional system headers.
>
> > This looks like fix-includes and it may be somewhat shaky if users start messing with include paths.
>
>
> We add this include path first, so I think it should be OK?  What do you think, @echristo?


It is very similar to fixincludes, but in this case I think it's probably the right thing.

If nothing else it's very easy to change our minds later.

One small wording change requested.

Thanks!

-eric


================
Comment at: clang/lib/Headers/__clang_cuda_complex_builtins.h:1
@@ +1,2 @@
+/*===-- __clang_cuda_complex_builtins - CUDA impls of libgcc complex fns ----===
+ *
----------------
Would swap libgcc for "runtime"


https://reviews.llvm.org/D24979





More information about the cfe-commits mailing list