The first two patches of the previous series [1] landed upstream a while back.
When I bump my platform/device versions to 1.2, the clang instance has been confirmed to enable 1.2 language features (like the static keyword required in test/cl/program/execute/static.cl, which goes skip->pass), while building a program with -cl-std=CL1.1 still leaves the 1.2 features disabled. I've also updated my clover platform version to 2.2 and device version to 2.0 and verified that I see expected behavior when specifying a -cl-std of: 1.0 - Invalid build options error (-cl-std=CL1.0 isn't valid). 1.1 - Build proceeds with version 1.1 1.2 - Build proceeds with version 1.2 2.0 - Build proceeds with version 2.0 2.1 - Invalid build options error 2.2 - Invalid build options error Changes since version 2: - Squashed several patches together as Pierre suggested and tried to avoid introducing and then changing API in later patches - Enable the -cl-std and __OPENCL_VERSION__ changes at the same time - Remove switch statements for version detection and created an array of struct cl_version with several attributes instead that can be matched on. Seems a lot cleaner that way (to me). Major changes since v1: Addressed Pierre's build-breakage comments Added a check for cl-std > device_clc_version Added a patch to pass the device object down into invocation.cpp instead of adding a bunch of device-based arguments. Use device_clc_version for cl version detection instead of device_version Added device_clc_version in device.cpp/hpp Anyway, happy reviewing. Cc: Jan Vesely <jan.ves...@rutgers.edu> Cc: Pierre Moreau <pierre.mor...@free.fr> Cc: Francisco Jerez <curroje...@riseup.net> 1 - https://lists.freedesktop.org/archives/mesa-dev/2017-July/164699.html _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev