aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/tests
Commit message (Collapse)AuthorAgeFilesLines
* gallium/util: s/uint/enum tgsi_semantic/ in simple shader codeBrian Paul2018-02-082-6/+6
| | | | | Reviewed-by: Mathias Fröhlich <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* Revert "gallium: build ddebug, noop, rbug, trace as part of auxiliary"Roland Scheidegger2018-02-071-0/+1
| | | | | | This reverts commit 6f82b8d8d0a986aac28e7bec47fc313fb950475c. This broke scons build, and reportedly clover with autotools/meson too.
* gallium: build ddebug, noop, rbug, trace as part of auxiliaryMarek Olšák2018-02-071-1/+0
| | | | | | | Building gallium is faster by 7.5 seconds on a 4core/8thread 3GHz CPU. (gallium build time is reduced by 15% when building only radeonsi) Non-recursive makefiles are great!
* util: move os_time.[ch] to src/utilNicolai Hähnle2017-11-091-1/+2
| | | | Reviewed-by: Marek Olšák <[email protected]>
* util: move pipe_barrier into src/util and rename to util_barrierNicolai Hähnle2017-11-091-6/+6
| | | | | | | | | The #if guard is probably not 100% equivalent to the previous PIPE_OS check, but if anything it should be an over-approximation (are there pthread implementations without barriers?), so people will get either a good implementation or compile errors that are easy to fix. Reviewed-by: Marek Olšák <[email protected]>
* gallium: Remove util_format_s3tc_init()Matt Turner2017-10-021-2/+0
| | | | | Reviewed-by: Nicolai Hähnle <[email protected]> Reviewed-by: Emil Velikov <[email protected]>
* gallium: Remove util_format_s3tc_enabledMatt Turner2017-10-021-5/+0
| | | | | Reviewed-by: Nicolai Hähnle <[email protected]> Reviewed-by: Emil Velikov <[email protected]>
* gallium/tests: use ARRAY_SIZE macroEric Engestrom2017-09-083-3/+9
| | | | | Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* gallium/tests: always use two-dimensional constant referencesNicolai Hähnle2017-09-042-8/+8
| | | | | | Acked-by: Roland Scheidegger <[email protected]> Tested-by: Dieter Nützel <[email protected]> Reviewed-by: Timothy Arceri <[email protected]>
* pipe-loader: remove config from pipe_loader_create_screenNicolai Hähnle2017-08-043-3/+3
| | | | | | | | | | | | The config passed into the screen should be independent from the state tracker, because at least in the case of radeonsi, the screen structure can be shared between different state trackers. Incidentally, this also fixes crashes that were recently introduced. Fixes: a35a9e7c ("gallium: add driconf options to pipe_screen_config") Tested-by: Dieter Nützel <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* gallium: add pipe_screen_config to screen_create functionsNicolai Hähnle2017-08-023-3/+3
| | | | | | | This allows a more generic mechanism for passing user configurations into drivers by accessing the dri options directly. Reviewed-by: Marek Olšák <[email protected]>
* gallium: allow passing 'unsigned flags' to create_screen()Marek Olšák2017-06-233-3/+3
| | | | | | for drirc options Reviewed-by: Nicolai Hähnle <[email protected]>
* gallium/util: add _LZ and TXF options to simple shadersMarek Olšák2017-06-071-1/+2
| | | | Reviewed-by: Nicolai Hähnle <[email protected]>
* u_format_test: Ignore S3TC errors.Jose Fonseca2017-05-221-0/+25
| | | | | | | | | | This prevents spurious failures when libtxc-dxtn-s2tc is installed. Note: lp_test_format doesn't need any change since we were already ignoring S3TC failures there. Reviewed-by: Roland Scheidegger <[email protected]> Reviewed-by: Rhys Kidd <[email protected]>
* gallium/tests: fix build after index buffer changesMarek Olšák2017-05-1116-32/+32
| | | | | | for some reason, only scons can build these. Reviewed-by: Nicolai Hähnle <[email protected]>
* gallium/util: replace pipe_thread_create() with u_thread_create()Timothy Arceri2017-03-121-1/+1
| | | | | | | They do the same thing we just moved the function to be accessible to all of Mesa. Reviewed-by: Marek Olšák <[email protected]>
* gallium/tests: remove execute bit from TGSI shader - vert-uadd.shEmil Velikov2017-03-101-0/+0
| | | | | | | | | Just like the the dozens of other shaders, the file is parsed by separate tool and not executed. Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Jose Fonseca <[email protected]> Reviewed-by: Eric Engestrom <[email protected]>
* gallium/util: replace pipe_thread_wait() with thrd_join()Timothy Arceri2017-03-071-1/+1
| | | | | | | | | Replace done using: find ./src -type f -exec sed -i -- \ 's:pipe_thread_wait(\([^)]*\)):thrd_join(\1, NULL):g' {} \; Reviewed-by: Plamena Manolova <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* gallium/util: remove PIPE_THREAD_ROUTINE()Timothy Arceri2017-03-071-1/+2
| | | | | | | | | | | | | This was made unnecessary with fd33a6bcd7f12. This was mostly done with: find ./src -type f -exec sed -i -- \ 's:PIPE_THREAD_ROUTINE(\([^,]*\), \([^)]*\)):int\n\1(void \*\2):g' {} \; With some small manual tidy ups. Reviewed-by: Plamena Manolova <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* gallium/util: replace pipe_thread with thrd_tTimothy Arceri2017-03-071-1/+1
| | | | | | | | pipe_thread was made unnecessary with fd33a6bcd7f12. V2: fix compile error in u_queue.c Reviewed-by: Marek Olšák <[email protected]>
* gallium: let state trackers tell u_vbuf whether user VBOs are possibleMarek Olšák2017-02-142-2/+2
| | | | | | This can affect whether u_vbuf will be enabled or not. Reviewed-by: Nicolai Hähnle <[email protected]>
* gallium: fix more occurences of u_hash.hMarek Olšák2016-11-221-1/+1
| | | | this fixes compile failures since 86514d84e0beec47c82da4888db12bf07f33cb83
* util/blitter: add clamping during SINT <-> UINT blitsNicolai Hähnle2016-11-161-0/+1
| | | | | | | | | | | | Even though glBlitFramebuffer cannot be used for SINT <-> UINT blits, we still need to handle this type of blit here because it can happen as part of texture uploads / downloads, e.g. uploading a GL_RGBA8I texture from GL_UNSIGNED_INT data. Fixes parts of GL45-CTS.gtf32.GL3Tests.packed_pixels.packed_pixels. Reviewed-by: Marek Olšák <[email protected]> Reviewed-by: Edward O'Callaghan <[email protected]>
* gallium: add missing zero-init for resource templatesRob Clark2016-10-079-0/+16
| | | | | | | Mostly test code, plus one spot I noticed in r600. Signed-off-by: Rob Clark <[email protected]> Reviewed-by: Nicolai Hähnle <[email protected]>
* gallium: split transfer_inline_write into buffer and texture callbacksMarek Olšák2016-07-235-72/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | to reduce the call indirections with u_resource_vtbl. The worst call tree you could get was: - u_transfer_inline_write_vtbl - u_default_transfer_inline_write - u_transfer_map_vtbl - driver_transfer_map - u_transfer_unmap_vtbl - driver_transfer_unmap That's 6 indirect calls. Some drivers only had 5. The goal is to have 1 indirect call for drivers that care. The resource type can be determined statically at most call sites. The new interface is: pipe_context::buffer_subdata(ctx, resource, usage, offset, size, data) pipe_context::texture_subdata(ctx, resource, level, usage, box, data, stride, layer_stride) v2: fix whitespace, correct ilo's behavior Reviewed-by: Nicolai Hähnle <[email protected]> Acked-by: Roland Scheidegger <[email protected]>
* scons: whitespace cleanupGiuseppe Bilotta2016-05-251-1/+1
| | | | | | | | | | This text transformation was done automatically via the following shell command: $ find -name SCons\* -exec sed -i s/\\s\\+$// '{}' \; Signed-off-by: Giuseppe Bilotta <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* Treewide: Remove Elements() macroJan Vesely2016-05-173-6/+6
| | | | | Signed-off-by: Jan Vesely <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* gallium: merge PIPE_SWIZZLE_* and UTIL_FORMAT_SWIZZLE_*Marek Olšák2016-04-223-23/+23
| | | | | | | | Use PIPE_SWIZZLE_* everywhere. Use X/Y/Z/W/0/1 instead of RED, GREEN, BLUE, ALPHA, ZERO, ONE. The new enum is called pipe_swizzle. Acked-by: Jose Fonseca <[email protected]>
* gallium/tests: Update UTIL_FORMAT_MAX_* defines.Jose Fonseca2016-04-191-0/+4
| | | | Reviewed-by: Roland Scheidegger <[email protected]>
* scons: Add a "check" target to run all unit tests.Jose Fonseca2016-04-141-7/+5
| | | | | | | | | Except: - u_cache_test -- too long - translate_test -- unreliable (it's probably testing corner cases that translate module doesn't care about.) Reviewed-by: Roland Scheidegger <[email protected]>
* test/unit: Make translate_test invoke translate_create by default.Jose Fonseca2016-04-141-3/+4
| | | | Reviewed-by: Roland Scheidegger <[email protected]>
* test/unit: Make pipe_barrier_test actually check correct bahavior.Jose Fonseca2016-04-141-7/+50
| | | | | | | | So it can run unattended. Also make it silent by default. Reviewed-by: Roland Scheidegger <[email protected]>
* gallium: distinguish between shader IR in get_compute_paramBas Nieuwenhuizen2016-04-021-1/+3
| | | | | | | | | | | | | For radeonsi, native and TGSI use different compilers and this results in different limits for different IR's. The set we strictly need for radeonsi is only the MAX_BLOCK_SIZE and MAX_THREADS_PER_BLOCK params, but I added a few others as shader related that seemed like they would also typically depend on the compiler. Signed-off-by: Bas Nieuwenhuizen <[email protected]> Reviewed-by: Dave Airlie <[email protected]>
* gallium: add compute shader IR typeBas Nieuwenhuizen2016-04-021-0/+1
| | | | | | Signed-off-by: Bas Nieuwenhuizen <[email protected]> Reviewed-by: Ilia Mirkin <[email protected]> Reviewed-by: Dave Airlie <[email protected]>
* gallium/tests: declare sampler views in shadersBrian Paul2016-03-213-0/+3
| | | | | Reviewed-by: Marek Olšák <[email protected]> Reviewed-by: Charmaine Lee <[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]>
* gallium: add a new interface for pipe_context::launch_grid()Samuel Pitoiset2016-02-131-1/+10
| | | | | | | | | | | | | This introduces pipe_grid_info which contains all information to describe a launch_grid call. This will be used to implement indirect compute in the same fashion as indirect draw. Changes from v2: - correctly initialize pipe_grid_info for nv50/nvc0 Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Marek Olšák <[email protected]> Reviewed-by: Ilia Mirkin <[email protected]>
* gallium/util: switch over to new u_debug_image.[ch] codeBrian Paul2016-02-083-2/+3
| | | | Reviewed-by: Marek Olšák <[email protected]>
* gallium/tests: fix build with clang compilerSamuel Pitoiset2016-01-031-273/+330
| | | | | | | | | | | | Nested functions are supported as an extension in GNU C, but Clang don't support them. This fixes compilation errors when (manually) building compute.c, or by setting --enable-gallium-tests to the configure script. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=75165 Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Edward O'Callaghan <[email protected]>
* gallium: rename libpipe_loader to libpipe_loader_dynamicEmil Velikov2015-11-211-1/+1
| | | | | | | | | With the next commits we'll introduce a 'static' version, which will essentially load the statically linked-in pipe-drivers, rather than the standalone pipe-$foo.so ones. Signed-off-by: Emil Velikov <[email protected]> Acked-by: Rob Clark <[email protected]>
* pipe-loader: rework the sw backendEmil Velikov2015-11-211-1/+0
| | | | | | | | | | | | Move the winsys into the pipe-target, similar to the hardware pipe-driver. v2: - move int declaration outside of loop (Brian) - fold the teardown into a goto + separate function. Signed-off-by: Emil Velikov <[email protected]> Acked-by: Rob Clark <[email protected]>
* gallium/tests: remove unneeded include pathsEmil Velikov2015-11-211-4/+0
| | | | | | | | The tests don't (and shouldn't) need to have anything driver and/or winsys specific. Signed-off-by: Emil Velikov <[email protected]> Acked-by: Rob Clark <[email protected]>
* gallium: remove library_path argument from pipe_loader_create_screen()Emil Velikov2015-11-214-5/+4
| | | | | | | | | | | | | | | Currently the location is determined at configure/build time and consistently copied across gallium. Just remove the extra argument, and use PIPE_SEARCH_DIR where appropriate. This will allow us to remove the duplication in the *configuration and *screen_create APIs by moving util_dl_get_proc_address() and friends to probe time. v2: rebase on top of vl_winsys_drm.c addition Signed-off-by: Emil Velikov <[email protected]> Acked-by: Rob Clark <[email protected]>
* automake: use GALLIUM_PIPE_LOADER_DEFINES only where applicableEmil Velikov2015-11-211-2/+1
| | | | | | | | As of last commit we no longer need the defines in order to have the function prototypes. Signed-off-by: Emil Velikov <[email protected]> Acked-by: Rob Clark <[email protected]>
* gallium: add flags parameter to pipe_screen::context_createMarek Olšák2015-08-2612-12/+12
| | | | | | | | This allows creating compute-only and debug contexts. Reviewed-by: Brian Paul <[email protected]> Acked-by: Christian König <[email protected]> Acked-by: Alex Deucher <[email protected]>
* gallium/tests: use cso_set_samplersMarek Olšák2015-07-231-2/+3
|
* gallium: replace INLINE with inlineIlia Mirkin2015-07-211-7/+7
| | | | | | | | | | | | | | | | Generated by running: git grep -l INLINE src/gallium/ | xargs sed -i 's/\bINLINE\b/inline/g' git grep -l INLINE src/mesa/state_tracker/ | xargs sed -i 's/\bINLINE\b/inline/g' git checkout src/gallium/state_trackers/clover/Doxyfile and manual edits to src/gallium/include/pipe/p_compiler.h src/gallium/README.portability to remove mentions of the inline define. Signed-off-by: Ilia Mirkin <[email protected]> Acked-by: Marek Olšák <[email protected]>
* automake: remove empty GALLIUM_PIPE_LOADER_LIBSEmil Velikov2015-07-131-1/+0
| | | | | | Cc: Rob Clark <[email protected]> Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Francisco Jerez <[email protected]>
* automake: pipe-loader: remove the 'client' pipe-loaderEmil Velikov2015-07-131-2/+2
| | | | | | | | | | Was only around as opencl's pipe-loader wanted to link against xcb in some cases. Cc: Rob Clark <[email protected]> Cc: Tom Stellard <[email protected]> Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Francisco Jerez <[email protected]>
* util/blitter (and friends): generate appropriate SVIEW declsRob Clark2015-06-211-1/+3
| | | | | | | | Some hardware needs to know the sampler type. Update the blit related shaders to include SVIEW decl. Signed-off-by: Rob Clark <[email protected]> Reviewed-by: Jose Fonseca <[email protected]>