summaryrefslogtreecommitdiffstats
path: root/src/gallium/state_trackers/xa/xa_context.c
Commit message (Collapse)AuthorAgeFilesLines
* gallium: add a pipe_context parameter to fence_finishMarek Olšák2016-08-101-1/+1
| | | | | | | | required by glClientWaitSync (GL 4.5 Core spec) that can optionally flush the context Reviewed-by: Rob Clark <robdclark@gmail.com> Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
* gallium: add flags parameter to pipe_screen::context_createMarek Olšák2015-08-261-1/+1
| | | | | | | | This allows creating compute-only and debug contexts. Reviewed-by: Brian Paul <brianp@vmware.com> Acked-by: Christian König <christian.koenig@amd.com> Acked-by: Alex Deucher <alexander.deucher@amd.com>
* xa: don't leak fencesRob Clark2015-07-101-1/+5
| | | | | | | | | | | | XA was never unref'ing last_fence in the various call paths to pipe->flush(). Add this to xa_context_flush() and update the other open-coded calls to pipe->flush() to use xa_context_flush() instead. This fixes a memory leak reported with xf86-video-freedreno. Reported-by: Nicolas Dechesne <nicolas.dechesne@linaro.org> Cc: "10.5 10.6" <mesa-stable@lists.freedesktop.org> Signed-off-by: Rob Clark <robclark@freedesktop.org>
* cso: put cso_release_all into cso_destroy_contextMarek Olšák2014-12-101-1/+0
| | | | Reviewed-by: Brian Paul <brianp@vmware.com>
* st/xa: Fix performance regression introduced by commit "Cache render target ↵Thomas Hellstrom2014-05-091-1/+1
| | | | | | | | | | | | surface" The mentioned commit has the nasty side-effect of turning off accelerated copies. Cc: "10.1 10.2" <mesa-stable@lists.freedesktop.org> Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Reviewed-by: Jakob Bornecrantz <jakob@vmware.com> Reviewed-by: Rob Clark <robdclark@gmail.com>
* st/xa: Cache render target surfaceThomas Hellstrom2014-04-171-3/+15
| | | | | | | | | | | | | | | | Otherwise it will trick the gallium driver into thinking that the render target has actually changed (due to different pipe_surface pointing to same underlying pipe_resource). This is really badness for tiling GPUs like adreno. This also appears to fix a rendering error with Motif on vmwgfx. Why that is is still under investigation. Based on an idea by Rob Clark. Cc: "10.0 10.1" <mesa-stable@lists.freedesktop.org> Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Reviewed-by: Rob Clark <robclark@freedesktop.org>
* st/xa: scissor to help tilersRob Clark2014-04-171-0/+3
| | | | | | | | | | | | | | Keep track of the maximal bounds of all the operations and set scissor accordingly. For tiling GPU's this can be a big win by reducing the memory bandwidth spent moving pixels from system memory to tile buffer and back. You could imagine being more sophisticated and splitting up disjoint operations. But this simplistic approach is good enough for the common cases. Signed-off-by: Rob Clark <robclark@freedesktop.org> Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
* st/xa: remove unneeded argsRob Clark2014-04-171-4/+1
| | | | | Signed-off-by: Rob Clark <robclark@freedesktop.org> Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
* st/xa: Add new map flagsThomas Hellstrom2013-12-171-6/+14
| | | | | | | | Replicate some of the gallium pipe transfer functionality. Also bump minor to signal availability of this feature. Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
* xa: let ddx handle flushJerome Glisse2013-07-251-8/+2
| | | | Signed-off-by: Jerome Glisse <jglisse@redhat.com>
* xa: export a common context flush functionJerome Glisse2013-07-251-6/+11
| | | | | | First step before moving flushing inside the ddx. Signed-off-by: Jerome Glisse <jglisse@redhat.com>
* gallium: extend pipe_context::flush for it to accept an END_OF_FRAME flagMarek Olšák2013-01-041-4/+4
| | | | | | | | | | | | | | | | | Usage with pipe_context: pipe->flush(pipe, NULL, PIPE_FLUSH_END_OF_FRAME); Usage with st_context_iface: st->flush(st, ST_FLUSH_END_OF_FRAME, NULL); The flag is only a hint for drivers. Radeon will use it for buffer eviction heuristics in the kernel (e.g. for queries like how many frames have passed since a buffer was used). The flag is currently only generated by st/dri on SwapBuffers. Reviewed-by: Brian Paul <brianp@vmware.com> Reviewed-by: Stéphane Marchesin <marcheu@chromium.org>
* gallium: remove pipe_surface::usageMarek Olšák2012-12-121-2/+1
| | | | | | Not really used by anybody now. Reviewed-by: Brian Paul <brianp@vmware.com>
* gallium: unify transfer functionsMarek Olšák2012-10-111-21/+9
| | | | | | | | | | | | | | "get_transfer + transfer_map" becomes "transfer_map". "transfer_unmap + transfer_destroy" becomes "transfer_unmap". transfer_map must create and return the transfer object and transfer_unmap must destroy it. transfer_map is successful if the returned buffer pointer is not NULL. If transfer_map fails, the pointer to the transfer object remains unchanged (i.e. doesn't have to be NULL). Acked-by: Brian Paul <brianp@vmware.com>
* st/xa: updates for CSO interface changesBrian Paul2012-08-031-2/+2
|
* st/xa: Fix format conversion copy alpha channelThomas Hellstrom2011-12-151-1/+3
| | | | | | | | | When doing format conversion copies between a format without an alpha channel and a format with an alpha channel, make sure the destination alpha is set to 1. Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
* st/xa, xa/vmwgfx: Use XA_EXPORT attribute to indicate global visibilityThomas Hellstrom2011-11-251-15/+15
| | | | | | | Also fix up Makefiles to use the default mesa compilation flags. Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Reviewed-by: Jakob Bornecrants <jakob@vmware.com>
* st/xa: Plug a pipe context leak.Thomas Hellstrom2011-10-311-0/+2
| | | | | | | Forgot to destroy the pipe context on xa context destroy. Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Reviewed-by: José Fonseca <jfonseca@vmware.com>
* st/xa: Don't call fence_reference with an unitialized fence handle as dstThomas Hellstrom2011-09-291-1/+1
| | | | Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
* st/xa: surfaces and sampler views are per contextThomas Hellstrom2011-09-291-17/+33
| | | | | | | | Don't store references to these on the surface but on the context. References to transfers are still stored on the surface since we allow only a single map of a surface at a time. Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
* st/xa: Fix render to xa_format_a8, which is backed by a gallium L8 textureThomas Hellstrom2011-07-071-3/+6
| | | | Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
* st/xa: Solid fill (tested) and composite (yet untested)Thomas Hellstrom2011-06-211-14/+113
| | | | Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
* st/xa: Support format-changing copy.Thomas Hellstrom2011-06-201-7/+36
| | | | Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
* st/xa: Initial import of the xa state-tracker and the xa-vmwgfx target.Thomas Hellstrom2011-06-151-0/+258
See the file src/gallium/state_trackers/xa/README for more info. Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>