summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2016-03-21glsl: non-constant indexes of ssbo arrays are always allowed in OpenGLssboNicolai Hähnle1-2/+8
ARB_shader_storage_buffer_object already says so. Actually, the language of that extension also implicitly allows non-constant indexes for ubo arrays, which this patch does not address. I'm not sure that it should, since this is such a weird corner of spec lawyering. Cc: Ilia Mirkin <imirkin@alum.mit.edu>
2016-03-21st/mesa: allow GLSL version up to 4.20Nicolai Hähnle1-2/+2
2016-03-21radeonsi: enable GLSL 4.20Nicolai Hähnle1-1/+2
All driver-specific functionality has already been implemented as part of extensions.
2016-03-21docs: mark atomic counters and SSBOs as done for radeonsiNicolai Hähnle2-7/+9
While I'm at it, add the image extensions in the GL ES section of GL3.txt.
2016-03-21radeonsi: enable shader buffer pipe capsNicolai Hähnle2-2/+4
2016-03-21radeonsi: add shader buffer support to TGSI_OPCODE_RESQNicolai Hähnle1-6/+11
2016-03-21radeonsi: add shader buffer support to TGSI_OPCODE_STORENicolai Hähnle1-18/+111
2016-03-21radeonsi: add shader buffer support to TGSI_OPCODE_LOADNicolai Hähnle1-19/+70
2016-03-21radeonsi: add shader buffer support to TGSI_OPCODE_ATOM*Nicolai Hähnle1-15/+46
2016-03-21radeonsi: add offset parameter to buffer_append_argsNicolai Hähnle1-5/+10
2016-03-21radeonsi: adjust buffer_append_args to take a 128 bit resourceNicolai Hähnle1-7/+23
Move the buffer resource extraction code out into its own function.
2016-03-21radeonsi: preload shader buffers in shadersNicolai Hähnle1-0/+17
2016-03-21radeonsi: implement set_shader_buffersNicolai Hähnle4-58/+123
2016-03-21radeonsi: move resetting of constant buffers into a separate functionNicolai Hähnle1-15/+26
This will be re-used for shader buffers.
2016-03-21radeonsi: fix out-of-bounds indexing of shader imagesNicolai Hähnle1-1/+43
Results are undefined but may not crash. Without this change, out-of-bounds indexing can lead to VM faults and GPU hangs. Constant buffers, samplers, and possibly others will eventually need similar treatment to support GL_ARB_robust_buffer_access_behavior.
2016-03-21radeonsi: cache flush/invalidation for missing PIPE_BARRIER_*_BUFFER bits (v2)Nicolai Hähnle1-2/+12
This fixes arb_shader_image_load_store-host-mem-barrier. v2: flush TC L2 for index buffers on <= CIK (Marek)
2016-03-21st/mesa: add missing MemoryBarrier bits and some explanationsNicolai Hähnle1-1/+24
2016-03-21gallium: add PIPE_BARRIER_STREAMOUT_BUFFERNicolai Hähnle1-0/+1
2016-03-21docs: mark GL_ARB_shader_image_load_store/_size as done for radeonsiNicolai Hähnle2-2/+4
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21radeonsi: Set PIPE_SHADER_CAP_MAX_SHADER_IMAGESEdward O'Callaghan1-1/+2
This enables ARB_shader_image_load_store and ARB_shader_image_size. Signed-off-by: Edward O'Callaghan <eocallaghan@alterapraxis.com> [allow the same number of images for all shader stages and require LLVM 3.9] Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21radeonsi: disable early Z if the fragment shader writes to memoryNicolai Hähnle1-2/+12
Empirically, both the EXEC_ON_* flags and LATE_Z are necessary. Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21tgsi/scan: add writes_memory to flag presence of stores or atomicsNicolai Hähnle2-4/+9
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21radeonsi: force the DCC enable bit off in image descriptors for writing (v2)Nicolai Hähnle1-8/+49
This avoids a lockup at least on Tonga. v2: only force DCC off on VI+ (Marek) Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21radeonsi: implement MemoryBarrier (v2)Nicolai Hähnle1-0/+37
v2: invalidate both constant and VMEM/TC L1 for constant buffers (Marek) Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21radeonsi: implement volatile memory accessNicolai Hähnle1-0/+4
Prevent loads from being re-ordered or coalesced. Atomics don't need special handling by definition, and stores don't need special handling because LLVM is unable to detect dead image or buffer stores. Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21radeonsi: implement coherent memory access (v2)Nicolai Hähnle1-4/+13
v2: set glc=1 for volatile also on buffers Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21radeonsi: Lower TGSI_OPCODE_MEMBAR down to LLVM opNicolai Hähnle1-0/+31
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21radeonsi: Lower TGSI_OPCODE_ATOM* down to LLVM opNicolai Hähnle1-8/+113
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21radeonsi: Lower TGSI_OPCODE_STORE down to LLVM opNicolai Hähnle1-3/+80
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21radeonsi: Lower TGSI_OPCODE_LOAD down to LLVM op (v3)Nicolai Hähnle1-0/+139
v2: new signature style for buffer intrinsics (offsets) v3: new signature style for llvm.amdgcn.buffer.load.format (overloaded return) Reviewed-by: Marek Olšák <marek.olsak@amd.com> (v2)
2016-03-21radeonsi: extract the LLVM type name construction into its own functionNicolai Hähnle1-7/+19
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21radeonsi: Lower TGSI_OPCODE_RESQ down to LLVM opNicolai Hähnle1-0/+129
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21radeonsi: extract TXQ buffer size computation into its own functionNicolai Hähnle1-20/+35
This will allow it to be reused for RESQ. Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21radeonsi: decompress shader imagesNicolai Hähnle1-3/+33
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21radeonsi: update shader image descriptor for invalidated bufferNicolai Hähnle1-1/+21
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21radeonsi: implement set_shader_images (v2)Nicolai Hähnle6-29/+254
Whether DCC is disabled depends on the access flags with which the image is bound: image_load supports DCC, but store and atomic don't. v2: remove an unnecessary masking of images->desc.enabled_mask Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21gallium/radeon: make r600_texture_disable_dcc externally accessibleNicolai Hähnle2-2/+4
We will need it in radeonsi for shader images. Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21tgsi/scan: track which shader images are really buffersNicolai Hähnle2-0/+7
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21tgsi/scan: add images_writemaskNicolai Hähnle2-2/+21
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21st/mesa: translate additional flags in MemoryBarrierNicolai Hähnle1-3/+18
Re-order flags in the order in which they appear in the OpenGL spec in the description of MemoryBarrier(). Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21gallium: add additional PIPE_BARRIER_* bitsNicolai Hähnle1-0/+7
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21st/mesa: use the texture view's format for render-to-textureNicolai Hähnle1-7/+15
Aside from the bug below, it fixes a simplistic test I've written locally, and I see no regression in Piglit for radeonsi. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94595 Cc: "11.0 11.1 11.2" <mesa-stable@lists.freedesktop.org> Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-03-21gallium: Remove unused TGSI_RESOURCE_ definesHans de Goede1-9/+0
These magic file-index defines where only ever used in the nouveau code and that no longer uses them. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> (v2) Reviewed-by: Marek Olšák <marek.olsak@amd.com> (v2)
2016-03-21nouveau: codegen: Do not silently fail in handeLOAD / handleSTORE / handleATOMHans de Goede1-9/+18
handeLOAD / handleSTORE / handleATOM can only handle TGSI_FILE_BUFFER and TGSI_FILE_MEMORY. Make things fail explictly when another register-file is used in these functions. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> (v2)
2016-03-21nouveau: codegen: Disable more old resource handling codeHans de Goede1-3/+12
Commit c3083c7082 ("nv50/ir: add support for BUFFER accesses") disabled / commented out some of the old resource handling code, but not all of it. Effectively all of it is dead already, if we ever enter the old code paths in handeLOAD / handleSTORE / handleATOM we will get an exception due to trying to access the now always zero-sized resources vector. Disable all the dead code. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> (v2)
2016-03-21nouveau: codegen: gk110: Make emitSTORE offset handling identical to emitLOADHans de Goede1-3/+1
Make the store offset handling in CodeEmitterGK110::emitSTORE identical to the one in CodeEmitterGK110::emitLOAD handling. This is just a cleanup, it does not cause any functional changes. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
2016-03-21nouveau: codegen: Slightly refactor Source::scanInstruction() dst handlingHans de Goede1-6/+6
Use the dst temp variable which was used in the TGSI_FILE_OUTPUT case everywhere. This makes the code somewhat easier to reads and helps avoiding going over 80 chars with upcoming changes. This also brings the dst handling more in line with the src handling. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
2016-03-21nouveau: codegen: Add support for clover / OpenCL kernel input parametersHans de Goede1-3/+15
Add support for clover / OpenCL kernel input parameters. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu> (v1) Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> (v2)
2016-03-21tgsi: Add support for global / private / input MEMORYHans de Goede8-26/+51
Extend the MEMORY file support to differentiate between global, private and shared memory, as well as "input" memory. "MEMORY[x], INPUT" is intended to access OpenCL kernel parameters, a special memory type is added for this, since the actual storage of these (e.g. UBO-s) may differ per implementation. The uploading of kernel parameters is handled by launch_grid, "MEMORY[x], INPUT" allows drivers to use an access mechanism for parameter reads which matches with the upload method. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu> (v1) Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> (v2)
2016-03-21tgsi: Fix decl.Atomic and .Shared not propagating when parsing tgsi textHans de Goede1-0/+6
When support for decl.Atomic and .Shared was added, tgsi_build_declaration was not updated to propagate these properly. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu> (v1) Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> (v2)