Re: [Mesa-dev] leak of gem_objects on intel i965

2011-06-17 Thread Lampersperger Andreas
Hello Kenneth, On 06/16/2011 12:10 AM, Lampersperger Andreas wrote: Hello Stéphane, I've tried your patch (I adopted it to 7.10.3, see attached patch), but it results in a SEGFAULT: Thread [1] 12367 (Suspended : Signal : SIGSEGV:Segmentation fault)

[Mesa-dev] leak of gem_objects on intel i965

2011-06-17 Thread Lampersperger Andreas
Hello Stéphane, I've applied your Patch against git mesa from yesterday. It also results in the same SEGFAULT running simple from the gtkglext examples. (see backtrace below, in st_visual_to_context_mode(..) visual is not initialized properly). When I try pure mesa git from yesterday, no

Re: [Mesa-dev] [PATCH] glx: implement drawable refcounting.

2011-06-17 Thread Adam Jackson
On 6/15/11 6:22 PM, Stéphane Marchesin wrote: The current dri context unbind logic will leak drawables until the process dies (they will then get released by the GEM code). There are two ways to fix this: either always call driReleaseDrawables every time we unbind a context (but that costs us

Re: [Mesa-dev] Mesa 7.10.3 release

2011-06-17 Thread Brian Paul
On Thu, Jun 16, 2011 at 2:41 PM, Kenneth Graunke kenn...@whitecape.org wrote: On 06/14/2011 12:22 PM, Chad Versace wrote: On Tue, 14 Jun 2011 13:09:50 +0200, Andreas Radkea.ra...@arcor.de  wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Can you please confirm the tarballs. gzip and

[Mesa-dev] [PATCH 3/3] r600g: fix LIT to handle src==dst properly

2011-06-17 Thread Vadim Girlin
Current LIT implementation uses dst components for storing temp results, possibly overwriting still needed values (depends on the swizzles). This patch uses temp reg for one of such cases (found in etqw) and fixes LIT R.z, R.xyzz. Tested on evergreen. Fixes some etqw-demo rendering glitches when

Re: [Mesa-dev] [PATCH] st/mesa: try the app's texture format first before using the internal format.

2011-06-17 Thread Brian Paul
On 06/17/2011 12:34 PM, Stéphane Marchesin wrote: If we can find it, that means we don't need to do texture format conversion and therefore we get fast texture uploads for natively supported formats. --- src/mesa/state_tracker/st_format.c | 25 + 1 files changed, 17

[Mesa-dev] [PATCH 3/4 resend] glx: Destroy the old context only after the new one has been bound

2011-06-17 Thread Jeremy Huddleston
This fixes a regression introduced by 49d7e48b33264d94e30af6129c281b6acafa9427 Signed-off-by: Jeremy Huddleston jerem...@apple.com --- src/glx/glxcurrent.c | 14 +++--- 1 files changed, 7 insertions(+), 7 deletions(-) diff --git origin/master/src/glx/glxcurrent.c

[Mesa-dev] PATCH 1/4 resend] glapi: Update specs to correctly list FramebufferTextureLayerARB as an alias of FramebufferTextureLayerEXT

2011-06-17 Thread Jeremy Huddleston
FramebufferTextureLayer is an alias of FramebufferTextureLayerEXT, so FramebufferTextureLayerARB needs to be listed as an alias of FramebufferTextureLayerEXT rather than FramebufferTextureLayer. Signed-off-by: Jeremy Huddleston jerem...@apple.com --- src/mapi/glapi/gen/ARB_geometry_shader4.xml

[Mesa-dev] [PATCH 4/4 resend] glx: Bind to our context before __glXSetCurrentContext

2011-06-17 Thread Jeremy Huddleston
We want to bind to our context before calling __glXSetCurrentContext or messing with the gc rect in order to properly handle error conditions. Signed-off-by: Jeremy Huddleston jerem...@apple.com --- src/glx/glxcurrent.c | 25 - 1 files changed, 16 insertions(+), 9

[Mesa-dev] [PATCH 1/2] ARB_vertex_buffer_object/elements-negative-offset: Pretty up the test name.

2011-06-17 Thread Eric Anholt
--- tests/all.tests |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/tests/all.tests b/tests/all.tests index 69c6477..6f0378a 100644 --- a/tests/all.tests +++ b/tests/all.tests @@ -873,7 +873,7 @@ add_texwrap_test2(arb_texture_compression, '2D', 'GL_COMPRESSED_RGBA')

[Mesa-dev] [PATCH 2/2] vbo: Don't discount stride == 0 for testing all varyings in VBOs.

2011-06-17 Thread Eric Anholt
In fixed function, stride == 0 (e.g. glColor4f() outside of the draw call) would get turned into uniform inputs, which is why it was ignored originally in this test. For shaders, drivers end up seeing a need to upload stride == 0 data, and get confused by needing to upload when

[Mesa-dev] [PATCH 1/2] vbo: Don't bother checking for stride == 0 for any varying in a VBO.

2011-06-17 Thread Eric Anholt
We would still want to consider that data as being in a VBO even if we managed to produce this case, which as far as I know we can't. --- src/mesa/vbo/vbo_rebase.c |3 +-- 1 files changed, 1 insertions(+), 2 deletions(-) diff --git a/src/mesa/vbo/vbo_rebase.c b/src/mesa/vbo/vbo_rebase.c

[Mesa-dev] [PATCH 2/2] ARB_vertex_buffer_object/mixed-immediate-and-vbo: New test for #37934.

2011-06-17 Thread Eric Anholt
--- tests/all.tests|1 + .../arb_vertex_buffer_object/CMakeLists.gl.txt |1 + .../mixed-immediate-and-vbo.c | 108 3 files changed, 110 insertions(+), 0 deletions(-) create mode 100644

Re: [Mesa-dev] [PATCH 1/2] vbo: Don't bother checking for stride == 0 for any varying in a VBO.

2011-06-17 Thread Brian Paul
On 06/17/2011 02:36 PM, Eric Anholt wrote: We would still want to consider that data as being in a VBO even if we managed to produce this case, which as far as I know we can't. --- src/mesa/vbo/vbo_rebase.c |3 +-- 1 files changed, 1 insertions(+), 2 deletions(-) diff --git

Re: [Mesa-dev] [PATCH 2/2] vbo: Don't discount stride == 0 for testing all varyings in VBOs.

2011-06-17 Thread Brian Paul
On 06/17/2011 02:36 PM, Eric Anholt wrote: In fixed function, stride == 0 (e.g. glColor4f() outside of the draw call) would get turned into uniform inputs, which is why it was ignored originally in this test. For shaders, drivers end up seeing a need to upload stride == 0 data, and get confused

Re: [Mesa-dev] [PATCH 2/2] ARB_vertex_buffer_object/mixed-immediate-and-vbo: New test for #37934.

2011-06-17 Thread Brian Paul
On 06/17/2011 02:36 PM, Eric Anholt wrote: --- tests/all.tests|1 + .../arb_vertex_buffer_object/CMakeLists.gl.txt |1 + .../mixed-immediate-and-vbo.c | 108 3 files changed, 110 insertions(+), 0

[Mesa-dev] [PATCH 0/4] i965: Support s8_z24 non-texture renderbuffers when using separate stencil

2011-06-17 Thread Chad Versace
This adds all necessary infrastructure to support s8_z24 non-texture renderbuffers on gen7. Chad Versace (4): intel: Unconditionally enable support for S8_Z24 texture format intel: Add fields to intel_renderbuffer for unwrapping packed depth/stencil buffers intel: Unobfuscate

[Mesa-dev] [PATCH 1/4] intel: Unconditionally enable support for S8_Z24 texture format

2011-06-17 Thread Chad Versace
Commit b5c847c7ca06823af3b72324056a2e478caca70b erroneously disabled support for S8_Z24 texture format when the context required separate stencil (intel_context.must_use_separate_stencil). But the GL spec requires implementations to support GL_DEPTH24_STENCIL8. So we better find a way to fake

[Mesa-dev] [PATCH 2/4] intel: Add fields to intel_renderbuffer for unwrapping packed depth/stencil buffers

2011-06-17 Thread Chad Versace
Add the following fields: intel_renderbuffer.wrapped_depth; intel_renderbuffer.wrapped_stencil If the intel_context is using separate stencil and the renderbuffer has a packed depth/stencil format, then wrapped_depth and wrapped_stencil are the real renderbuffers. Alter the following

[Mesa-dev] [PATCH 4/4] intel: Allocate s8_z24 non-texture renderbuffers when using separate stencil

2011-06-17 Thread Chad Versace
Now all infrastructure is in place to support s8_z24 non-texture renderbuffers for gen7. Signed-off-by: Chad Versace c...@chad-versace.us --- src/mesa/drivers/dri/intel/intel_fbo.c | 84 ++- 1 files changed, 81 insertions(+), 3 deletions(-) diff --git

Re: [Mesa-dev] [PATCH] st/mesa: try the app's texture format first before using the internal format.

2011-06-17 Thread Stéphane Marchesin
2011/6/17 Brian Paul bri...@vmware.com: On 06/17/2011 12:34 PM, Stéphane Marchesin wrote: If we can find it, that means we don't need to do texture format conversion and therefore we get fast texture uploads for natively supported formats. ---  src/mesa/state_tracker/st_format.c |   25

[Mesa-dev] [Bug 9951] GL_LINE_SMOOTH and GL_POLYGON_SMOOTH with i965 driver

2011-06-17 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=9951 Eric Anholt e...@anholt.net changed: What|Removed |Added Status|NEW |RESOLVED

[Mesa-dev] [PATCH 0/6] glsl: Add support for switch statements

2011-06-17 Thread Dan McCabe
This patch set adds support for switch statements to the GLSL compiler. We modify the grammar for the compiler with productions for switch statements and case labels, while adding supporting supporting productions not already present. New AST classes are defined to support those productions.

