[Mesa-dev] [PATCH 1/6] glsl: Allow non-constant UBO array indexing with GLSL4/ARB_gpu_shader5.

2014-07-12 Thread Chris Forbes
Signed-off-by: Chris Forbes --- src/glsl/ast_array_index.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/glsl/ast_array_index.cpp b/src/glsl/ast_array_index.cpp index f3b060e..50f9987 100644 --- a/src/glsl/ast_array_index.cpp +++ b/src/glsl/ast_array_index.cpp @@ -18

[Mesa-dev] [PATCH 6/6] glsl: No longer require ubo block index to be constant in ir_validate

2014-07-12 Thread Chris Forbes
Signed-off-by: Chris Forbes --- src/glsl/ir_validate.cpp | 1 - 1 file changed, 1 deletion(-) diff --git a/src/glsl/ir_validate.cpp b/src/glsl/ir_validate.cpp index 42142da..74ae318 100644 --- a/src/glsl/ir_validate.cpp +++ b/src/glsl/ir_validate.cpp @@ -495,7 +495,6 @@ ir_validate::visit_leave(

[Mesa-dev] [PATCH 3/6] glsl: Accept nonconstant array references in lower_ubo_reference

2014-07-12 Thread Chris Forbes
Instead of falling back to just the block name (which we won't find), look for the first element of the block array. We'll deal with the rest in the backend by arranging for the blocks to be laid out contiguously. Signed-off-by: Chris Forbes --- src/glsl/lower_ubo_reference.cpp | 10 ++

[Mesa-dev] [PATCH 5/6] glsl: Plumb through UBO array indexing expressions

2014-07-12 Thread Chris Forbes
Signed-off-by: Chris Forbes --- src/glsl/lower_ubo_reference.cpp | 50 1 file changed, 30 insertions(+), 20 deletions(-) diff --git a/src/glsl/lower_ubo_reference.cpp b/src/glsl/lower_ubo_reference.cpp index c49ae34..80edd93 100644 --- a/src/glsl/lower_ub

[Mesa-dev] [PATCH 4/6] glsl: Convert uniform_block in lower_ubo_reference to ir_rvalue.

2014-07-12 Thread Chris Forbes
Previously this was a block index with special semantics for -1. With ARB_gpu_shader5, this need not be a compile-time constant, so allow any rvalue here and convert the -1 to a NULL pointer. Signed-off-by: Chris Forbes --- src/glsl/lower_ubo_reference.cpp | 15 --- 1 file changed, 8

[Mesa-dev] [PATCH 0/6] Dynamically uniform UBO array indexing, Part 1

2014-07-12 Thread Chris Forbes
This series adds various relaxations and extra plumbing to allow indexing arrays of uniform blocks with dynamically uniform expressions rather than only constant expressions. Covers only the GLSL part -- there are still a few loose ends in the corresponding i965 patches, so I'll send that support

[Mesa-dev] [PATCH 2/6] glsl: Mark entire UBO array active if indexed with non-constant.

2014-07-12 Thread Chris Forbes
Without doing a lot more work, we have no idea which indices may be used at runtime, so just mark them all. Signed-off-by: Chris Forbes --- src/glsl/link_uniform_block_active_visitor.cpp | 51 -- 1 file changed, 32 insertions(+), 19 deletions(-) diff --git a/src/glsl/lin

Re: [Mesa-dev] About the differences in struct intel_region and intel_mipmap_level

2014-07-12 Thread Kenneth Graunke
On Saturday, July 12, 2014 09:06:44 AM Zhaotian Wang wrote: > Hi guys, > Recently I am working on a project, who uses mesa source code as its > library. It went quite well with mesa 10.1.* and older version of mesa > source code. However, it does not build successfully with the current mesa > git m

Re: [Mesa-dev] [PATCH V5 6/6] i965/fs: add support for ir_*_interpolate_at_* expressions

2014-07-12 Thread Kenneth Graunke
On Saturday, July 12, 2014 09:16:25 PM Chris Forbes wrote: > SIMD8-only for now. > > V5: - Fix style complaints > - Move prototype to be with other oddball emit functions > - Use unreachable() instead of assert() where possible > > Signed-off-by: Chris Forbes > --- > src/mesa/drivers/dr

Re: [Mesa-dev] [PATCH 1/3] Add support for swrast to the DRM EGL platform

2014-07-12 Thread Emil Velikov
On 12/07/14 12:47, Giovanni Campagna wrote: > 2014-07-11 19:19 GMT+02:00 Emil Velikov : [snip] >> diff --git a/src/gbm/backends/dri/gbm_dri.c b/src/gbm/backends/dri/gbm_dri.c >> index 347bc99..4014d5c 100644 >> --- a/src/gbm/backends/dri/gbm_dri.c >> +++ b/src/gbm/backends/dri/gbm_dri.c [snip] >> @

[Mesa-dev] [PATCH 2/3] Add a dumb drm/kms winsys for software rendering

2014-07-12 Thread Emil Velikov
From: Giovanni Campagna Add a new winsys and target that can be used with a dri2 state tracker and loader instead of drisw. This allows to use gbm as a dri2/image loader and avoid the extra copy from the backbuffer to the shadow frontbuffer. The new driver is called "kms_swrast", and is only loa

[Mesa-dev] [PATCH 1/3] Add support for swrast to the DRM EGL platform

2014-07-12 Thread Emil Velikov
From: Giovanni Campagna Turn GBM into a swrast loader (providing putimage/getimage backed by a dumb KMS buffer). This allows to run KMS+DRM GL applications (such as weston or mutter-wayland) unmodified on cards that don't have any client side HW acceleration component but that can do modeset (exa

[Mesa-dev] [PATCH 3/6] radeonsi: add support for fine-grained sampler view updates

2014-07-12 Thread Marek Olšák
From: Marek Olšák --- src/gallium/drivers/radeonsi/si_blit.c| 14 +-- src/gallium/drivers/radeonsi/si_descriptors.c | 36 +++ src/gallium/drivers/radeonsi/si_pipe.h| 1 - 3 files changed, 21 insertions(+), 30 deletions(-) diff --git a/src/gallium

[Mesa-dev] [PATCH 5/6] radeonsi: remove nr_vertex_buffers

2014-07-12 Thread Marek Olšák
From: Marek Olšák Unused. Also inline util_set_vertex_buffers_count and simplify it. --- src/gallium/drivers/radeonsi/si_descriptors.c | 4 ++-- src/gallium/drivers/radeonsi/si_pipe.h| 3 +-- src/gallium/drivers/radeonsi/si_state.c | 22 -- 3 files changed, 2

[Mesa-dev] [PATCH 2/6] radeonsi: move si_set_sampler_views to si_descriptors.c

2014-07-12 Thread Marek Olšák
From: Marek Olšák --- src/gallium/drivers/radeonsi/si_descriptors.c | 72 +-- src/gallium/drivers/radeonsi/si_state.c | 66 src/gallium/drivers/radeonsi/si_state.h | 3 -- 3 files changed, 68 insertions(+), 73 deletions(-) diff --git

[Mesa-dev] [PATCH 4/6] radeonsi: move vertex buffer descriptors from IB to memory

2014-07-12 Thread Marek Olšák
From: Marek Olšák This removes the intermediate storage (pm4 state) and generates descriptors directly in a staging buffer. It also reduces the number of flushes, because the descriptors no longer take CS space. --- src/gallium/drivers/radeonsi/si_descriptors.c | 131 --

[Mesa-dev] [PATCH 1/6] radeonsi: move sampler descriptors from IB to memory

2014-07-12 Thread Marek Olšák
From: Marek Olšák Sampler descriptors are now represented by si_descriptors. This also adds support for fine-grained sampler state updates and the border color update is now isolated in a separate function. Border colors have been broken if texturing from multiple shader stages is used. This pat

[Mesa-dev] [PATCH 6/6] radeonsi: only update vertex buffers when they need updating

2014-07-12 Thread Marek Olšák
From: Marek Olšák --- src/gallium/drivers/radeonsi/si_descriptors.c | 16 +++- src/gallium/drivers/radeonsi/si_state.c | 2 ++ src/gallium/drivers/radeonsi/si_state_draw.c | 6 +- 3 files changed, 22 insertions(+), 2 deletions(-) diff --git a/src/gallium/drivers/radeons

Re: [Mesa-dev] [PATCH 3/3] configure: check for core xcb (libxcb.so) and link VL targets against it.

2014-07-12 Thread Emil Velikov
On 12/07/14 10:28, Christian König wrote: > Am 12.07.2014 01:13, schrieb Emil Velikov: >> Make sure to check the presence of the module in order to pick the >> correct libs flag and before feeding them to the compiler/linker. >> >> Current libXvMC*, libvdpau* and libomx_mesa depends unconditionally

[Mesa-dev] [PATCH] glsl: Optimize logic operation A || (A && B) v2

2014-07-12 Thread thomashelland90
From: Thomas Helland Let's cut the needless A && B here. Gives some effect on a clean shader-db with some extra shaders from TF2 and portal. helped: shaders/tf2/2042.shader_test fs16:23 -> 21 (-8.70%) helped: shaders/tf2/2042.shader_test fs8: 23 -> 21 (-8.70%) helped: shaders/tf2

[Mesa-dev] About the differences in struct intel_region and intel_mipmap_level

2014-07-12 Thread Zhaotian Wang
Hi guys, Recently I am working on a project, who uses mesa source code as its library. It went quite well with mesa 10.1.* and older version of mesa source code. However, it does not build successfully with the current mesa git master branch source code. It turns out that the project uses some stru

Re: [Mesa-dev] [PATCH 3/3] configure: check for core xcb (libxcb.so) and link VL targets against it.

2014-07-12 Thread Christian König
Am 12.07.2014 01:13, schrieb Emil Velikov: Make sure to check the presence of the module in order to pick the correct libs flag and before feeding them to the compiler/linker. Current libXvMC*, libvdpau* and libomx_mesa depends unconditionally upon xcb, due to their usage of the aux/vl gellium m

[Mesa-dev] [PATCH V5 6/6] i965/fs: add support for ir_*_interpolate_at_* expressions

2014-07-12 Thread Chris Forbes
SIMD8-only for now. V5: - Fix style complaints - Move prototype to be with other oddball emit functions - Use unreachable() instead of assert() where possible Signed-off-by: Chris Forbes --- src/mesa/drivers/dri/i965/brw_fs.h | 2 + src/mesa/drivers/dri/i965/brw_fs_visitor.c

[Mesa-dev] [PATCH V5 0/6] i965 ARB_gpu_shader5 interpolateAt*

2014-07-12 Thread Chris Forbes
Here's a new version of the series incorporating the review feedback from earlier today. ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev

[Mesa-dev] [PATCH V5 2/6] i965/disasm: add support for pixel interpolator messages

2014-07-12 Thread Chris Forbes
V3: Rework for brw_inst changes Signed-off-by: Chris Forbes Reviewed-by: Kenneth Graunke --- src/mesa/drivers/dri/i965/brw_disasm.c | 17 + 1 file changed, 17 insertions(+) diff --git a/src/mesa/drivers/dri/i965/brw_disasm.c b/src/mesa/drivers/dri/i965/brw_disasm.c index f37da

[Mesa-dev] [PATCH V5 1/6] i965: Add message descriptor bit definitions for pixel interpolator

2014-07-12 Thread Chris Forbes
These got lost in the big brw_inst shakeup. Signed-off-by: Chris Forbes Reviewed-by: Kenneth Graunke --- src/mesa/drivers/dri/i965/brw_defines.h | 5 + src/mesa/drivers/dri/i965/brw_inst.h| 11 +++ 2 files changed, 16 insertions(+) diff --git a/src/mesa/drivers/dri/i965/brw_de

[Mesa-dev] [PATCH V5 5/6] i965/fs: Skip channel expressions splitting for interpolation

2014-07-12 Thread Chris Forbes
The backend will have to do a message send, so we want to keep these in one piece, just like texture ops. Signed-off-by: Chris Forbes Reviewed-by: Kenneth Graunke --- .../dri/i965/brw_fs_channel_expressions.cpp| 25 ++ 1 file changed, 25 insertions(+) diff --git a/s

[Mesa-dev] [PATCH V5 4/6] i965/fs: add generator support for pixel interpolator query

2014-07-12 Thread Chris Forbes
V5: - Split into separate opcodes - Pass message data in src1 immediate - Put noperspective bit in fs_inst rather than adding any junk to backend_instruction Signed-off-by: Chris Forbes --- src/mesa/drivers/dri/i965/brw_defines.h| 4 +++ src/mesa/drivers/dri/i965/brw_fs.cp

[Mesa-dev] [PATCH V5 3/6] i965: add low-level support for send to pixel interpolator

2014-07-12 Thread Chris Forbes
Signed-off-by: Chris Forbes Reviewed-by: Kenneth Graunke --- src/mesa/drivers/dri/i965/brw_eu.h | 10 ++ src/mesa/drivers/dri/i965/brw_eu_emit.c | 28 2 files changed, 38 insertions(+) diff --git a/src/mesa/drivers/dri/i965/brw_eu.h b/src/mesa/drivers/

Re: [Mesa-dev] [PATCH 4/4] i965/vec4: Invalidate live intervals in opt_cse, not _local.

2014-07-12 Thread Kenneth Graunke
On Friday, July 11, 2014 08:50:01 PM Matt Turner wrote: > --- > src/mesa/drivers/dri/i965/brw_vec4_cse.cpp | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > > diff --git a/src/mesa/drivers/dri/i965/brw_vec4_cse.cpp b/src/mesa/drivers/dri/i965/brw_vec4_cse.cpp > index 7bb016d..83c7e

Re: [Mesa-dev] [PATCH V4 6/6] i965/fs: add support for ir_*_interpolate_at_* expressions

2014-07-12 Thread Matt Turner
On Fri, Jul 11, 2014 at 8:20 PM, Chris Forbes wrote: > SIMD8-only for now. > > Signed-off-by: Chris Forbes > --- > src/mesa/drivers/dri/i965/brw_fs.h | 1 + > src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 135 > ++- > 2 files changed, 134 insertions(+), 2 de

Re: [Mesa-dev] [PATCH V4 4/6] i965/fs: add generator support for pixel interpolator query

2014-07-12 Thread Matt Turner
On Sat, Jul 12, 2014 at 12:06 AM, Kenneth Graunke wrote: > On Saturday, July 12, 2014 03:20:13 PM Chris Forbes wrote: >> Signed-off-by: Chris Forbes >> --- >> src/mesa/drivers/dri/i965/brw_defines.h| 1 + >> src/mesa/drivers/dri/i965/brw_fs.cpp | 2 ++ >> src/mesa/drivers/dri

Re: [Mesa-dev] [PATCH V4 3/6] i965: add low-level support for send to pixel interpolator

2014-07-12 Thread Matt Turner
On Fri, Jul 11, 2014 at 8:20 PM, Chris Forbes wrote: > Signed-off-by: Chris Forbes > --- > src/mesa/drivers/dri/i965/brw_eu.h | 10 > src/mesa/drivers/dri/i965/brw_eu_emit.c | 43 > + > 2 files changed, 53 insertions(+) > > diff --git a/src/mesa/dri

Re: [Mesa-dev] [PATCH V4 4/6] i965/fs: add generator support for pixel interpolator query

2014-07-12 Thread Kenneth Graunke
On Saturday, July 12, 2014 03:20:13 PM Chris Forbes wrote: > Signed-off-by: Chris Forbes > --- > src/mesa/drivers/dri/i965/brw_defines.h| 1 + > src/mesa/drivers/dri/i965/brw_fs.cpp | 2 ++ > src/mesa/drivers/dri/i965/brw_fs.h | 4 > src/mesa/drivers/dri/i965

Re: [Mesa-dev] [PATCH V4 3/6] i965: add low-level support for send to pixel interpolator

2014-07-12 Thread Chris Forbes
Yeah, I can inline brw_set_pixel_interpolator_query_message into its one caller. On Sat, Jul 12, 2014 at 6:56 PM, Kenneth Graunke wrote: > On Saturday, July 12, 2014 03:20:12 PM Chris Forbes wrote: >> Signed-off-by: Chris Forbes >> --- >> src/mesa/drivers/dri/i965/brw_eu.h | 10 >>