[PATCH] D96524: [OpenCL] Add support of OpenCL C 3.0 __opencl_c_fp64

Sven van Haastregt via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Feb 12 03:41:57 PST 2021


svenvh added inline comments.


================
Comment at: clang/include/clang/Basic/OpenCLOptions.h:157
+  // Is OpenCL C feature (OpenCL C 3.0, 6.2.1. Features)
+  bool isFeature(llvm::StringRef Ext) const;
+
----------------
The argument "Ext" suggests "Extension", so perhaps rename if this is about features? (also in the definition in the .cpp file)


================
Comment at: clang/lib/Basic/TargetInfo.cpp:395
+
+    // Set extensions simultaneosly with correspoding features
+    // for OpenCL C 3.0 and higher
----------------
simultaneosly -> simultaneously
correspoding -> corresponding


================
Comment at: clang/lib/Headers/opencl-c.h:4635
 
-#ifdef cl_khr_fp64
+#if defined(cl_khr_fp64) || defined(__opencl_c_fp64)
 #pragma OPENCL EXTENSION cl_khr_fp64 : enable
----------------
Wondering if we need a similar change in `clang/lib/Headers/opencl-c-base.h` to guard the double<N> vector types?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D96524



More information about the cfe-commits mailing list