summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2014-02-25docs/GL3.txt: add r600g support for ARB_texture_query_lod.r600g-texture-gatherDave Airlie1-1/+1
Signed-off-by: Dave Airlie <airlied@redhat.com>
2014-02-25docs/GL3.txt add texture query levels support.Dave Airlie1-1/+1
All gallium drivers that advertise GLSL 1.30 can do this. Signed-off-by: Dave Airlie <airlied@redhat.com>
2014-02-25r600g: add LODQ supportDave Airlie2-2/+11
This add ARB_texture_query_lod support to r600.
2014-02-25st/mesa: add support for ARB_texture_query_lodDave Airlie2-2/+4
Add support for the LODQ texture instruction. Signed-off-by: Dave Airlie <airlied@redhat.com>
2014-02-25gallium: add support for LODQ opcodes.Dave Airlie16-2/+28
This opcode provide support for GL_ARB_texture_query_lod, Signed-off-by: Dave Airlie <airlied@redhat.com>
2014-02-25st/mesa: add support for ARB_texture_query_levels.Dave Airlie2-8/+20
This assumes anyone who can do GLSL1.30 textureSize can also do query levels, which seems quite likely for nearly all DX10 hw. We call TXQ and swizzle the result from W to the X channel Signed-off-by: Dave Airlie <airlied@redhat.com>
2014-02-25gallium/docs: clarify W channel of TXQ.Dave Airlie1-0/+2
This just specifies the W channel of TXQ is number of levels, like the DX10 RESINFO instruction. Signed-off-by: Dave Airlie <airlied@redhat.com>
2014-02-25r600g: start of TG4 implementationDave Airlie5-17/+130
2014-02-25r600g: limit texture offset applicationDave Airlie1-2/+5
Only apply texture offsets values for the correct type of texture targets. Signed-off-by: Dave Airlie <airlied@redhat.com>
2014-02-25st/mesa: add texture gather support. (v2)Dave Airlie2-27/+93
This adds support for GL_ARB_texture_gather, and one step of support for GL_ARB_gpu_shader5. This adds support for passing the TG4 instruction, along with non-constant texture offsets, and tracking them for the optimisation passes. This doesn't support native textureGatherOffsets hw, to do that you'd need to add a CAP and if set disable the lowering pass, and bump the MAX offsets to 4, then do the i0,j0 sampling using those. Signed-off-by: Dave Airlie <airlied@redhat.com>
2014-02-25gallium: add texture gather support to gallium (v3)Dave Airlie17-2/+73
This adds support to gallium for a TG4 instruction, and two CAPs. The first CAP is required for GL_ARB_texture_gather. The second CAP is required to expose GL_ARB_gpu_shader5. However so far we haven't found any hardware that natively exposes the textureGatherOffsets feature from GL, so just lower it for now. If hardware appears for this we can add another CAP to allow TG4 to take 4 offsets. v2: add component selection src and a cap to say hw can do it. (st can use to help control GL_ARB_gpu_shader5/GLSL 4.00). Add docs. v3: rename to SM5, add docs. Reviewed-by: Roland Scheidegger <sroland@vmware.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
2014-02-25glsl/i965: move lower_offset_array up to GLSL compiler level.Dave Airlie6-12/+9
This lowering pass will be useful for gallium drivers as well, in order to support the GL TG4 oddity that is textureGatherOffsets. Reviewed-by: Chris Forbes <chrisf@ijw.co.nz> Signed-off-by: Dave Airlie <airlied@redhat.com>
2014-02-24clover: Pass buffer offsets to the driver in set_global_binding() v3Tom Stellard4-10/+32
The offsets will be stored in the handles parameter. This makes it possible to use sub-buffers. v2: - Style fixes - Add support for constant sub-buffers - Store handles in device byte order v3: - Use endian helpers Reviewed-by: Francisco Jerez <currojerez@riseup.net>
2014-02-24radeonsi: Use SI_BIG_ENDIAN now that it existsTom Stellard1-1/+1
Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>
2014-02-24r600g: Use util_cpu_to_le32() instead of bswap32() on big-endian systemsTom Stellard3-3/+3
Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>
2014-02-24radeonsi: Use util_cpu_to_le32() instead of bswap32() on big-endian systemsTom Stellard2-2/+2
Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>
2014-02-24util: Add util_cpu_to_le* helpersTom Stellard1-0/+3
Reviewed-by: Michel Dänzer <michel.daenzer@amd.com> Reviewed-by: Francisco Jerez <currojerez@riseup.net>
2014-02-24util: Add util_bswap64() v3Tom Stellard2-0/+17
v2: - Use __builtin_bswap64() - Remove unnecessary mask - Add util_le64_to_cpu() helper v3: - Remove unnecessary AC_SUBST Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>
2014-02-24configure.ac: Use AX_GCC_BUILTIN to check availability of __builtin_bswap32 v2Tom Stellard3-1/+174
v2: - Remove unnecessary AC_SUBST Reviewed-by: Matt Turner <mattst88@gmail.com>
2014-02-24targets/opencl: resolve undefined symbols at link timeEmil Velikov1-0/+1
Current automake build does not try to resolve undefined symbols thus we could end up with a broken library. Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Francisco Jerez <currojerez@riseup.net>
2014-02-24gallium/targets: resolve undefined reference to pipe_loader_sw_probe_driEmil Velikov3-0/+15
With the introduction of the pipe_loader_sw_probe_dri helper we require the sw/dri winsys during linking stage despite it being unused by any of the targets. This will cause a minor increase in the resulting library which will be cleaned up via linker options with upcoming patches. v2: Link with libswdri.la only when available. Reported-and-tested-by: Tom Stellard <thomas.stellard@amd.com> (v1) Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
2014-02-24configure: correctly report if we're building the sw/xlib winsysEmil Velikov1-0/+1
While looking at bug 75356, I've noticed that the presence of x11 egl platform pulls in sw/xlib as "needed" but fails to report so at the end of configure. Tested-by: Tom Stellard <thomas.stellard@amd.com> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
2014-02-24pipe-loader: wrap pipe_loader_sw_probe_xlib within HAVE_PIPE_LOADER_XLIBEmil Velikov8-7/+41
The above function implies using the the xlib winsys, which has additional library dependencies that should not be forced. Make the software xlib pipe loader optional thus avoid all the dependency hell. A user that wishes to use the particular pipe-loader would need to set the following within configure.ac. enable_gallium_xlib_loader=yes v2: - Wrap sw/xlib/xlib_sw_winsys.h to handle compilation on systems lacking X11 headers. Spotted by Christian Prochaska. Tested-by: Tom Stellard <thomas.stellard@amd.com> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=75356 Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
2014-02-24targets/gbm: exit gracefully if pipe_loader_drm_probe_fd is not availableEmil Velikov1-3/+4
When one builds without gallium_drm_loader, the above function will not be available, thus we'll segfault in gallium_screen_create due to memory access violation. Tested-by: Tom Stellard <thomas.stellard@amd.com> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=75335 Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
2014-02-23i965: Don't try to use the hardware blitter for multisampled miptrees.Kenneth Graunke1-0/+4
The blitter is completely ignorant of MSAA buffer layouts, so any attempt to use BLT paths with MSAA buffers is likely to break spectacularly. In most cases, BLORP handles MSAA blits, so we never hit this bug. Until recently, it also wasn't worth fixing, since Meta couldn't handle MSAA either, so there was nothing to fall back to. But now there is. +143 piglit tests on Broadwell (which doesn't have BLORP support). Surprisingly, three also start failing. Since non-IMS MSAA buffers store samples in successive array slices, using the blitter ought to access sample 0 and ignore the rest, which is apparently good enough for a few not-very-picky Piglit tests. Presumably the meta replacement code is still broken. No Piglit changes on Ivybridge. v2: Move the early return to the top of the function (suggested by Paul). Signed-off-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Paul Berry <stereotype441@gmail.com>
2014-02-23freedreno/a3xx/compiler: half-precision outputRob Clark6-10/+130
Using generic shaders caused a measurable fps drop, which was isolated to use of full precision (vs half precision) output. This is an attempt to regain that lost performance by using half precision solid/blit shaders (when the output format is not float32). Note: for the built-in shaders, I would not expect them to be register starved. And in fact it is the solid frag shader that seems to have the biggest impact. So I suspect you get double the pixel pipe units (or half the cycles) when the output is half precision. So there may be some gain to using half precision output for application shaders as well, even though the rest of register usage is still full precision. But for half precision to work for more complex shaders, we need to deal with some constraints, like cat2 needing same precision for it's two src registers. So for now it is not enabled by default except for the built-in shaders. Signed-off-by: Rob Clark <robclark@freedesktop.org>
2014-02-23freedreno/a3xx: add shader variantsRob Clark10-196/+283
Start putting in place infrastructure to deal with multiple shader variants. Initially we'll use this for two sided color (frag) and binning pass (vert) shaders. Possibly need for others later (such as YUV vs RGB eglImage?). Signed-off-by: Rob Clark <robclark@freedesktop.org>
2014-02-23freedreno/a3xx/compiler: collapse nop's with repeatRob Clark2-0/+15
Easier than making more extensive use of rpt, and the more compact shaders seem to bring some bit of performance boost. (Perhaps repeat flag benefits are more than just instruction cache, possibly it saves on instruction decode as well?) Signed-off-by: Rob Clark <robclark@freedesktop.org>
2014-02-23freedreno/a3xx: drop hand-coded blit/solid shadersRob Clark10-287/+181
Instead in the common code, construct these shaders from TGSI. For now we let a2xx keep it's hand coded shaders, as it's compiler isn't quite up to the job yet. All the same it is a net drop in code size and gets rid of special cases. Signed-off-by: Rob Clark <robclark@freedesktop.org>
2014-02-23freedreno/lowering: cleanup apiRob Clark5-24/+138
Make things configurable, and tweak the API a bit to avoid an extra tgsi_shader_scan(). Getting closer to something generic which can be moved out of freedreno and shaderd by other drivers. Signed-off-by: Rob Clark <robclark@freedesktop.org>
2014-02-23freedreno/a3xx: add float 16 and 32bit formatsRob Clark1-0/+22
Signed-off-by: Rob Clark <robclark@freedesktop.org>
2014-02-23freedreno: resync generated headersRob Clark4-4/+20
Signed-off-by: Rob Clark <robclark@freedesktop.org>
2014-02-23glx/drisw: use the implemented version of __DRIswrastLoaderExtensionEmil Velikov1-5/+6
... over the one provided by the headers. Explicitly set extension members to improve clarity. Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2014-02-23glx/dri: use the implemented version of __DRIdamageExtensionEmil Velikov1-2/+3
... over the one provided by the headers. Explicitly set extension members to improve clarity. Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2014-02-23glx/dri_common: use the implemented version of __DRIsystemTimeExtensionEmil Velikov1-3/+4
... over the one provided by the headers. Explicitly set extension members to improve clarity. Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2014-02-23glx/dri: use the implemented version of __DRIgetDrawableInfoExtensionEmil Velikov1-2/+3
... over the one provided by the headers. Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2014-02-23dri_util: use the implemented version of __DRIimageDriverExtensionEmil Velikov1-1/+1
... over the one provided by the headers. Currently both versions are identical, but that is not guaranteed to be the case in the future. Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2014-02-23glx/dri3: set the implemented version of __DRIimageLoaderExtensionEmil Velikov1-3/+4
... over the one provided by the spec. Currently both versions are identical, but that is not guaranteed to be the case in the future. Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2014-02-23gbm: explicitly set __DRIimageLoaderExtension membersEmil Velikov1-3/+4
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2014-02-23egl/wayland: explicitly set __DRIimageLoaderExtension membersEmil Velikov1-3/+4
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>y
2014-02-23drivers/dri: explicitly set __DRI2flushExtension membersEmil Velikov2-6/+8
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>y
2014-02-23gbm: explicitly set __DRIdri2LoaderExtension membersEmil Velikov1-4/+5
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>y
2014-02-23glx/dri2: set the implemented version of __DRIdri2LoaderExtensionEmil Velikov1-8/+10
... over the version number provided by the headers. Explicitly set extension members to improve clarity. Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2014-02-23dri_interface: note introduction of __DRIdri2LoaderExtension membersEmil Velikov1-0/+4
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2014-02-23dri_interface: note introduction of various __DRItexBufferExtension membersEmil Velikov1-0/+4
Note the member function releaseTexBuffer was added without bumping spec version, and currently no drivers implement it. v2: releaseTexBuffer was introduced by version 3 Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2014-02-23dri_interface: Note the version introducing ↵Emil Velikov1-0/+2
__DRIswrastLoaderExtensionRec::putImage2 Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2014-02-23dri_util: explicitly set __DRIcopySubBufferExtension membersEmil Velikov1-2/+3
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2014-02-23dri_util: explicitly set __DRIswrastExtension members.Emil Velikov1-6/+7
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2014-02-22glsl: Pass stdout to _mesa_print_ir from st_glsl_to_tgsi.Kenneth Graunke1-1/+1
Fixes the Gallium build since commit 1e3bd9f9a5af90295788c5d71ea27c. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=75389 Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
2014-02-22i965: Move the remaining driver debug over to stderr.Eric Anholt12-63/+66
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Matt Turner <mattst88@gmail.com>