summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers
Commit message (Collapse)AuthorAgeFilesLines
...
* freedreno: update generated headersRob Clark2015-03-127-16/+45
| | | | | | | | Signed-off-by: Rob Clark <[email protected]> (cherry picked from commit fb1301e40abbac1de973563cacd2c7f31aa6bb4f) Conflicts: src/gallium/drivers/freedreno/a3xx/a3xx.xml.h
* freedreno/a4xx: bit of cleanupRob Clark2015-03-124-33/+27
| | | | | Signed-off-by: Rob Clark <[email protected]> (cherry picked from commit bdf023482a6fd07adef090fb66a4aaaac22810fc)
* freedreno/a2xx: fix increment in assertRob Clark2015-03-121-1/+2
| | | | | | Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=88883 Signed-off-by: Rob Clark <[email protected]> (cherry picked from commit 68552266535747bad1eff34d856c43158398b9bf)
* r300g: fix sRGB->sRGB blitsMarek Olšák2015-03-111-0/+9
| | | | | Cc: 10.5 10.4 <[email protected]> (cherry picked from commit c939231e7223510408a446400ad23b8b5ce2922e)
* r300g: fix a crash when resolving into an sRGB textureMarek Olšák2015-03-111-3/+5
| | | | | Cc: 10.5 10.4 <[email protected]> (cherry picked from commit 9953586af2254f83a610d4cd284f52f37fa18b98)
* r300g: fix RGTC1 and LATC1 SNORM formatsMarek Olšák2015-03-112-31/+17
| | | | | Cc: 10.5 10.4 <[email protected]> (cherry picked from commit 74a757f92f7377f59c0feb7f84c7518f9a167631)
* r300g: Fix the ATI1N swizzle (RGTC1 and LATC1)Stefan Dösinger2015-03-111-1/+3
| | | | | | | | | | | | | | | | | | | | | | This fixes the GL_COMPRESSED_RED_RGTC1 part of piglit's rgtc-teximage-01 test as well as the precision part of Wine's 3dc format test (fd.o bug 89156). The Z component seems to contain a lower precision version of the result, probably a temporary value from the decompression computation. The Y and W component contain different data that depends on the input values as well, but I could not make sense of them (Not that I tried very hard). GL_COMPRESSED_SIGNED_RED_RGTC1 still seems to have precision problems in piglit, and both formats are affected by a compiler bug if they're sampled by the shader with a swizzle other than .xyzw. Wine uses .xxxx, which returns random garbage. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=89156 Signed-off-by: Marek Olšák <[email protected]> Cc: 10.5 10.4 <[email protected]> (cherry picked from commit f710b99071fe4e3c2ee88cdcb6bb5c10298e014e)
* freedreno/ir3: fix silly typo for binning pass shadersRob Clark2015-03-111-1/+1
| | | | | | | | | | Was resulting in gl_PointSize write being optimized out, causing particle system type shaders to hang if hw binning enabled. Fixes neverball, OGLES2ParticleSystem, etc. Signed-off-by: Rob Clark <[email protected]> (cherry picked from commit 60096ed906e5ebfdce41024c7af69f03b96dbe82)
* freedreno/ir3: get the # of miplevels from getinfoIlia Mirkin2015-03-111-0/+20
| | | | | | | | | | This fixes ARB_texture_query_levels to actually return the desired value. Signed-off-by: Ilia Mirkin <[email protected]> Reviewed-by: Rob Clark <[email protected]> Cc: "10.4 10.5" <[email protected]> (cherry picked from commit cb3eb43ad690a7355429ba8dcd40120646c55b9c)
* freedreno/ir3: fix array count returned by TXQIlia Mirkin2015-03-111-2/+42
| | | | | | | Signed-off-by: Ilia Mirkin <[email protected]> Reviewed-by: Rob Clark <[email protected]> Cc: "10.4 10.5" <[email protected]> (cherry picked from commit 8ac957a51c67fc095db9539df6482b9533b1d05c)
* freedreno: move fb state copy after checking for size changeIlia Mirkin2015-03-111-2/+2
| | | | | | | | Fixes: 1f3ca56b ("freedreno: use util_copy_framebuffer_state()") Signed-off-by: Ilia Mirkin <[email protected]> Reviewed-by: Rob Clark <[email protected]> Cc: "10.4 10.5" <[email protected]> (cherry picked from commit f3dfe6513c26d1ce50b3b0fc830d4d8ff7f6b922)
* r300g: Check return value of snprintf().Matt Turner2015-03-071-1/+6
| | | | | | | | | Would have at least prevented the crash the previous patch fixed. Cc: 10.4, 10.5 <[email protected]> Bugzilla: https://bugs.gentoo.org/show_bug.cgi?id=540970 Reviewed-by: Tom Stellard <[email protected]> (cherry picked from commit ade0b580e75bdea227eec5345f6681b678d0811b)
* r300g: Use PATH_MAX instead of limiting ourselves to 100 chars.Matt Turner2015-03-071-3/+3
| | | | | | | | | | | When built with Gentoo's package manager, the Mesa source directory exists seven directories deep. The path to the .test file is too long and is silently truncated, leading to a crash. Just use PATH_MAX. Cc: 10.4, 10.5 <[email protected]> Bugzilla: https://bugs.gentoo.org/show_bug.cgi?id=540970 Reviewed-by: Tom Stellard <[email protected]> (cherry picked from commit f5e2aa1324dd6a9666bb21834097d2fbc3cb99b6)
* r600g/sb: treat undefined values like constantsDave Airlie2015-02-271-2/+2
| | | | | | | | | | | | | When we schedule an instructions with undefined value, we eventually will use 0, which is a constant, however sb wasn't taking this into account and creating ops with illegal scalar swizzles. this replaces my fix for op3 in t slots. Reviewed-by: Glenn Kennard <[email protected]> Signed-off-by: Dave Airlie <[email protected]> (cherry picked from commit e8e4437ed0660b3f1d1912f53d997cf5e25f486d)
* radeonsi: fix point spritesMarek Olšák2015-02-241-1/+1
| | | | | | | | | | | | | | | | Broken by a27b74819ad375e8c0bc88e13f42c951d2b5cd6a. This fix is critical and should be ported to stable ASAP. Cc: 10.5 10.4 <[email protected]> (cherry picked from commit 7820a11e3dea2aca8e2b9b4ed9faf94ff5696990) Squashed with commit radeonsi: fix a warning caused by previous commit Cc: 10.5 10.4 <[email protected]> (cherry picked from commit 050bf75c8bbaa7cad537aabaf8612129edfee3a4)
* radeonsi: don't use SQC_CACHES to flush ICACHE and KCACHE on SIMarek Olšák2015-02-241-18/+11
| | | | | | | | | | | | | | | | This reverts 73c2b0d18c51459697d8ec194ecfc4438c98c139. It doesn't seem to be reliable. It's probably missing a wait packet or something, because it's just a register write and doesn't wait for anything. SURFACE_SYNC at least seems to wait until the flush is done. Just guessing. Let's not complicate things and revert this. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=88561 Cc: 10.5 <[email protected]> Reviewed-by: Alex Deucher <[email protected]> (cherry picked from commit 7692704b144b2aa9a57767a43212ceb5aad6638a)
* Revert "radeon/llvm: enable unsafe math for graphics shaders"Michel Dänzer2015-02-241-4/+0
| | | | | | | | | | | | This reverts commit 0e9cdedd2e3943bdb7f3543a3508b883b167e427. It caused the grass to disappear in The Talos Principle. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=89069 Cc: "10.5 10.4" <[email protected]> Reviewed-by: Tom Stellard <[email protected]> Reviewed-by: Marek Olšák <[email protected]> (cherry picked from commit 4db985a5fa9ea985616a726b1770727309502d81)
* radeonsi: fix a crash if a stencil ref state is set before a DSA stateMarek Olšák2015-02-241-4/+8
| | | | | | | | | | | | | + minor indentation fixes Discovered by Axel Davy. This can't be reproduced with any app, because all state trackers set a DSA state first. Cc: 10.5 10.4 10.3 <[email protected]> Reviewed-by: Axel Davy <[email protected]> (cherry picked from commit 2ead74888a70481aa40b5b6ede42279e1917e66c)
* radeonsi: small fix in SPI stateMarek Olšák2015-02-241-2/+4
| | | | | | Cc: 10.5 10.4 <[email protected]> Reviewed-by: Michel Dänzer <[email protected]> (cherry picked from commit a27b74819ad375e8c0bc88e13f42c951d2b5cd6a)
* nvc0: allow holes in xfb target listsIlia Mirkin2015-02-242-4/+13
| | | | | | | | | Tested with a modified xfb-streams test which outputs to streams 0, 2, and 3. Signed-off-by: Ilia Mirkin <[email protected]> Cc: "10.4 10.5" <[email protected]> (cherry picked from commit 854eb06bee7d266fc739f984c1b4ebb54dac3b87)
* nvc0: bail out of 2d blits with non-A8_UNORM alpha formatsIlia Mirkin2015-02-241-2/+5
| | | | | | | | | This fixes the teximage-colors uploads with GL_ALPHA format and non-GL_UNSIGNED_BYTE type. Signed-off-by: Ilia Mirkin <[email protected]> Cc: "10.4 10.5" <[email protected]> (cherry picked from commit 68e4f3f572b1e629f32a73ae618dc0b016f631b1)
* r600g/sb: fix a bug in constants folding optimisation passXavier Bouchoux2015-02-061-0/+2
| | | | | | | | | | | | | | | ADD R6.y.1, R5.w.1, ~1|3f800000 ADD R6.y.2, |R6.y.1|, -0.0001|b8d1b717 was wrongly being converted to ADD R6.y.1, R5.w.1, ~1|3f800000 ADD R6.y.2, R5.w.1, -1.0001|bf800347 because abs() modifier was ignored. Signed-off-by: Xavier Bouchoux <[email protected]> Reviewed-by: Glenn Kennard <[email protected]>
* r600g: fix abs() support on ALU 3 source operands instructionsXavier Bouchoux2015-02-063-7/+63
| | | | | | | | Since alu does not support abs() modifier on source operands, spill and apply the modifiers to a temp register when needed. Signed-off-by: Xavier Bouchoux <[email protected]> Reviewed-by: Glenn Kennard <[email protected]>
* r300g: small code cleanup (v2)David Heidelberg2015-02-064-26/+4
| | | | | | | v2: incorporated changes from Marek Olšák Reviewed-by: Marek Olšák <[email protected]> Signed-off-by: David Heidelberg <[email protected]>
* gallium: Add MULTISAMPLE_Z_RESOLVE capAxel Davy2015-02-0613-0/+16
| | | | | | | | | | | | | | | | Resolving a multisampled depth texture into a single sampled texture is supported on >= SM4.1 hw. It is possible some previous hw support it. The ability was tested on radeonsi and nvc0. Apparently is is also supported for radeon >= r700. This patch adds the MULTISAMPLE_Z_RESOLVE cap and add it to the drivers. It is advertised for drivers for which it is sure the ability is supported. Reviewed-by: Marek Olšák <[email protected]> Signed-off-by: Axel Davy <[email protected]>
* llvmpipe: Trivially advertise PIPE_CAP_BUFFER_MAP_PERSISTENT_COHERENT.Jose Fonseca2015-02-051-1/+2
| | | | | | | | | | | Nothing special needs to be done. Even though llvmpipe copies constant (ie uniform) buffers internally, the application is supposed to flush and sync, so all should work. All bufferstorage piglit tests pass. Reviewed-by: Roland Scheidegger <[email protected]>
* radeonsi: implement polygon stipplingMarek Olšák2015-02-047-5/+79
| | | | Reviewed-by: Michel Dänzer <[email protected]>
* radeonsi: add polygon stipple texture slotMarek Olšák2015-02-041-5/+8
| | | | Reviewed-by: Michel Dänzer <[email protected]>
* radeonsi: deduce rasterizer primitive type at the beginning of draw_vboMarek Olšák2015-02-042-13/+17
| | | | | | I will need this for polygon stippling. Reviewed-by: Michel Dänzer <[email protected]>
* radeonsi: allow 64 descriptors per arrayMarek Olšák2015-02-042-34/+34
| | | | | | | We need a slot for the stipple texture and the pixel shader already uses 32 textures (16 API slots + 16 FMASK slots). Reviewed-by: Michel Dänzer <[email protected]>
* radeonsi: add support for sampler views where resource = NULLMarek Olšák2015-02-042-6/+22
| | | | | | | The hardware obeys swizzles even if the resource is NULL. This will be used by set_polygon_stipple. Reviewed-by: Michel Dänzer <[email protected]>
* radeonsi: add support for NULL texture sampler views that return (0,0,0,1)Marek Olšák2015-02-041-2/+28
| | | | | | This used to hang. Reviewed-by: Michel Dänzer <[email protected]>
* radeonsi: fix a crash when binding a NULL sampler view listMarek Olšák2015-02-041-1/+1
| | | | Reviewed-by: Michel Dänzer <[email protected]>
* radeonsi: move the buffer descriptor to the end of the image descriptorMarek Olšák2015-02-044-7/+9
| | | | | | This will allow supporting NULL textures. Reviewed-by: Michel Dänzer <[email protected]>
* radeonsi: don't use tgsi_parse_context to get processor typeMarek Olšák2015-02-041-7/+1
| | | | | | Also remove unused "tokens". Reviewed-by: Michel Dänzer <[email protected]>
* radeonsi: fix instanced arrays with non-zero start instanceMarek Olšák2015-02-041-3/+3
| | | | | | | Fixes piglit ARB_base_instance/arb_base_instance-drawarrays. Cc: 10.3 10.4 <[email protected]> Reviewed-by: Michel Dänzer <[email protected]>
* r600g,radeonsi: don't append to streamout buffers that haven't been used yetMarek Olšák2015-02-042-1/+4
| | | | | | | | | | | | The FILLED_SIZE counter is uninitialized at the beginning, so we can't use it. Instead, use offset = 0, which is what we always do when not appending. This unexpectedly fixes spec/ARB_texture_multisample/sample-position/*. Yes, the test does use transform feedback. Cc: 10.3 10.4 <[email protected]> Reviewed-by: Glenn Kennard <[email protected]> Reviewed-by: Michel Dänzer <[email protected]>
* gallium/u_pstipple: add ability to specify a fixed texture unitMarek Olšák2015-02-041-1/+1
| | | | | | | E.g. r600g can use slot 17, which is outside of the API range. Reviewed-by: Glenn Kennard <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* tgsi: add tgsi_get_processor_type helper from radeonMarek Olšák2015-02-041-11/+0
| | | | | Reviewed-by: Glenn Kennard <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* gallium: add a cap to determine whether the driver supports offset_clampIlia Mirkin2015-02-0213-0/+16
| | | | | | Signed-off-by: Ilia Mirkin <[email protected]> Reviewed-by: Glenn Kennard <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* dir-locals.el: Don't set variables for non-programming modesNeil Roberts2015-02-026-6/+6
| | | | | | | | | | | | | | This limits the style changes to modes inherited from prog-mode. The main reason to do this is to avoid setting fill-column for people using Emacs to edit commit messages because 78 characters is too many to make it wrap properly in git log. Note that makefile-mode also inherits from prog-mode so the fill column should continue to apply there. v2: Apply to all the .dir-locals.el files, not just the one in the root directory. Acked-by: Michel Dänzer <[email protected]>
* vc4: Kill a bunch of color write calculation when colormask is all off.Eric Anholt2015-02-011-8/+35
| | | | | | | | | | | | | I could have done this in the bit that generates the ANDs and ORs, but it's probably generally useful. Sadly, I still need this even if I move to NIR, because I can't yet express my read of the destination color in NIR, which I would need to move my blend/logicop/colormask handling into NIR. total uniforms in shared programs: 13497 -> 13455 (-0.31%) uniforms in affected programs: 101 -> 59 (-41.58%) total instructions in shared programs: 40797 -> 40296 (-1.23%) instructions in affected programs: 1639 -> 1138 (-30.57%)
* vc4: Dump the VPM read index in QIR disasm.Eric Anholt2015-02-011-4/+9
| | | | | Since the VPM reads have to be in order, it's useful to see their indices in the dump.
* vc4: Fix point size handling when it's the first output.Eric Anholt2015-01-291-1/+1
|
* gallium: Replace u_simple_list.h with util/simple_list.hEric Anholt2015-01-2817-22/+17
| | | | | | | The code was exactly the same, except util/ has c++ guards and a struct simple_node declaration. Reviewed-by: Marek Olšák <[email protected]>
* radeonsi: Enable VGPR spilling for all shader types v5Tom Stellard2015-01-288-52/+217
| | | | | | | | | | | | | | | | | | | | v2: - Only emit write SPI_TMPRING_SIZE once per packet. - Use context global scratch buffer. v3: - Patch shaders using WRITE_DATA packet instead of map/unmap. - Emit ICACHE_FLUSH, CS_PARTIAL_FLUSH, PS_PARTIAL_FLUSH, and VS_PARTIAL_FLUSH when patching shaders. v4: - Code cleanups. - Remove unnecessary multiplies. v5: - Patch shaders in system memory and re-upload to vram. Reviewed-by: Michel Dänzer <[email protected]>
* radeonsi/compute: Allocate the scratch buffer during state creationTom Stellard2015-01-282-24/+62
| | | | | | | | | | This moves scratch buffer allocation from si_launch_grid() to si_create_compute_state(). This helps to reduce the overhead of launching a kernel and also fixes a bug in the code that would cause the scratch buffer to be too small if a kernel with smaller scratch size was launched before a kernel with a larger scratch size. Reviewed-by: Michel Dänzer <[email protected]>
* radeonsi: Add radeon_shader_binary member to struct si_shaderTom Stellard2015-01-282-6/+6
| | | | Reviewed-by: Michel Dänzer <[email protected]>
* radeonsi/compute: Rename si_compute::program to si_compute::shaderTom Stellard2015-01-281-5/+5
| | | | Reviewed-by: Michel Dänzer <[email protected]>
* radeonsi: Avoid leaking memory when rebuilding shader statesMarek Olšák2015-01-283-4/+13
| | | | Reviewed-by: Michel Dänzer <[email protected]>