arsenm added a comment.

In D78979#2011582 <https://reviews.llvm.org/D78979#2011582>, @jvesely wrote:

> In D78979#2006901 <https://reviews.llvm.org/D78979#2006901>, @yaxunl wrote:
>
> > In D78979#2006847 <https://reviews.llvm.org/D78979#2006847>, @arsenm wrote:
> >
> > > I'm also wondering if using -nogpulib for the corresponding linker 
> > > purpose was correct, since in the OpenCL case it's not really an offload 
> > > target. Maybe this should switch to -nostdlib?
> >
> >
> > -nogpulib is fine since opencl compiler is in parallel with the device 
> > compiler of CUDA/HIP. The library it uses is the device library.
>
>
> OpenCL can target other devices than GPUs, including CPUs and FPGAs, 
> referring to gpulibs wrt opencl is a misnomer.


It makes sense to have a separate flag from -nostdiinc for CUDA/HIP/OpenMP 
since you have to consider both the host and offload target code.

> It would be nice to have some clarity as to how OpenCL is handled wrt clang 
> frontend vs. clang driver.
>  OpenCL options are currently split between the two (e.g. cl-denorms-are-zero 
> is only available in the driver and not the frontend)

Users shouldn't ever need to concern themselves with cc1 flags. That's part of 
the issue with not including the header by default today. Only the user facing 
driver should be guaranteed to have all the spec flags

> There are 3 implementations of CL headers, two in clang which might or might 
> not be included by default, and the 3rd one in libclc.

I think the libclc header should just be removed


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D78979/new/

https://reviews.llvm.org/D78979



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to