aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/r300/r300_emit.c
Commit message (Collapse)AuthorAgeFilesLines
* r300: drop u_mm.h include.Dave Airlie2017-08-031-1/+0
| | | | | | | This is not used in any of these files. Reviewed-by: Marek Olšák <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
* gallium: decrease the size of pipe_vertex_buffer - 24 -> 16 bytesMarek Olšák2017-05-101-3/+3
|
* gallium/radeon: add RADEON_USAGE_SYNCHRONIZEDNicolai Hähnle2016-09-271-8/+11
| | | | | | | | | | This is really the behavior we want most of the time, but having a SYNCHRONIZED flag instead of an UNSYNCHRONIZED one has the advantage that OR'ing different flags together always results in stronger guarantees. The parent BOs of sub-allocated buffers will be added unsynchronized. Reviewed-by: Marek Olšák <[email protected]>
* r300g: remove support for DRM < 2.12.0Marek Olšák2016-03-011-2/+1
|
* gallium/radeon: remove radeon_winsys_cs_handleMarek Olšák2015-12-111-11/+11
| | | | | | | | "radeon_winsys_cs_handle *cs_buf" is now equivalent to "pb_buffer *buf". Reviewed-by: Nicolai Hähnle <[email protected]> Reviewed-by: Edward O'Callaghan <[email protected]> Reviewed-by: Michel Dänzer <[email protected]>
* gallium/radeon: stop using "reloc" in a few placesMarek Olšák2015-10-031-9/+9
| | | | Reviewed-by: Michel Dänzer <[email protected]>
* gallium/radeon: tell the winsys the exact resource binding typesMarek Olšák2015-10-031-5/+5
| | | | | | | Use the priority flags and expand them. This information will be used for debugging. Reviewed-by: Michel Dänzer <[email protected]>
* Fix a few typosZoë Blade2015-04-271-1/+1
| | | | Reviewed-by: Francisco Jerez <[email protected]>
* r300g: implement pipe_rasterizer_state::clip_halfzMarek Olšák2014-10-221-0/+1
| | | | Reviewed-by: Alex Deucher <[email protected]>
* r300g: don't crash when getting NULL colorbuffersMarek Olšák2014-04-251-9/+16
| | | | Cc: [email protected]
* winsys/radeon: remove cs_write_reloc, add simpler cs_get_relocMarek Olšák2014-04-161-2/+2
| | | | | | | The only difference is that it doesn't write to the CS and only returns the index. Reviewed-by: Christian König <[email protected]>
* r300g,uvd,vce: set priorities for relocationsMarek Olšák2014-03-111-8/+19
| | | | This updates all occurences of cs_add_reloc.
* r300g: fix blending and alpha-test with RGBX16F and enable MSAA for itMarek Olšák2013-02-071-1/+5
|
* r300g: enable AA optimizations for the RGBA16F formatMarek Olšák2013-01-211-0/+5
|
* r300g: fix and cleanup flushing before clearing CMASK, ZMASK, and HIZMarek Olšák2013-01-151-9/+0
|
* r300g: implement MSAA compression and fast MSAA color clearMarek Olšák2013-01-151-2/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | These are optimizations which make MSAA a lot faster. The MSAA work is complete with this commit. (except for enablement of AA optimizations for RGBA16F, for which a patch is ready and waiting until the kernel CS checker fix lands) MSAA can't be made any faster as far as hw programming is concerned. The catch is only one process and one colorbuffer can use the optimizations at a time. There usually is only one MSAA colorbuffer, so it shouldn't be an issue. Also, there is a limit on the size of MSAA colorbuffer resolution in terms of megapixels. If the limit is surpassed, the AA optimizations are disabled. The limit is: - 1 Mpix on low-end and some mid-level chipsets (1024x768 and 1280x720) - 2 Mpix on some mid-level chipsets (1600x1200 and 1920x1080) - 3 or 4 Mpix on high-end chipsets (2048x1536 or 2560x1600, respectively) It corresponds to the number of raster pipes (= GB pipes) available, each pipe can hold 1 Mpix of AA compression data. If it's enabled, the driver prints to stdout: radeon: Acquired access to AA optimizations.
* r300g: don't set sample positions to the pixel center if MSAA is disabledMarek Olšák2013-01-101-8/+4
| | | | | | | | | | | but an MSAA resource is bound. This effectively makes the MSAA disable switch not affect rasterization, but it still affects the alpha-to-one and alpha-to-coverage states. This hardware just lacks a proper MSAA disable switch. This fixes graphics corruption in sauerbraten. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=59194
* r300g: fix CS checker errors caused by emit_dsa_stateMarek Olšák2013-01-091-1/+1
| | | | size is 10 on r500 and 8 on r300
* r300g: fix assertion failure in emit_dsa_stateMarek Olšák2013-01-081-1/+3
| | | | Broken by 8ed6b1400bc8a78f46340f41aaf2e88b24c23267.
* radeon/winsys: move radeon family/class identification to winsysJerome Glisse2013-01-071-2/+2
| | | | | | | | Upcoming async dma support rely on winsys knowing about GPU families. Signed-off-by: Jerome Glisse <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* r300g: implement MSAAMarek Olšák2013-01-061-31/+134
| | | | | | | | | | | | | | | | | | | | | | This is not as optimized as r600g - the MSAA compression is missing, so r300g needs a lot of bandwidth (more than r600g to do the same thing). However, if the bandwidth is not an issue for you, you can enjoy this unoptimized MSAA support. The only other missing optimization for MSAA is the fast color clear. MSAA is enabled on r500 only, because that's the only GPU family I tested. That said, MSAA should work on r300 and r400 as well (but you must set RADEON_MSAA=1 to allow it, then turn MSAA on in your app or set GALLIUM_MSAA=n, n >= 2, n <= 6) I will enable the support by default on r300-r400 once someone (other than me) tests those chipsets with piglit. The supported modes are 2x, 4x, 6x. The supported MSAA formats are RGBA8, BGRA8, and RGBA16F (r500 only). Those 3 formats are used for all GL internal formats. Tested with piglit. (I have ported all MSAA tests to GL2.1)
* r300g: simplify DSA state, add ability to patch FG_ALPHA_FUNC while emittingMarek Olšák2013-01-061-10/+13
| | | | Preparation for MSAA and alpha-to-coverage.
* r300g/swtcl: simplify vertex uploadingMarek Olšák2013-01-041-5/+7
| | | | | | | | - skip the vertex buffer reallocation in flush and just use the unsynchronized flag to get new memory. - remove the cruft needed to get around the issues with the vertex buffer reallocation in flush - use pb_buffer instead of pipe_resource
* r300g: clear the ZB cache before clearing ZMASK or HIZMarek Olšák2012-12-021-0/+6
| | | | | | | This fixes wrong rendering in Lightsmark and the piglit/depthstencil-render-miplevels. I think I fixed Hyper-Z. So far every app seems to work like a charm.
* Revert "r300g: fix occlusion queries when depth test is disabled or zbuffer ↵Marek Olšák2012-12-021-13/+0
| | | | | | is missing" It broke Hyper-Z terribly.
* r300g: fix colormask with non-BGRA formatsMarek Olšák2012-09-141-3/+5
| | | | NOTE: This is a candidate for the stable branches.
* u_vbuf: remove u_vbuf_resourceMarek Olšák2012-04-241-3/+3
|
* u_vbuf: override set_vertex_buffersMarek Olšák2012-04-241-4/+5
|
* r300/compiler: Clear loop registers in vertex shaders w/o loopsTom Stellard2012-04-131-13/+11
| | | | | | | | | | | | | | The loop registers weren't being cleared, so any shader that was executed after a shader containing loops was at risk of having a loop randomly inserted into it. This fixes over one hundred piglit tests, although these test only failed during full piglit runs and would pass if run individually. The exact number of piglit tests that this patch fixes will vary depending on the version of piglit and the order the tests are run. NOTE: This is a candidate for the stable branches.
* winsys/radeon: move managing GEM domains back to driversMarek Olšák2011-12-241-7/+13
| | | | | | | | This partially reverts commit 363ff844753c46ac9c13866627e096b091ea81f8. It caused severe performance drops in Nexuiz. Reported by Phoronix. Tested by me on r300g and by IRC people on r600g.
* r300g: remove useless codeMarek Olšák2011-10-281-2/+2
|
* winsys/radeon: move GEM domains out of the drivers into winsysMarek Olšák2011-09-301-9/+9
| | | | | | | | | | | | | | | The drivers don't need to care about the domains. All they need to set are the bind and usage flags. This simplifies the winsys too. This also fixes on r600g: - fbo-depth-GL_DEPTH_COMPONENT32F-copypixels - fbo-depth-GL_DEPTH_COMPONENT16-copypixels - fbo-depth-GL_DEPTH_COMPONENT24-copypixels - fbo-depth-GL_DEPTH_COMPONENT32-copypixels - fbo-depth-GL_DEPTH24_STENCIL8-copypixels I can't explain it. Reviewed-by: Alex Deucher <[email protected]>
* u_vbuf_mgr: cleanup original vs real vertex buffer arraysMarek Olšák2011-09-261-10/+11
| | | | | | It can now override both buffer offsets and strides in additions to resources. Overriding buffer offsets was kinda hackish and could cause issues with non-native vertex formats.
* winsys/radeon: fix space checkingMarek Olšák2011-08-051-2/+1
| | | | | | | We should remove the relocations which caused a validation failure from the list, so that the kernel receives only the validated ones. NOTE: This is a candidate for the 7.11 branch.
* winsys/radeon: simplify how value queries workMarek Olšák2011-07-251-5/+6
| | | | | This drops the get_value query and adds a function query_info, which returns all the values in one nice structure.
* r300g: set squared microtiling for the dummy zbufferMarek Olšák2011-05-311-1/+1
| | | | The pitch of 4 is allowed for squared microtiling only.
* r300g: fix occlusion queries when depth test is disabled or zbuffer is missingMarek Olšák2011-05-291-0/+13
| | | | | | | | | | | | | | | From now on, depth test is always enabled in hardware. If depth test is disabled in Gallium, the hardware Z function is set to ALWAYS. If there is no zbuffer set, the colorbuffer0 memory is set as a zbuffer to silence the CS checker. This fixes piglit: - occlusion-query-discard - NV_conditional_render/bitmap - NV_conditional_render/drawpixels - NV_conditional_render/vertex_array
* r300g: dynamically ask for and release Hyper-Z accessMarek Olšák2011-05-151-2/+1
| | | | | We ask for Hyper-Z access when clearing a zbuffer. We release it if no zbuffer clear has been done for 2 seconds.
* r300g/winsys: rename r300->radeon and do a little cleanupMarek Olšák2011-04-181-2/+2
| | | | | Renaming a few files, types, and functions. Also make the winsys independent of r300g.
* r300g: fix texturing with sizes > 2048 on r500Marek Olšák2011-04-081-0/+6
|
* r300g: postpone fragment shader state validation until draw_vboMarek Olšák2011-04-051-3/+2
|
* r300g: fix alpha-test with no colorbufferMarek Olšák2011-03-241-0/+5
| | | | | | | Piglit: - fbo-alphatest-nocolor NOTE: This is a candidate for the stable branches.
* r300g: clamp after blending for fixed-point formats onlyMarek Olšák2011-03-141-1/+4
|
* r300g: decide whether a flush should be asynchronous when calling itMarek Olšák2011-03-081-1/+1
| | | | Thread offloading is not sometimes desirable, e.g. when mapping a buffer.
* r300g: implement instanced arraysMarek Olšák2011-03-051-23/+77
|
* r300g: implement FP16 alpha testMarek Olšák2011-03-041-2/+8
|
* r300g: require DRM 2.3.0 (kernel 2.6.34)Marek Olšák2011-03-021-31/+30
| | | | Running any older kernel is not recommended anyway.
* r300g: set the correct HiZ clear valueMarek Olšák2011-03-011-1/+1
|
* r300g: disable HiZ permanently if the the depth function is invertedMarek Olšák2011-03-011-4/+1
| | | | | | | Instead of temporarily. The HiZ function (something like a depth function) is a property of a HiZ buffer and can only be changed during HiZ clears.
* r300g: fix HiZ memory size computation and deciding when to use HiZMarek Olšák2011-03-011-54/+12
| | | | | | | I removed the HiZ memory management, because the HiZ RAM is too small and I also did it in hope that HiZ will be enabled more often. This also sets aligned strides to HIZ_PITCH and ZMASK_PITCH.