On 2018-02-22 — 11:04, Francisco Jerez wrote: > Pierre Moreau <pierre.mor...@free.fr> writes: > > >> do we already have an upstream version of both dependencies we could > >> just use? Or do we still need special branches? > > > > For both we can use the master branch of the upstream version. SPIRV-Tools > > validator is still not perfect, but it does already catch issues in OpenCL > > SPIR-V binaries. And llvm-spirv needs to be “rebased” as some commits went > > missing during the update process, but that is not going to impact the API > > used; we can absolutely wait for that to finish before merging the series. > > > > Maybe it would make more sense to make these dependencies optional > (since it may take a while for distros to package them) and expose > cl_khr_il_program conditionally only if they are present?
That would make sense. I’ll add some ifdefs in the code to handle that scenario. > > Pierre > > > >> On Wed, Feb 21, 2018 at 11:50 PM, Pierre Moreau <pierre.mor...@free.fr> > >> wrote: > >> > Signed-off-by: Pierre Moreau <pierre.mor...@free.fr> > >> > --- > >> > > >> > Notes: > >> > v3: > >> > * Bump the required version of SPIRV-Tools to the latest release; > >> > * Add a dependency on llvm-spirv. > >> > > >> > configure.ac | 10 ++++++++++ > >> > meson.build | 4 ++++ > >> > 2 files changed, 14 insertions(+) > >> > > >> > diff --git a/configure.ac b/configure.ac > >> > index 8a9172690a..1d393a5234 100644 > >> > --- a/configure.ac > >> > +++ b/configure.ac > >> > @@ -2386,6 +2386,16 @@ AM_CONDITIONAL(HAVE_CLOVER_ICD, test > >> > "x$enable_opencl_icd" = xyes) > >> > AC_SUBST([OPENCL_LIBNAME]) > >> > AC_SUBST([CLANG_RESOURCE_DIR]) > >> > > >> > +AS_IF([test "x$enable_opencl" = xyes], [ > >> > + PKG_CHECK_MODULES([SPIRV_TOOLS], [SPIRV-Tools >= 2018.0])]) > >> > +AC_SUBST([SPIRV_TOOLS_CFLAGS]) > >> > +AC_SUBST([SPIRV_TOOLS_LIBS]) > >> > + > >> > +AS_IF([test "x$enable_opencl" = xyes], [ > >> > + PKG_CHECK_MODULES([LLVM_SPIRV], [llvm-spirv])]) > >> > +AC_SUBST([LLVM_SPIRV_CFLAGS]) > >> > +AC_SUBST([LLVM_SPIRV_LIBS]) > >> > + > >> > dnl > >> > dnl Gallium configuration > >> > dnl > >> > diff --git a/meson.build b/meson.build > >> > index 8cf67b8171..c67bd32d0f 100644 > >> > --- a/meson.build > >> > +++ b/meson.build > >> > @@ -596,10 +596,14 @@ if _opencl != 'disabled' > >> > > >> > # TODO: alitvec? > >> > dep_clc = dependency('libclc') > >> > + dep_spirv_tools = dependency('SPIRV-Tools', version : '>= 2018.0') > >> > + dep_llvm_spirv = dependency('llvm-spirv') > >> > with_gallium_opencl = true > >> > with_opencl_icd = _opencl == 'icd' > >> > else > >> > dep_clc = [] > >> > + dep_spirv_tools = [] > >> > + dep_llvm_spirv = [] > >> > with_gallium_opencl = false > >> > with_gallium_icd = false > >> > endif > >> > -- > >> > 2.16.2 > >> >
signature.asc
Description: PGP signature
_______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev