[Mesa-dev] [RFC PATCH] clover: add LLVM version to device and platform version
Francisco Jerez
currojerez at riseup.net
Sun May 15 01:32:05 UTC 2016
Giuseppe Bilotta <giuseppe.bilotta at gmail.com> writes:
> Code generation (kernel compilation) may sometimes hit LLVM-specific
> bugs. Adding the used LLVM version to the version string may make bug
> triaging easier.
>
> Signed-off-by: Giuseppe Bilotta <giuseppe.bilotta at gmail.com>
Acked-by: Francisco Jerez <currojerez at riseup.net>
> ---
> configure.ac | 2 +-
> src/gallium/state_trackers/clover/api/device.cpp | 2 +-
> src/gallium/state_trackers/clover/api/platform.cpp | 2 +-
> 3 files changed, 3 insertions(+), 3 deletions(-)
>
>
> I believe similar additions could be made for OpenGL version strings as well.
>
> diff --git a/configure.ac b/configure.ac
> index 023110e..4fcadcf 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -2116,7 +2116,7 @@ if test "x$enable_gallium_llvm" = xyes; then
> LLVM_COMPONENTS="${LLVM_COMPONENTS} all-targets ipo linker instrumentation"
> LLVM_COMPONENTS="${LLVM_COMPONENTS} irreader option objcarcopts profiledata"
> fi
> - DEFINES="${DEFINES} -DHAVE_LLVM=0x0$LLVM_VERSION_INT -DMESA_LLVM_VERSION_PATCH=$LLVM_VERSION_PATCH"
> + DEFINES="${DEFINES} -DHAVE_LLVM=0x0$LLVM_VERSION_INT -DMESA_LLVM_VERSION_PATCH=$LLVM_VERSION_PATCH '-DMESA_LLVM_VERSION_STRING=\"$LLVM_VERSION_MAJOR.$LLVM_VERSION_MINOR.$LLVM_VERSION_PATCH\"'"
> MESA_LLVM=1
>
> dnl Check for Clang internal headers
> diff --git a/src/gallium/state_trackers/clover/api/device.cpp b/src/gallium/state_trackers/clover/api/device.cpp
> index bc93f91..0d0f77b 100644
> --- a/src/gallium/state_trackers/clover/api/device.cpp
> +++ b/src/gallium/state_trackers/clover/api/device.cpp
> @@ -300,7 +300,7 @@ clGetDeviceInfo(cl_device_id d_dev, cl_device_info param,
> break;
>
> case CL_DEVICE_VERSION:
> - buf.as_string() = "OpenCL 1.1 MESA " PACKAGE_VERSION;
> + buf.as_string() = "OpenCL 1.1 MESA " PACKAGE_VERSION " LLVM " MESA_LLVM_VERSION_STRING;
> break;
>
> case CL_DEVICE_EXTENSIONS:
> diff --git a/src/gallium/state_trackers/clover/api/platform.cpp b/src/gallium/state_trackers/clover/api/platform.cpp
> index cf71593..06eb4ec 100644
> --- a/src/gallium/state_trackers/clover/api/platform.cpp
> +++ b/src/gallium/state_trackers/clover/api/platform.cpp
> @@ -57,7 +57,7 @@ clover::GetPlatformInfo(cl_platform_id d_platform, cl_platform_info param,
> break;
>
> case CL_PLATFORM_VERSION:
> - buf.as_string() = "OpenCL 1.1 MESA " PACKAGE_VERSION;
> + buf.as_string() = "OpenCL 1.1 MESA " PACKAGE_VERSION " LLVM " MESA_LLVM_VERSION_STRING;
> break;
>
> case CL_PLATFORM_NAME:
> --
> 2.8.1.372.g9612035
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 212 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20160514/583ba32d/attachment-0001.sig>
More information about the mesa-dev
mailing list