[PATCH] D100492: [OpenCL] Change OpenCL builtin version encoding
    Sven van Haastregt via Phabricator via cfe-commits 
    cfe-commits at lists.llvm.org
       
    Thu Apr 15 07:22:42 PDT 2021
    
    
  
svenvh added inline comments.
================
Comment at: clang/utils/TableGen/ClangOpenCLBuiltinEmitter.cpp:507
+    if (VersionIDs[I] >= MinVersion && VersionIDs[I] < MaxVersion) {
+      Encoded |= 1 << I;
+    }
----------------
azabaznov wrote:
> nit: Encoded |= clang::encodeOpenCLVersion(VersionIDs[I]);
I wish I could use `encodeOpenCLVersion` indeed, but the Clang headers are not available in TableGen (see comment on line 493).  I couldn't think of a better solution unfortunately, but let me know if you have any suggestions.
Repository:
  rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D100492/new/
https://reviews.llvm.org/D100492
    
    
More information about the cfe-commits
mailing list