Tom Stellard <t...@stellard.net> writes: > On Thu, Aug 07, 2014 at 04:02:40PM +0300, Francisco Jerez wrote: >> Jan Vesely <jan.ves...@rutgers.edu> writes: >> >> > This respin includes Francisco's approach of providing implicit >> > in the arg vector passed from clover, and Tom's idea of appending >> > implicit args after the kernel args. >> > >> >> Hmmm... Maybe it would make sense to add some sort of versioning >> (e.g. as part of the target triple) to the binary interface between >> clover and the kernel instead, so we can handle this sort of >> non-backwards compatible changes and the compiler back-end and libclc >> have some way to find out whether some specific feature is available and >> e.g. some specific extension should be enabled. >> > > I was thinking the way to do this would be to use calling conventions > on the kernel functions to specify which binary interface to use. > However, I don't want to change the binary interface right now, because > it is still missing a lot of things, and I don't want to have to change > it every time we add something new. > > I think we should keep the current interface of: > Offset | Data > -------------------------|------------------ > 0 : Kernel Arguments > sizeof(Kernel Inputs) : work_dim > sizeof(Kernel Inputs) + 4: ???? > ... > > We can always revisit this once clover is more mature and we think > we have a binary interface that won't change. Although, personally I > prefer adding implicit inputs to the end of the kernel arguments rather > than having of them somewhere else. >
Right, that sounds reasonable to me. Thanks. > -Tom > >> > I assumed it's not safe to modify exec.input, so the input vector is copied >> > before appending work dim. >> > >> >> Why wouldn't it be safe? You just need to make sure they're appended >> before the compute state is created. >> >> > Passes get-work-dim piglit on turks without any regression, >> > I have not tested SI as I don't have the hw. >> > >> > jan >> > >> > >> > >> > >> > Jan Vesely (3): >> > gallium: Pass input data size to launch_grid >> > clover: Add work dimension implicit param to input >> > r600,radeonsi: Copy implicit args provided by clover >> > >> > src/gallium/drivers/ilo/ilo_gpgpu.c | 2 +- >> > src/gallium/drivers/nouveau/nvc0/nvc0_compute.c | 2 +- >> > src/gallium/drivers/nouveau/nvc0/nvc0_context.h | 4 +- >> > src/gallium/drivers/nouveau/nvc0/nve4_compute.c | 2 +- >> > src/gallium/drivers/r600/evergreen_compute.c | 14 +- >> > src/gallium/drivers/r600/evergreen_compute.h | 1 - >> > src/gallium/drivers/radeonsi/si_compute.c | 6 +- >> > src/gallium/include/pipe/p_context.h | 2 +- >> > src/gallium/state_trackers/clover/core/kernel.cpp | 162 >> > ++++++++++++---------- >> > src/gallium/tests/trivial/compute.c | 40 +++--- >> > 10 files changed, 122 insertions(+), 113 deletions(-) >> > >> > -- >> > 1.9.3
pgpdo7ljkXl34.pgp
Description: PGP signature
_______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev