Re: [Mesa-dev] [PATCH 17/18] i965/cs: Add max_cs_threads

2015-03-22 Thread Jordan Justen
On 2015-03-22 21:34:19, Kenneth Graunke wrote: > On Sunday, March 22, 2015 12:39:25 PM Ben Widawsky wrote: > > On Sat, Mar 14, 2015 at 09:54:27PM -0700, Jordan Justen wrote: > [snip] > > > @@ -225,7 +229,8 @@ static const struct brw_device_info > brw_device_info_hsw_gt3 = { > > > .max_hs_threa

Re: [Mesa-dev] [PATCH 17/18] i965/cs: Add max_cs_threads

2015-03-22 Thread Kenneth Graunke
On Sunday, March 22, 2015 12:39:25 PM Ben Widawsky wrote: > On Sat, Mar 14, 2015 at 09:54:27PM -0700, Jordan Justen wrote: [snip] > > @@ -225,7 +229,8 @@ static const struct brw_device_info brw_device_info_hsw_gt3 = { > > .max_hs_threads = 504, \ > > .max_ds_threa

Re: [Mesa-dev] [PATCH v3 5/7] i965: Add a NIR analysis pass for determining when a boolean resolve is needed

2015-03-22 Thread Jason Ekstrand
On Mar 22, 2015 8:48 PM, "Connor Abbott" wrote: > > On Fri, Mar 20, 2015 at 5:23 PM, Jason Ekstrand wrote: > > v2: Fix the spelling of analyze and re-arrange code for better readability > > as per Connor's comments. > > v3: Make the naming of things more consistent and add a pile of comments

Re: [Mesa-dev] [PATCH v3 5/7] i965: Add a NIR analysis pass for determining when a boolean resolve is needed

2015-03-22 Thread Connor Abbott
On Fri, Mar 20, 2015 at 5:23 PM, Jason Ekstrand wrote: > v2: Fix the spelling of analyze and re-arrange code for better readability > as per Connor's comments. > v3: Make the naming of things more consistent and add a pile of comments > --- > src/mesa/drivers/dri/i965/Makefile.sources

Re: [Mesa-dev] [PATCH 10/11] i965/fs: Implement support for ir_barrier

2015-03-22 Thread Chris Forbes
Jordan, You also need to set m0.2:15 (Barrier count enable) and m0.2:14-9 (Barrier count) to have the message gateway actually collect the proper number of threads, right? - Chris On Mon, Mar 23, 2015 at 2:49 PM, Jordan Justen wrote: > Signed-off-by: Jordan Justen > Reviewed-by: Chris Forbes

Re: [Mesa-dev] [PATCH 03/11] nir: Add barrier intrinsic function

2015-03-22 Thread Connor Abbott
Reviewed-by: Connor Abbott On Sun, Mar 22, 2015 at 9:49 PM, Jordan Justen wrote: > Signed-off-by: Jordan Justen > Reviewed-by: Chris Forbes > --- > src/glsl/nir/glsl_to_nir.cpp | 4 +++- > src/glsl/nir/nir_intrinsics.h | 1 + > 2 files changed, 4 insertions(+), 1 deletion(-) > > diff --git a

Re: [Mesa-dev] [PATCH 10/11] i965/fs: Implement support for ir_barrier

2015-03-22 Thread Matt Turner
On Sun, Mar 22, 2015 at 6:49 PM, Jordan Justen wrote: > diff --git a/src/mesa/drivers/dri/i965/brw_fs_visitor.cpp > b/src/mesa/drivers/dri/i965/brw_fs_visitor.cpp > index 2b1b72f..5cde8f5 100644 > --- a/src/mesa/drivers/dri/i965/brw_fs_visitor.cpp > +++ b/src/mesa/drivers/dri/i965/brw_fs_visitor.

Re: [Mesa-dev] [PATCH 09/11] i965: Add brw_barrier to emit a Gateway Barrier SEND

2015-03-22 Thread Matt Turner
On Sun, Mar 22, 2015 at 6:49 PM, Jordan Justen wrote: > This will be used to implement the Gateway Barrier SEND needed to implement > the barrier function. > > Signed-off-by: Jordan Justen > Reviewed-by: Chris Forbes > --- > src/mesa/drivers/dri/i965/brw_eu.h | 3 +++ > src/mesa/drivers/d

Re: [Mesa-dev] [PATCH 08/11] i965: Add brw_wait to emit wait instruction

2015-03-22 Thread Matt Turner
On Sun, Mar 22, 2015 at 6:49 PM, Jordan Justen wrote: > This will be used to implement the barrier function. > > Signed-off-by: Jordan Justen > Reviewed-by: Chris Forbes > --- > src/mesa/drivers/dri/i965/brw_eu.h | 2 ++ > src/mesa/drivers/dri/i965/brw_eu_emit.c | 23 +

Re: [Mesa-dev] [PATCH 07/11] i965: Add notification register

2015-03-22 Thread Matt Turner
On Sun, Mar 22, 2015 at 6:49 PM, Jordan Justen wrote: > This will be used by the wait instruction when implementing the barrier() > function. > > Signed-off-by: Jordan Justen > Reviewed-by: Chris Forbes > --- > src/mesa/drivers/dri/i965/brw_reg.h | 16 > 1 file changed, 16 inse

Re: [Mesa-dev] [PATCH 01/11] glsl: Add ir node for barrier

2015-03-22 Thread Matt Turner
On Sun, Mar 22, 2015 at 6:49 PM, Jordan Justen wrote: > From: Chris Forbes > > [jordan.l.jus...@intel.com: Add nir support] > Signed-off-by: Jordan Justen > --- > src/glsl/ir.h | 24 > src/glsl/ir_hierarchical_visitor.cpp | 9

[Mesa-dev] [PATCH 11/11] i965/nir: Support barrier intrinsic function

2015-03-22 Thread Jordan Justen
Signed-off-by: Jordan Justen Reviewed-by: Chris Forbes --- src/mesa/drivers/dri/i965/brw_fs_nir.cpp | 4 1 file changed, 4 insertions(+) diff --git a/src/mesa/drivers/dri/i965/brw_fs_nir.cpp b/src/mesa/drivers/dri/i965/brw_fs_nir.cpp index 5d88fe7..0dddcbf 100644 --- a/src/mesa/drivers/dr

[Mesa-dev] [PATCH 01/11] glsl: Add ir node for barrier

2015-03-22 Thread Jordan Justen
From: Chris Forbes [jordan.l.jus...@intel.com: Add nir support] Signed-off-by: Jordan Justen --- src/glsl/ir.h | 24 src/glsl/ir_hierarchical_visitor.cpp | 9 + src/glsl/ir_hierarchical_visitor.h | 1 + sr

[Mesa-dev] [PATCH 06/11] i965: Disassemble Gateway SEND messages

2015-03-22 Thread Jordan Justen
Signed-off-by: Jordan Justen Reviewed-by: Chris Forbes --- src/mesa/drivers/dri/i965/brw_disasm.c | 16 1 file changed, 16 insertions(+) diff --git a/src/mesa/drivers/dri/i965/brw_disasm.c b/src/mesa/drivers/dri/i965/brw_disasm.c index c41dde2..9324bec 100644 --- a/src/mesa/dr

[Mesa-dev] [PATCH 07/11] i965: Add notification register

2015-03-22 Thread Jordan Justen
This will be used by the wait instruction when implementing the barrier() function. Signed-off-by: Jordan Justen Reviewed-by: Chris Forbes --- src/mesa/drivers/dri/i965/brw_reg.h | 16 1 file changed, 16 insertions(+) diff --git a/src/mesa/drivers/dri/i965/brw_reg.h b/src/mes

[Mesa-dev] [PATCH 05/11] i965/inst: Add notify and gateway_subfuncid fields

2015-03-22 Thread Jordan Justen
These fields will be used when emitting a send for the barrier function. Reference: IVB PRM Volume 4, Part 2, Section 1.1.1 Message Descriptor Signed-off-by: Jordan Justen Reviewed-by: Chris Forbes --- src/mesa/drivers/dri/i965/brw_inst.h | 18 +++--- 1 file changed, 15 insertions(

[Mesa-dev] [PATCH 09/11] i965: Add brw_barrier to emit a Gateway Barrier SEND

2015-03-22 Thread Jordan Justen
This will be used to implement the Gateway Barrier SEND needed to implement the barrier function. Signed-off-by: Jordan Justen Reviewed-by: Chris Forbes --- src/mesa/drivers/dri/i965/brw_eu.h | 3 +++ src/mesa/drivers/dri/i965/brw_eu_emit.c | 31 +++ 2 files ch

[Mesa-dev] [PATCH 08/11] i965: Add brw_wait to emit wait instruction

2015-03-22 Thread Jordan Justen
This will be used to implement the barrier function. Signed-off-by: Jordan Justen Reviewed-by: Chris Forbes --- src/mesa/drivers/dri/i965/brw_eu.h | 2 ++ src/mesa/drivers/dri/i965/brw_eu_emit.c | 23 +++ 2 files changed, 25 insertions(+) diff --git a/src/mesa/drivers

[Mesa-dev] [PATCH 03/11] nir: Add barrier intrinsic function

2015-03-22 Thread Jordan Justen
Signed-off-by: Jordan Justen Reviewed-by: Chris Forbes --- src/glsl/nir/glsl_to_nir.cpp | 4 +++- src/glsl/nir/nir_intrinsics.h | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/glsl/nir/glsl_to_nir.cpp b/src/glsl/nir/glsl_to_nir.cpp index 5543b38..98b3921 100644 --- a/sr

[Mesa-dev] [PATCH 10/11] i965/fs: Implement support for ir_barrier

2015-03-22 Thread Jordan Justen
Signed-off-by: Jordan Justen Reviewed-by: Chris Forbes --- src/mesa/drivers/dri/i965/brw_defines.h| 5 + src/mesa/drivers/dri/i965/brw_fs.h | 3 +++ src/mesa/drivers/dri/i965/brw_fs_generator.cpp | 11 +++ src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 27

[Mesa-dev] [PATCH 02/11] glsl: Add builtin barrier() function

2015-03-22 Thread Jordan Justen
From: Chris Forbes [jordan.l.jus...@intel.com: Add CS support] Signed-off-by: Jordan Justen --- src/glsl/builtin_functions.cpp | 29 + 1 file changed, 29 insertions(+) diff --git a/src/glsl/builtin_functions.cpp b/src/glsl/builtin_functions.cpp index c607572..a851cf

[Mesa-dev] [PATCH 04/11] i965: Add GATEWAY_SFID definitions

2015-03-22 Thread Jordan Justen
Signed-off-by: Jordan Justen Reviewed-by: Chris Forbes --- src/mesa/drivers/dri/i965/brw_defines.h | 8 1 file changed, 8 insertions(+) diff --git a/src/mesa/drivers/dri/i965/brw_defines.h b/src/mesa/drivers/dri/i965/brw_defines.h index da6ed5b..98a392a 100644 --- a/src/mesa/drivers/d

[Mesa-dev] [PATCH 00/11] Initial glsl + i965 barrier support

2015-03-22 Thread Jordan Justen
git://people.freedesktop.org/~jljusten/mesa i965-barrier-v1 These have been tested with CS on gen7 & gen8. There is more glsl barrer() work with regards to control flow requirements, but I think Chris already has some support for this in his TS branch. (CS will require some tweaks to that as well

[Mesa-dev] Correct behaviour of glDrawPixels and glBitmap when texturing is enabled.

2015-03-22 Thread Matthew Dawson
Hi all, I've been working fixing the piglit tests around glDrawPixels, and I'm not sure what the correct behaviour of glDrawPixels is when any texturing units are enabled (tested with the draw-pixel-with-texture piglit test). After asking on irc, imirkin suggested I bring the issue here as it

Re: [Mesa-dev] [PATCH 17/18] i965/cs: Add max_cs_threads

2015-03-22 Thread Ben Widawsky
On Sat, Mar 14, 2015 at 09:54:27PM -0700, Jordan Justen wrote: > Add some values for gen7 & gen8. These are the number threads in a > subslice. > > Signed-off-by: Jordan Justen > Cc: Ben Widawsky > Cc: Kenneth Graunke > --- > src/mesa/drivers/dri/i965/brw_context.c | 1 + > src/mesa/driver

[Mesa-dev] [PATCH v2 14/15] nvc0: make begin_query return false when all MP counters are used

2015-03-22 Thread Samuel Pitoiset
Signed-off-by: Samuel Pitoiset --- src/gallium/drivers/nouveau/nvc0/nvc0_query.c | 13 - 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_query.c b/src/gallium/drivers/nouveau/nvc0/nvc0_query.c index a63a740..c3a1899 100644 --- a/src

[Mesa-dev] [PATCH v2 13/15] nvc0: expose more driver-specific query groups

2015-03-22 Thread Samuel Pitoiset
This patch exposes "Driver statistics" and "MP counters" groups. Signed-off-by: Samuel Pitoiset --- src/gallium/drivers/nouveau/nvc0/nvc0_query.c | 61 -- src/gallium/drivers/nouveau/nvc0/nvc0_screen.h | 11 + 2 files changed, 69 insertions(+), 3 deletions(-) diff -

[Mesa-dev] [PATCH v2 11/15] nvc0: implement pipe_screen::get_driver_query_group_info

2015-03-22 Thread Samuel Pitoiset
This enables GL_AMD_performance_monitor for nvc0. Signed-off-by: Samuel Pitoiset --- src/gallium/drivers/nouveau/nvc0/nvc0_query.c | 10 ++ src/gallium/drivers/nouveau/nvc0/nvc0_screen.c | 1 + src/gallium/drivers/nouveau/nvc0/nvc0_screen.h | 3 +++ 3 files changed, 14 insertions(+)

[Mesa-dev] [PATCH v2 15/15] nvc0: all queries use an unsigned 64-bits integer by default

2015-03-22 Thread Samuel Pitoiset
Signed-off-by: Samuel Pitoiset --- src/gallium/drivers/nouveau/nvc0/nvc0_query.c | 12 +++- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_query.c b/src/gallium/drivers/nouveau/nvc0/nvc0_query.c index c3a1899..fcdb0a3 100644 --- a/src/

[Mesa-dev] [PATCH v2 10/15] radeon: implement pipe_screen::get_driver_query_group_info

2015-03-22 Thread Samuel Pitoiset
This enables GL_AMD_performance_monitor for radeon. Signed-off-by: Samuel Pitoiset Reviewed-by: Marek Olšák --- src/gallium/drivers/radeon/r600_pipe_common.c | 9 + src/gallium/drivers/radeon/r600_pipe_common.h | 1 + 2 files changed, 10 insertions(+) diff --git a/src/gallium/drivers/r

[Mesa-dev] [PATCH v2 07/15] gallium: add util_get_driver_query_group_info

2015-03-22 Thread Samuel Pitoiset
This function can be used to get a generic group of driver-specific queries when a driver doesn't expose any groups. Signed-off-by: Samuel Pitoiset --- src/gallium/auxiliary/Makefile.sources | 1 + src/gallium/auxiliary/util/u_query.c | 50 ++ src/gallium/auxil

[Mesa-dev] [PATCH v2 05/15] gallium: make pipe_context::begin_query return a boolean

2015-03-22 Thread Samuel Pitoiset
GL_AMD_performance_monitor must return an error when a monitoring session cannot be started. Signed-off-by: Samuel Pitoiset --- src/gallium/drivers/freedreno/freedreno_query.c| 4 ++-- src/gallium/drivers/freedreno/freedreno_query.h| 2 +- src/gallium/drivers/freedreno/freedreno_query_

[Mesa-dev] [PATCH v2 06/15] st/mesa: implement GL_AMD_performance_monitor

2015-03-22 Thread Samuel Pitoiset
From: Christoph Bumiller This is based on the original patch of Christoph Bumiller. (source: http://people.freedesktop.org/~chrisbmr/perfmon.diff) As for the Gallium HUD, we keep a list of busy queries in a ring buffer in order to prevent stalls when reading queries. Drivers must implement get_

[Mesa-dev] [PATCH v2 12/15] docs: mark GL_AMD_performance_monitor for the 10.6.0 release

2015-03-22 Thread Samuel Pitoiset
GL_AMD_performance_monitor is supported by nvc0, svga, freedreno, r600 and radeonsi. Signed-off-by: Samuel Pitoiset --- docs/relnotes/10.6.0.html | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/relnotes/10.6.0.html b/docs/relnotes/10.6.0.html index 005..391e076 100644 --- a/docs/rel

[Mesa-dev] [PATCH v2 03/15] gallium: add new numeric types to pipe_query_result

2015-03-22 Thread Samuel Pitoiset
This will be used by GL_AMD_performance_monitor. Signed-off-by: Samuel Pitoiset --- src/gallium/include/pipe/p_defines.h | 8 1 file changed, 8 insertions(+) diff --git a/src/gallium/include/pipe/p_defines.h b/src/gallium/include/pipe/p_defines.h index dcbb8fe..9f061f7 100644 --- a/sr

[Mesa-dev] [PATCH v2 01/15] gallium: add pipe_screen::get_driver_query_group_info

2015-03-22 Thread Samuel Pitoiset
Driver queries are organized as a single hierarchy where queries are categorized into groups. Each goup has a list of queries and a maximum number of queries that can be sampled. The list of available groups can be obtained using pipe_screen::get_driver_query_group_info. This will be used by GL_AM

[Mesa-dev] [PATCH v2 00/15] GL_AMD_performance_monitor

2015-03-22 Thread Samuel Pitoiset
Hello, A series I have waited too long to re-submit, but I recently refactored the code and fixed some minor issues. This patchset enables GL_AMD_performance_monitor for svga, freedreno, r600, radeonsi and nvc0 drivers. This code has been tested with Nouveau (NVD9 and NVE7) but it should also wo

[Mesa-dev] [PATCH v2 08/15] svga: implement pipe_screen::get_driver_query_group_info

2015-03-22 Thread Samuel Pitoiset
This enables GL_AMD_performance_monitor for svga. Signed-off-by: Samuel Pitoiset --- src/gallium/drivers/svga/svga_context.h | 1 + src/gallium/drivers/svga/svga_screen.c | 11 +++ 2 files changed, 12 insertions(+) diff --git a/src/gallium/drivers/svga/svga_context.h b/src/gallium/dr

[Mesa-dev] [PATCH v2 02/15] gallium: add new fields to pipe_driver_query_info

2015-03-22 Thread Samuel Pitoiset
According to the spec of GL_AMD_performance_monitor, valid type values returned are UNSIGNED_INT, UNSIGNED_INT64_AMD, PERCENTAGE_AMD, FLOAT. This also introduces the new field group_id in order to categorize queries into groups. v2: add PIPE_DRIVER_QUERY_TYPE_BYTES Signed-off-by: Samuel Pitoiset

[Mesa-dev] [PATCH v2 09/15] freedreno: implement pipe_screen::get_driver_query_group_info

2015-03-22 Thread Samuel Pitoiset
This enables GL_AMD_performance_monitor for freedreno. Signed-off-by: Samuel Pitoiset Reviewed-by: Rob Clark --- src/gallium/drivers/freedreno/freedreno_query.c | 9 + src/gallium/drivers/freedreno/freedreno_query.h | 1 + 2 files changed, 10 insertions(+) diff --git a/src/gallium/driv

[Mesa-dev] [PATCH v2 04/15] gallium: replace pipe_driver_query_info::max_value by a union

2015-03-22 Thread Samuel Pitoiset
This allows queries to return different numeric types. Signed-off-by: Samuel Pitoiset --- src/gallium/auxiliary/hud/hud_driver_query.c| 3 ++- src/gallium/drivers/freedreno/freedreno_query.c | 12 ++-- src/gallium/drivers/nouveau/nvc0/nvc0_query.c | 9 + src/gallium/drive

Re: [Mesa-dev] [RFC] More ARB_arrays_of_arrays support

2015-03-22 Thread Timothy Arceri
On Sat, 2015-03-21 at 09:27 -0700, Jason Ekstrand wrote: > > On Mar 21, 2015 2:49 AM, "Timothy Arceri" > wrote: > > > > This series adds most of the remaining glsl arrays of arrays > support. Support for uniform blocks is still missing, I've played > around with this but don't have anything worki