From 1a5c8c24b5791efa02a7beefa4ba1c49ae033c73 Mon Sep 17 00:00:00 2001 From: Bas Nieuwenhuizen Date: Fri, 25 Mar 2016 02:06:50 +0100 Subject: gallium: distinguish between shader IR in get_compute_param 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 Reviewed-by: Dave Airlie --- src/mesa/state_tracker/st_extensions.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'src/mesa/state_tracker') diff --git a/src/mesa/state_tracker/st_extensions.c b/src/mesa/state_tracker/st_extensions.c index 8748ab5c876..6c0df8d2a98 100644 --- a/src/mesa/state_tracker/st_extensions.c +++ b/src/mesa/state_tracker/st_extensions.c @@ -1124,14 +1124,15 @@ void st_init_extensions(struct pipe_screen *screen, if (compute_supported_irs & (1 << PIPE_SHADER_IR_TGSI)) { uint64_t grid_size[3], block_size[3]; - screen->get_compute_param(screen, PIPE_COMPUTE_CAP_MAX_GRID_SIZE, - grid_size); - screen->get_compute_param(screen, PIPE_COMPUTE_CAP_MAX_BLOCK_SIZE, - block_size); - screen->get_compute_param(screen, + screen->get_compute_param(screen, PIPE_SHADER_IR_TGSI, + PIPE_COMPUTE_CAP_MAX_GRID_SIZE, grid_size); + screen->get_compute_param(screen, PIPE_SHADER_IR_TGSI, + PIPE_COMPUTE_CAP_MAX_BLOCK_SIZE, block_size); + screen->get_compute_param(screen, PIPE_SHADER_IR_TGSI, PIPE_COMPUTE_CAP_MAX_THREADS_PER_BLOCK, &consts->MaxComputeWorkGroupInvocations); - screen->get_compute_param(screen, PIPE_COMPUTE_CAP_MAX_LOCAL_SIZE, + screen->get_compute_param(screen, PIPE_SHADER_IR_TGSI, + PIPE_COMPUTE_CAP_MAX_LOCAL_SIZE, &consts->MaxComputeSharedMemorySize); for (i = 0; i < 3; i++) { -- cgit v1.2.3