[PATCH] D22637: [OpenCL] Add extension cl_khr_mipmap_image to clang

Anastasia Stulova via cfe-commits cfe-commits at lists.llvm.org
Tue Jul 26 08:40:50 PDT 2016


Anastasia added inline comments.

================
Comment at: test/SemaOpenCL/extension-version.cl:228
@@ +227,3 @@
+#endif
+// expected-warning at +6{{unsupported OpenCL extension 'cl_khr_mipmap_image' - ignoring}}
+#else
----------------
Anastasia wrote:
> ashi1 wrote:
> > Anastasia wrote:
> > > Can you move this error message down instead of adding 6 lines offset.
> > I've added this error message here because I am following the order inside include/clang/Basic/OpenCLExtensions.def. Seems it is alphabetical there and in same order here. What do you think?
> Sure that's great! I am just saying could you move the expected-warning line below to where it belongs i.e. line 234 where you are enabling the extension which results in a warning generated.
My main problem here is that the check for the warning is too far away from the place that generates it and therefore difficult to understand. If we could restructure this somehow. I think it's also OK to move this line above:
  #pragma OPENCL EXTENSION cl_khr_mipmap_image: enable

This test is already hard to read, let's try to simplify it a bit...


Repository:
  rL LLVM

https://reviews.llvm.org/D22637





More information about the cfe-commits mailing list