[Mesa-dev] [PATCH 1/6] glsl: Create AST data structures for switch statement and case label

2011-06-17 Thread Dan McCabe
Data structures for switch statement and case label are created that parallel the structure of other AST data. --- src/glsl/ast.h | 24 1 files changed, 20 insertions(+), 4 deletions(-) diff --git a/src/glsl/ast.h b/src/glsl/ast.h index 878f48b..39a59d4 100644 ---

[Mesa-dev] [PATCH 2/6] glsl: Add productions to GLSL grammar for switch statement

2011-06-17 Thread Dan McCabe
The grammar is modified to support switch statements. Rather than follow the grammar in the appendix, which allows case labels to be placed ANYWHERE as a regular statement, we follow the development of the grammar as described in the body of the GLSL. In this variation, the switch statement has a

[Mesa-dev] [PATCH 3/6] glsl: Create AST structs corresponding to new productions in grammar

2011-06-17 Thread Dan McCabe
Previously we added productions for: switch_body case_label_list case_statement case_statement_list Now add AST structs corresponding to those productions. --- src/glsl/ast.h | 49 + 1 files changed, 49

[Mesa-dev] [PATCH 4/6] glsl: Reference data structure ctors in grammar

2011-06-17 Thread Dan McCabe
We now tie the grammar to the ctors of the ASTs they reference. This requires that we actually have definitions of the ctors. In addition, we also need to define print and hir methods for the AST classes. At this stage of the development, we simply stub out the print and hir methods and flesh

[Mesa-dev] [PATCH 6/6] glsl: Generate IR for switch statements

2011-06-17 Thread Dan McCabe
Beware! Here be dragons! Up until now modyfing the GLSL compiler has been pretty straightforward. This is where things get interesting. Switch statement processing leverages infrastructure that was previously created (specifically for break statements, which are encountered in both loops and

[Mesa-dev] [PATCH 0/8]: Enabling GL_ARB_shader_texture_lod, take 2

2011-06-17 Thread Kenneth Graunke
Hey! Version 2 of my GL_ARB_shader_texture_lod patches. Patches 1, 5, and 8 are the same; unfortunately, the rest changed. I added ten new piglit tests for shadow2DGradARB---essentially, copy and paste of glsl-fs-shadow2D-0*.shader_test, but using dPdx and dPdy. The tenth one combines them all

[Mesa-dev] [PATCH 2/8] i965/fs: Add support for non-shadow textureGrad (TXD) on Ivybridge.

2011-06-17 Thread Kenneth Graunke
This is somewhat ugly, but I couldn't think of a nicer way to handle the interleaved coordinate/derivative parameter loading. Ironlake and Sandybridge will still hit an assertion in visit(). Signed-off-by: Kenneth Graunke kenn...@whitecape.org --- src/mesa/drivers/dri/i965/brw_fs_emit.cpp|

[Mesa-dev] [PATCH 3/8] i965/fs: Add support for non-shadow textureGrad (TXD) on gen5/6.

2011-06-17 Thread Kenneth Graunke
Signed-off-by: Kenneth Graunke kenn...@whitecape.org --- src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 32 +- 1 files changed, 31 insertions(+), 1 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_fs_visitor.cpp b/src/mesa/drivers/dri/i965/brw_fs_visitor.cpp

[Mesa-dev] [PATCH 4/8] i965/fs: Add support for non-shadow textureGrad (TXD) on gen4.

2011-06-17 Thread Kenneth Graunke
Signed-off-by: Kenneth Graunke kenn...@whitecape.org --- src/mesa/drivers/dri/i965/brw_fs_emit.cpp|4 ++- src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 37 +- 2 files changed, 39 insertions(+), 2 deletions(-) diff --git

[Mesa-dev] [PATCH 5/8] i965/fs: Move sampler fetch to the top of the ir_texture visit function.

2011-06-17 Thread Kenneth Graunke
This makes it available earlier, which will soon be necessary. (Separating code motion from actual changes.) Signed-off-by: Kenneth Graunke kenn...@whitecape.org --- src/mesa/drivers/dri/i965/brw_fs_visitor.cpp |9 +++-- 1 files changed, 3 insertions(+), 6 deletions(-) diff --git

[Mesa-dev] [PATCH 7/8] i965/fs: Add support for TXD with shadow comparisons.

2011-06-17 Thread Kenneth Graunke
Our hardware doesn't have a sample_d_c message, so we have to do a regular sample_d and emit instructions to manually perform the comparison. This requires a state dependent recompile whenever the sampler's compare mode or function change. This adds the per-sampler comparison functions to

Re: [Mesa-dev] [PATCH 1/4] i965/gen6: Factor the PIPE_CONTROL workaround to a separate function.

2011-06-17 Thread Kenneth Graunke
On 06/17/2011 06:46 PM, Eric Anholt wrote: We're need this workaorund a lot more than we're currently doing, so let's reuse it. --- src/mesa/drivers/dri/intel/intel_batchbuffer.c | 29 +-- 1 files changed, 21 insertions(+), 8 deletions(-) diff --git