summaryrefslogtreecommitdiffstats
path: root/src/gallium
Commit message (Collapse)AuthorAgeFilesLines
* gallium: add external usage flags to resource_from(get)_handle (v2)Marek Olšák2016-03-0930-54/+123
| | | | | | | | | This will allow drivers to make better decisions about texture sharing for DRI2, DRI3, Wayland, and OpenCL. v2: add read/write flags, take advantage of __DRI_IMAGE_USE_BACKBUFFER Reviewed-by: Axel Davy <[email protected]>
* radeon/uvd: increase max height to 4096 for VI and newerTamil velan2016-03-081-1/+1
| | | | | | | | | | | | | | | | | With this issue 'mpv --hwdec=vdpau --vo=vdpau <stream>' fails for vdpau decode if the stream height is 4096. Vdpau decode of height upto 4096 is necessary usecase on amdgpu driver for VI and newer platforms. The fix is in driver specific implementation of "Decoder Query Capabilities" API to return 4096 for VI and newer platforms. With this fix vdpauinfo reports height support as 4096 and mpv for vdpau decode works fine for 4096 height streams. Signed-off-by: Tamil velan <[email protected]> Reviewed-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Cc: "11.1 11.2" <[email protected]>
* winsys/amdgpu: enlarge buffer_indices_hashlistBas Nieuwenhuizen2016-03-091-1/+1
| | | | | | | | | | | | | | | | | | | | | | Enlarge the buffer hashlist to prevent large numbers of misses due to adding more buffers than can be cached in the hashlist. The game I tested had CS's with up to 1500 buffers and the overhead of amdgpu_lookup_buffer for various sizes was: 4096 1.97% (new value) 2048 4.37% 1024 6.92% 512 9.47% (old value) (percentage of CPU usage in render thread as determined by perf) The time spent in amdgpu_add_buffer self is ~4.2% in all cases and for 4096 the time needed to clear the hashlist is still < 0.10%, so I am not expecting significant regressions. Signed-off-by: Bas Nieuwenhuizen <[email protected]> Signed-off-by: Marek Olšák <[email protected]>
* nvc0: add a new validation path for computeSamuel Pitoiset2016-03-092-48/+39
| | | | | | | | This makes use of the new state validation interface to be consistent with 3d. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Ilia Mirkin <[email protected]>
* nvc0: rework the validation path for 3DSamuel Pitoiset2016-03-094-16/+36
| | | | | | | | This exposes an interface for state validation that will be also used to rework the compute validation path. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Ilia Mirkin <[email protected]>
* nv50,nvc0: make sure to destroy the mutex used for blitsSamuel Pitoiset2016-03-082-0/+2
| | | | | | | | | This mutex is initialized when the blitter is created, but it is never destroyed. This doesn't hurt anything but it makes sense to destroy it at blitter deletion. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Ilia Mirkin <[email protected]>
* gallium/radeon: don't use temporary buffers for persistent mappingsMarek Olšák2016-03-081-2/+4
| | | | | Cc: 11.1 11.2 <[email protected]> Reviewed-by: Michel Dänzer <[email protected]>
* radeon/uvd: disable MPEG1Christian König2016-03-081-0/+1
| | | | | | | | The hardware simply doesn't support that correctly. Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Cc: "11.1 11.2" <[email protected]>
* gallium/swr: fix issues preventing a 32-bit buildTim Rowley2016-03-072-2/+1
| | | | | | | | | Not a currently tested configuration, but these couple of small changes allow a 32-bit build. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94383 Acked-by: Emil Velikov <[email protected]> Acked-by: Brian Paul <[email protected]>
* gallium/swr: remove use of UINT64 from swr_fenceTim Rowley2016-03-071-2/+2
| | | | | | Remove use of a win32-style type leaked from the swr rasterizer. Reviewed-by: Kenneth Graunke <[email protected]>
* gm107/ir: add emission for ATOMSSamuel Pitoiset2016-03-071-1/+44
| | | | | | | This allows to perform atomic operations on shared memory. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Ilia Mirkin <[email protected]>
* tgsi: fix parsing of shared memory declarationsSamuel Pitoiset2016-03-071-1/+3
| | | | | | | | | | The SHARED TGSI keyword is only allowed with TGSI_FILE_MEMORY and not with TGSI_FILE_BUFFER. I have found this by using the nouveau_compiler from command line. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Ilia Mirkin <[email protected]> Cc: "11.2" <[email protected]>
* gm107/ir: add emission for BARSamuel Pitoiset2016-03-071-0/+52
| | | | | Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Ilia Mirkin <[email protected]>
* gk110/ir: add missing src predicate emission for BAR.REDSamuel Pitoiset2016-03-071-0/+8
| | | | | Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Ilia Mirkin <[email protected]>
* gk110/ir: allow to emit immediates for BARSamuel Pitoiset2016-03-071-2/+21
| | | | | Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Ilia Mirkin <[email protected]>
* gk110/ir: fix wrong emission of BAR.SYNCSamuel Pitoiset2016-03-071-1/+0
| | | | | Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Ilia Mirkin <[email protected]>
* nvc0/ir: make sure that thread count immediate for BAR fitSamuel Pitoiset2016-03-071-0/+1
| | | | | | | The limit of the thread count immediate value is 12 bits. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Ilia Mirkin <[email protected]>
* svga: add new surface-write-flushes HUD queryBrian Paul2016-03-074-8/+23
| | | | | | | To know when we're flushing the command buffer because we need to write to surface in the command buffer. Reviewed-by: Charmaine Lee <[email protected]>
* svga: add new flush-time HUD queryBrian Paul2016-03-074-7/+24
| | | | | | To measure the time spent flushing the command buffer. Reviewed-by: Charmaine Lee <[email protected]>
* svga: also dump SVGA3D_BUFFER surfaces in svga_screen_cache_dump()Brian Paul2016-03-071-2/+8
| | | | Reviewed-by: Charmaine Lee <[email protected]>
* nvc0: reset TFB bufctx when we no longer hold a reference to the buffersIlia Mirkin2016-03-062-2/+3
| | | | | | | | | | This fixes some use-after-free situations in dEQP when an xfb state is removed, and then a clear is triggered, which only does a partial validation. It would attempt to read the no-longer-valid buffers, resulting in crashes. Signed-off-by: Ilia Mirkin <[email protected]> Cc: "11.1 11.2" <[email protected]>
* nv50/ir: using sampleid/pos shouldn't force per-sample interpolationIlia Mirkin2016-03-052-6/+1
| | | | | | See https://www.khronos.org/bugzilla/show_bug.cgi?id=1462 Signed-off-by: Ilia Mirkin <[email protected]>
* gallium/util: add new comments, assertions in u_debug_refcnt.cBrian Paul2016-03-051-0/+20
| | | | Reviewed-by: Eduardo Lima Mitev <[email protected]>
* gallium/util: update comments and URL in u_debug_refcnt.cBrian Paul2016-03-051-4/+10
| | | | Reviewed-by: Eduardo Lima Mitev <[email protected]>
* gallium/util: make stream variable static in u_debug_refcnt.cBrian Paul2016-03-051-1/+1
| | | | Reviewed-by: Eduardo Lima Mitev <[email protected]>
* gallium/util: re-indent u_debug_refcnt.[ch]Brian Paul2016-03-052-50/+65
| | | | | | Wrap comments to 78 columns, etc. Reviewed-by: Eduardo Lima Mitev <[email protected]>
* gallium/tests: silence warning in compute.cBrian Paul2016-03-051-1/+1
| | | | | | | | | | | compute.c: In function ‘launch_grid’: compute.c:435:20: warning: assignment discards ‘const’ qualifier from pointer target type [enabled by default] info.input = input; ^ Maybe the pipe_grid_info::input field should be const void *? Reviewed-by: Samuel Pitoiset <[email protected]>
* st/xlib: Don't destroy screen on XCloseDisplay()George Kyriazis2016-03-041-3/+7
| | | | | | | | | screen may still be used by other resources that are not yet freed. To correctly fix this there will be a need to account for resources differently, but this quick fix is not any worse than the original code that leaked screens anyway. Reviewed-by: Brian Paul <[email protected]>
* st/xlib: Hang off screen destructor off main XCloseDisplay() callback.George Kyriazis2016-03-043-35/+27
| | | | | | | | This resolves some order dependencies between the already existing callback the newly created one. Tested-by: Brian Paul <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* st/xlib: Support unlimited number of display connectionsGeorge Kyriazis2016-03-041-19/+103
| | | | | | | | | | | | | | | There is a limit of 10 display connections, which was a problem for apps/tests that were continuously opening/closing display connections. This fix uses XAddExtension() and XESetCloseDisplay() to keep track of the status of the display connections from the X server, freeing mesa-related data as X displays get destroyed by the X server. Poster child is the VTK "TimingTests" Tested-by: Brian Paul <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* svga: add new command-buffer-size HUD queryBrian Paul2016-03-044-7/+23
| | | | | | To plot a graph of the command buffer size. Reviewed-by: Charmaine Lee <[email protected]>
* svga: add new svga_winsys_context::get_command_buffer_size()Brian Paul2016-03-042-0/+14
| | | | | | | To ask how large the current command buffer is. Will be used for a new GALLIUM_HUD graph. Reviewed-by: Charmaine Lee <[email protected]>
* svga: reorder SVGA_QUERY_ switch cases to match declaration orderBrian Paul2016-03-041-9/+9
| | | | Reviewed-by: Charmaine Lee <[email protected]>
* svga: Force an RGBA view creation for an RGBA resourceSinclair Yeh2016-03-041-1/+10
| | | | | | | | | | | glXCreatePixmap() may specify a GLX_TEXTURE_FORMAT_RGB_EXT format for an RGBA resource, causing us to create an RGBX view for an RGBA resource, a combination vgpu10 does not support. When this is detected, change the request to create an RGBA view instead. Reviewed-by: Brian Paul <[email protected]>
* svga: fix an error in svga_texture_generate_mipmapCharmaine Lee2016-03-041-1/+6
| | | | | | | With this patch, make sure the shader resource view is properly created before referencing it in the generate mipmap command. Reviewed-by: Brian Paul <[email protected]>
* winsys/svga: Increase the fence timeoutThomas Hellstrom2016-03-041-1/+2
| | | | | | | | | | | If running with a software renderer backend, the timeout may be insufficient, and we don't want to release busy buffers too early. In practice, SVGA gpu lockups are extremely rare. Signed-off-by: Thomas Hellstrom <[email protected]> Reviewed-by: Brian Paul <[email protected]> Cc: "11.0 11.1" <[email protected]>
* winsys/svga: Fix an uninitialized return valueThomas Hellstrom2016-03-041-0/+2
| | | | | | | Reported-by: Brian Paul <[email protected]> Signed-off-by: Thomas Hellstrom <[email protected]> Reviwed-by: Brian Paul <[email protected]> Cc: "11.0 11.1" <[email protected]>
* radeonsi: Do colorformat endian swap for PIPE_USAGE_STAGINGOded Gabbay2016-03-031-5/+1
| | | | | | | | | | | | | | | | | | There is an old if statement (dated to 2011) that prevented doing endian swap for colorformat, in case the buffer is marked as PIPE_USAGE_STAGING. This is now wrong because st_ReadPixels() reads into a destination texture that is marked with PIPE_USAGE_STAGING. Therefore, even if the texture is rendered correctly to the monitor, when reading it back we get unswapped/wrong values. This patch makes the check_rgba() function in gl-1.0-readpixsanity piglit test pass in big-endian. Signed-off-by: Oded Gabbay <[email protected]> Cc: "11.1 11.2" <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* r600g: Do colorformat endian swap for PIPE_USAGE_STAGINGOded Gabbay2016-03-032-17/+2
| | | | | | | | | | | | | | | | | | | | | There is an old if statement (dated to 2011) that prevented doing endian swap for colorformat, in case the buffer is marked as PIPE_USAGE_STAGING. This is now wrong because st_ReadPixels() reads into a destination texture that is marked with PIPE_USAGE_STAGING. Therefore, even if the texture is rendered correctly to the monitor, when reading it back we get unswapped/wrong values. This patch makes the check_rgba() function in gl-1.0-readpixsanity piglit test pass in big-endian. v2: removed duplicate call to r600_colorformat_endian_swap() inside evergreen_init_color_surface_rat() Signed-off-by: Oded Gabbay <[email protected]> Cc: "11.1 11.2" <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* mesa/build: add OpenSWR to buildTim Rowley2016-03-029-0/+444
| | | | | | | Tested on Linux (centos, ubuntu, and suse variants) Reviewed-by: Emil Velikov <[email protected]> Acked-by: Jose Fonseca <[email protected]>
* gallium/docs - add OpenSWR documentationTim Rowley2016-03-025-0/+381
| | | | Acked-by: Jose Fonseca <[email protected]>
* gallium/target-helpers: add OpenSWR driverTim Rowley2016-03-021-1/+11
| | | | | | Reviewed-by: Roland Scheidegger <[email protected]> Reviewed-by: Emil Velikov <[email protected]> Acked-by: Jose Fonseca <[email protected]>
* gallium/auxilary: more __cplusplus exportsTim Rowley2016-03-025-0/+34
| | | | | | | | swr driver which is written in C++ needs access to some more gallium utility functions than are currently exposed. Reviewed-by: Roland Scheidegger <[email protected]> Acked-by: Jose Fonseca <[email protected]>
* gallium/swr: add OpenSWR rasterizerTim Rowley2016-03-0288-0/+48234
| | | | | Acked-by: Roland Scheidegger <[email protected]> Acked-by: Jose Fonseca <[email protected]>
* gallium/swr: add OpenSWR driverTim Rowley2016-03-0223-0/+5718
| | | | | | | | OpenSWR is a new software rasterizer for x86 processors designed for high performance and high scalablility on visualization workloads. Acked-by: Roland Scheidegger <[email protected]> Acked-by: Jose Fonseca <[email protected]>
* gk110/ir: fix wrong emission of NOT modifier for VOTESamuel Pitoiset2016-03-021-1/+1
| | | | | | | | Spotted by Coverity. Signed-off-by: Samuel Pitoiset <[email protected]> Reported-by: Matt Turner <[email protected]> Reviewed-by: Ilia Mirkin <[email protected]>
* gallium/cso: fix indentationThomas Hindoe Paaboel Andersen2016-03-021-4/+4
| | | | | | | | Only one of these were recently introduced. However, since we keep copy/pasting the same wrong indentation we should probably just fix it. Reviewed-by: Brian Paul <[email protected]>
* gallium: fix PIPE_BIND_QUERY_BUFFER - PIPE_BIND_SCANOUT overlapMarek Olšák2016-03-021-3/+3
| | | | | Reviewed-by: Samuel Pitoiset <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* freedreno/ir3: enable shareable shadersRob Clark2016-03-015-8/+12
| | | | | | | Now that we are no longer using the pctx reference in the shader, drop it and turn on shareable shaders. Signed-off-by: Rob Clark <[email protected]>
* freedreno/ir3: pass ctx to constant-emit codeRob Clark2016-03-014-25/+21
| | | | | | | Rather than fishing it out of the shader. This removes the other big user of shader->pctx. Signed-off-by: Rob Clark <[email protected]>