[cfe-dev] Clang error

Enrique González via cfe-dev cfe-dev at lists.llvm.org
Thu Feb 6 04:51:21 PST 2020


Dear all,

I have had a problem when using clang to transform an OpenCL code to a
bytecode. When i use the command "clang" like:
clang -cc1 -triple spir64 -emit-llvm-bc -finclude-default-header
-cl-single-precision-constant example.cl -o example.bc

I get back, in many programs, an undeclared identifier error, for example:

../programs/nsgminer/scrypt.cl:764:30: error: use of undeclared identifier
'LOOKUP_GAP'
    const uint ySIZE = (1024/LOOKUP_GAP+(1024%LOOKUP_GAP>0));

Does someone know if I can solve this problem,  or I just cannot transform
this kind of OpenCL code into bytecode format?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20200206/ed4ce5ee/attachment.html>


More information about the cfe-dev mailing list