Re: [Mesa-dev] [PATCH] gallium: implement WGL_ARB_create_context

2011-10-19 Thread morgan devel
Sorry about the missing file. Here is the patch taking into account your remarks. --- src/gallium/state_trackers/wgl/SConscript |1 + src/gallium/state_trackers/wgl/stw_context.c | 130 src/gallium/state_trackers/wgl/stw_context.h |3 + src/galli

Re: [Mesa-dev] [PATCH] Add solaris detection for PIPE_ARCH_LITTLE_ENDIAN/PIPE_ARCH_BIG_ENDIAN

2011-10-19 Thread Jose Fonseca
Looks good to me. Jose - Original Message - > Signed-off-by: Alan Coopersmith > --- > src/gallium/include/pipe/p_config.h |9 + > 1 files changed, 9 insertions(+), 0 deletions(-) > > diff --git a/src/gallium/include/pipe/p_config.h > b/src/gallium/include/pipe/p_config.h >

Re: [Mesa-dev] [PATCH 2/2] i965: Avoid generating MOVs for most ir_assignment handling.

2011-10-19 Thread Stéphane Marchesin
On Sat, Aug 27, 2011 at 03:23, Kenneth Graunke wrote: > This is a port of vec4_visitor::try_rewrite_rhs_to_dst to fs_visitor. > > Not only is this technique less invasive and more robust, it also > generates better code.  Over and above the previous technique, this > reduced instruction count in s

[Mesa-dev] [PATCH] Add solaris detection for PIPE_ARCH_LITTLE_ENDIAN/PIPE_ARCH_BIG_ENDIAN

2011-10-19 Thread Alan Coopersmith
Signed-off-by: Alan Coopersmith --- src/gallium/include/pipe/p_config.h |9 + 1 files changed, 9 insertions(+), 0 deletions(-) diff --git a/src/gallium/include/pipe/p_config.h b/src/gallium/include/pipe/p_config.h index b3a7b33..7cd42c6 100644 --- a/src/gallium/include/pipe/p_config

Re: [Mesa-dev] [PATCH 4/4 v2] mesa, intel: use _mesa_image_offset() for PBOs

2011-10-19 Thread Brian Paul
On Wed, Oct 19, 2011 at 6:13 PM, nobled wrote: > This avoids forming invalid pointers needlessly, which even if > never dereferenced is undefined behavior. It also makes > _mesa_validate_pbo_access() more comprehensible. > --- > v2: Now rebased on top of the recent commit 9024d8af0ae. Reviewed-by

Re: [Mesa-dev] [PATCH 2/4 v2] mesa/image: assert on bad format

2011-10-19 Thread Brian Paul
On Wed, Oct 19, 2011 at 6:10 PM, nobled wrote: > NULL as an error indicator is meaningless, since it will return NULL > on success anyway if the caller passes in zero as the image's address > and asks to calculate the offset of the first pixel. For example, > _mesa_validate_pbo_access() does this.

Re: [Mesa-dev] [PATCH] mesa: Fix detection of whether an ARB_vp is enabled for two sided lighting.

2011-10-19 Thread Eric Anholt
On Wed, 19 Oct 2011 11:28:42 -0600, Brian Paul wrote: > On 10/19/2011 10:49 AM, Eric Anholt wrote: > > When there is no ARB_vertex_program program enabled, the Current > > pointer points at a default program, so we were always using > > VERTEX_PROGRAM_TWO_SIDE, even for fixed function lighting. >

[Mesa-dev] Radeon DRI1 removal

2011-10-19 Thread Eric Anholt
For the MapRenderbuffer() code (See http://cgit.freedesktop.org/~anholt/mesa/log/?h=rbmap for the current work, which has glReadPixels() converted so far and tested on gen6 with only one regression in the tip commit), I need to be able to provide a linear mapping of arbitrary renderbuffers. Radeon

Re: [Mesa-dev] [PATCH 2/2] i965: use a cast to silence a signed/unsigned comparison warning

2011-10-19 Thread Brian Paul
On 10/19/2011 02:24 PM, Paul Berry wrote: On 19 October 2011 12:58, Brian Paul mailto:bri...@vmware.com>> wrote: On 10/19/2011 01:53 PM, Paul Berry wrote: On 18 October 2011 18:07, Brian Paul mailto:brian.e.p...@gmail.com>

[Mesa-dev] [PATCH 4/4 dri] Revert "Duplicate state_tracker/dri/sw/dri_drawable.c"

2011-10-19 Thread nobled
This reverts commit 569bde1fa7d03fb7688d0d391b32e61e857ad44e. --- src/gallium/state_trackers/dri/sw/dri_drawable.c | 274 +- 1 files changed, 1 insertions(+), 273 deletions(-) mode change 100644 => 12 src/gallium/state_trackers/dri/sw/dri_drawable.c diff --git a/src/gall

[Mesa-dev] [PATCH 3/4 dri] st/dri: sync the sw/ changes to dri_drawable.c

2011-10-19 Thread nobled
The sw copy needs to go away. It's already missing several new patches to the original. --- .../state_trackers/dri/common/dri_drawable.c | 13 - 1 files changed, 8 insertions(+), 5 deletions(-) diff --git a/src/gallium/state_trackers/dri/common/dri_drawable.c b/src/gallium/sta

[Mesa-dev] [PATCH 2/4 dri] st/dri: add copy_drawable() callback

2011-10-19 Thread nobled
This moves drisw-specific code into drisw.c, making it possible to eliminate the extra copy of dri_drawable.c. --- .../state_trackers/dri/common/dri_context.h|4 ++ src/gallium/state_trackers/dri/drm/dri2.c | 26 +- src/gallium/state_trackers/dri/sw/dri_drawable.c

[Mesa-dev] [PATCH 1/4 dri] st/dri: factor out software texbuffer code

2011-10-19 Thread nobled
--- src/gallium/state_trackers/dri/sw/dri_drawable.c | 72 -- 1 files changed, 40 insertions(+), 32 deletions(-) diff --git a/src/gallium/state_trackers/dri/sw/dri_drawable.c b/src/gallium/state_trackers/dri/sw/dri_drawable.c index 05c64b6..66997fb 100644 --- a/src/gallium/s

[Mesa-dev] [PATCH 4/4 v2] mesa, intel: use _mesa_image_offset() for PBOs

2011-10-19 Thread nobled
This avoids forming invalid pointers needlessly, which even if never dereferenced is undefined behavior. It also makes _mesa_validate_pbo_access() more comprehensible. --- v2: Now rebased on top of the recent commit 9024d8af0ae. src/mesa/drivers/dri/intel/intel_pixel_read.c |5 ++- src/mesa/m

[Mesa-dev] [PATCH 2/4 v2] mesa/image: assert on bad format

2011-10-19 Thread nobled
NULL as an error indicator is meaningless, since it will return NULL on success anyway if the caller passes in zero as the image's address and asks to calculate the offset of the first pixel. For example, _mesa_validate_pbo_access() does this. This also matches the code in the non-GL_BITMAP codepa

Re: [Mesa-dev] [PATCH] Only use gcc visibility support with gcc4+.

2011-10-19 Thread Alan Coopersmith
On 10/19/11 13:44, Tom Fogal wrote: I had a colleague hitting issues compiling with an old gcc3.2 system. These patches got them through. --- include/GL/gl.h |2 +- src/mesa/main/compiler.h |2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/GL/gl.h

Re: [Mesa-dev] [PATCH] gallium: implement WGL_ARB_create_context

2011-10-19 Thread Jose Fonseca
- Original Message - > --- > src/gallium/state_trackers/wgl/SConscript |1 + > src/gallium/state_trackers/wgl/stw_context.c | 39 > ++-- > .../state_trackers/wgl/stw_getprocaddress.c|3 ++ > src/gallium/state_trackers/wgl/stw_icd.h

[Mesa-dev] [PATCH] gallium: implement WGL_ARB_create_context

2011-10-19 Thread morgan devel
--- src/gallium/state_trackers/wgl/SConscript |1 + src/gallium/state_trackers/wgl/stw_context.c | 39 ++-- .../state_trackers/wgl/stw_getprocaddress.c|3 ++ src/gallium/state_trackers/wgl/stw_icd.h |8 4 files changed, 48 inserti

[Mesa-dev] [PATCH] Only use gcc visibility support with gcc4+.

2011-10-19 Thread Tom Fogal
I had a colleague hitting issues compiling with an old gcc3.2 system. These patches got them through. --- include/GL/gl.h |2 +- src/mesa/main/compiler.h |2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/GL/gl.h b/include/GL/gl.h index 998a83a..e65e1bc

Re: [Mesa-dev] [PATCH 2/2] i965: use a cast to silence a signed/unsigned comparison warning

2011-10-19 Thread Paul Berry
On 19 October 2011 12:58, Brian Paul wrote: > On 10/19/2011 01:53 PM, Paul Berry wrote: > >> On 18 October 2011 18:07, Brian Paul > > wrote: >> >>From: Brian Paul mailto:bri...@vmware.com>> >> >> >>--- >> .../drivers/dri/i965/brw_vec4_**reg_allocate.c

Re: [Mesa-dev] [PATCH] glsl-fs-normalmatrix: New test program for gl_NormalMatrix.

2011-10-19 Thread Paul Berry
On 18 October 2011 17:33, Eric Anholt wrote: > From: tom fogal > > v2: lots of hacking by anholt to make it look more like a normal >piglit test and make all results visible at once. > --- > tests/all.tests |1 + > tests/shaders/CMakeLists.gl.txt |1 + > te

Re: [Mesa-dev] [PATCH 2/2] i965: use a cast to silence a signed/unsigned comparison warning

2011-10-19 Thread Brian Paul
On 10/19/2011 01:53 PM, Paul Berry wrote: On 18 October 2011 18:07, Brian Paul mailto:brian.e.p...@gmail.com>> wrote: From: Brian Paul mailto:bri...@vmware.com>> --- .../drivers/dri/i965/brw_vec4_reg_allocate.cpp |2 +- 1 files changed, 1 insertions(+), 1 deletions(-)

Re: [Mesa-dev] [PATCH 2/2] i965: use a cast to silence a signed/unsigned comparison warning

2011-10-19 Thread Paul Berry
On 18 October 2011 18:07, Brian Paul wrote: > From: Brian Paul > > --- > .../drivers/dri/i965/brw_vec4_reg_allocate.cpp |2 +- > 1 files changed, 1 insertions(+), 1 deletions(-) > > diff --git a/src/mesa/drivers/dri/i965/brw_vec4_reg_allocate.cpp > b/src/mesa/drivers/dri/i965/brw_vec4_r

Re: [Mesa-dev] [PATCH 1/2] i965: silence signed/unsigned comparison warning

2011-10-19 Thread Paul Berry
On 18 October 2011 18:07, Brian Paul wrote: > From: Brian Paul > > --- > src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp |3 ++- > 1 files changed, 2 insertions(+), 1 deletions(-) > > diff --git a/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp > b/src/mesa/drivers/dri/i965/brw_vec4_visitor.c

Re: [Mesa-dev] [PATCH] glsl: Fix gl_NormalMatrix swizzle setup to match i965's invariants.

2011-10-19 Thread Paul Berry
On 18 October 2011 17:33, Eric Anholt wrote: > A driver trying to set up builtin uniforms is faced with a problem: > How do I walk the ir_variable structure (representing an array of > structs, or array of matrices, or struct, or whatever), and set up > driver structures so that dereference of th

Re: [Mesa-dev] [PATCH 5/5] intel: Remove intel_renderbuffer::hiz_region

2011-10-19 Thread Chad Versace
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 10/18/2011 03:57 PM, Eric Anholt wrote: > On Mon, 17 Oct 2011 07:40:28 -0700, Chad Versace wrote: >> Replace it with intel_renderbuffer::region::hiz::region. >> >> Signed-off-by: Chad Versace >> --- >> src/mesa/drivers/dri/i965/brw_misc_state.c

Re: [Mesa-dev] [PATCH 4/5] intel: Add function intel_renderbuffer_hiz_alloc

2011-10-19 Thread Chad Versace
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 10/18/2011 03:51 PM, Eric Anholt wrote: > On Mon, 17 Oct 2011 07:40:27 -0700, Chad Versace wrote: >> This function allocates the HiZ region and initializes the HiZ control >> state for a depthbuffer. >> >> It is wise to define the logic for HiZ reg

Re: [Mesa-dev] [PATCH] mesa: Fix detection of whether an ARB_vp is enabled for two sided lighting.

2011-10-19 Thread Brian Paul
On 10/19/2011 10:49 AM, Eric Anholt wrote: When there is no ARB_vertex_program program enabled, the Current pointer points at a default program, so we were always using VERTEX_PROGRAM_TWO_SIDE, even for fixed function lighting. Fixes piglit two-sided-lighting* --- src/mesa/main/state.c |2

[Mesa-dev] [Bug 34401] glXGetScreenDriver doesn't report the same driver name as used in ~/.drirc

2011-10-19 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=34401 Michal Suchanek changed: What|Removed |Added CC||hramr...@gmail.com -- Configure bugma

[Mesa-dev] [PATCH] mesa: Fix detection of whether an ARB_vp is enabled for two sided lighting.

2011-10-19 Thread Eric Anholt
When there is no ARB_vertex_program program enabled, the Current pointer points at a default program, so we were always using VERTEX_PROGRAM_TWO_SIDE, even for fixed function lighting. Fixes piglit two-sided-lighting* --- src/mesa/main/state.c |2 +- 1 files changed, 1 insertions(+), 1 deleti

Re: [Mesa-dev] [PATCH 1/3] i965: Fix incorrect dirty bit in gen6_prepare_wm_push_constants.

2011-10-19 Thread Eric Anholt
On Tue, 18 Oct 2011 17:05:28 -0700, Kenneth Graunke wrote: > We definitely want CACHE_NEW_WM_PROG, not CACHE_NEW_VS_PROG. > > NOTE: This is a candidate for the 7.11 branch. > > Signed-off-by: Kenneth Graunke This series is Reviewed-by: Eric Anholt > --- > src/mesa/drivers/dri/i965/gen6_wm_

Re: [Mesa-dev] r600g shader optimization

2011-10-19 Thread Vadim Girlin
On Wed, 2011-10-19 at 10:49 -0400, Tom Stellard wrote: > On Fri, 2011-10-07 at 10:14 -0400, Vadim Girlin wrote: > > Hi, > > > > Recently I've been working on the shader optimization for r600g, and now > > I have the initial working implementation of simple alu scheduler and > > register allocator.

Re: [Mesa-dev] [PATCH] glsl-fs-normalmatrix: New test program for gl_NormalMatrix.

2011-10-19 Thread tom fogal
Not sure this needs it, but LGTM. You might want to add yourself to the "Authors" comment, but *shrug*. -tom On 10/18/2011 06:33 PM, Eric Anholt wrote: From: tom fogal v2: lots of hacking by anholt to make it look more like a normal piglit test and make all results visible at once. ---

[Mesa-dev] remove unused but set variables

2011-10-19 Thread Fabio Pedretti
from osmesa, radeon and r600 classic drivers.diff --git a/src/mesa/drivers/dri/r600/evergreen_fragprog.c b/src/mesa/drivers/dri/r600/evergreen_fragprog.c index cc584ca..10c88d7 100644 --- a/src/mesa/drivers/dri/r600/evergreen_fragprog.c +++ b/src/mesa/drivers/dri/r600/evergreen_fragprog.c @@ -498,7

[Mesa-dev] [Bug 41999] New: GL_OES_mapbuffer is advertised but calling glMapBufferOES throws a warning

2011-10-19 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=41999 Bug #: 41999 Summary: GL_OES_mapbuffer is advertised but calling glMapBufferOES throws a warning Classification: Unclassified Product: Mesa Version: git Platform: Othe

Re: [Mesa-dev] r600g shader optimization

2011-10-19 Thread Tom Stellard
On Fri, 2011-10-07 at 10:14 -0400, Vadim Girlin wrote: > Hi, > > Recently I've been working on the shader optimization for r600g, and now > I have the initial working implementation of simple alu scheduler and > register allocator. It has no piglit regressions, though it's still a > work in progre

Re: [Mesa-dev] [PATCH] mesa: handle PBO access error in display list mode

2011-10-19 Thread Brian Paul
On 10/18/2011 09:20 PM, Yuanhan Liu wrote: Simply generate GL_INVALID_OPERATION error at display list mode. As explained by Brian, we are going to access PBO data at compile time. No need to defer the error at execution time. Signed-off-by: Yuanhan Liu --- src/mesa/main/dlist.c |2 ++ 1 f

Re: [Mesa-dev] [PATCH] mesa: Fix multithreaded buffer object refcounting.

2011-10-19 Thread Brian Paul
On 10/19/2011 12:00 AM, Mathias Fröhlich wrote: Hi Brian, On Tuesday, October 18, 2011 17:05:53 Brian Paul wrote: This was brought up a few weeks ago by someone else. I had posted the start of a patch to fix it. I'm attaching an updated version that I think is pretty clean. But there's a fe

Re: [Mesa-dev] [PATCH 4/4] mesa, intel: use _mesa_image_offset() for PBOs

2011-10-19 Thread Brian Paul
On 10/19/2011 06:03 AM, nobled wrote: This avoids forming invalid pointers needlessly, which even if never dereferenced is undefined behavior. It also makes _mesa_validate_pbo_access() more comprehensible. Reviewed-by: Brian Paul BTW, be sure to test these changes with the glean pbo test. It

Re: [Mesa-dev] [PATCH 3/4] mesa: add _mesa_image_offset()

2011-10-19 Thread Brian Paul
On 10/19/2011 06:03 AM, nobled wrote: --- src/mesa/main/image.c | 67 src/mesa/main/image.h |7 + 2 files changed, 57 insertions(+), 17 deletions(-) Reviewed-by: Brian Paul ___ mesa-dev m

Re: [Mesa-dev] [PATCH 2/4] mesa/image: assert on bad format

2011-10-19 Thread Brian Paul
On 10/19/2011 06:02 AM, nobled wrote: NULL as an error indicator is meaningless, since it will return NULL on success anyway if the caller passes in zero as the image's address and asks to calculate the offset of the first pixel. For example, _mesa_validate_pbo_access() does this. This also matc

Re: [Mesa-dev] [PATCH 1/4] mesa/image: delete dead store

2011-10-19 Thread Brian Paul
On 10/19/2011 06:02 AM, nobled wrote: The return value here is a) always zero, b) never used. --- src/mesa/main/image.c |7 --- 1 files changed, 0 insertions(+), 7 deletions(-) diff --git a/src/mesa/main/image.c b/src/mesa/main/image.c index 7d95dd6..ca5771c 100644 --- a/src/mesa/main

Re: [Mesa-dev] [PATCH] texgetimage: add missing return on error

2011-10-19 Thread Brian Paul
On 10/19/2011 05:54 AM, nobled wrote: Missed this back in the arb_robustness branch <6b329b9274b18c50f4177eef7ee087d50ebc1525>. --- src/mesa/main/texgetimage.c |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/src/mesa/main/texgetimage.c b/src/mesa/main/texgetimage.c ind

[Mesa-dev] [PATCH 4/4] mesa, intel: use _mesa_image_offset() for PBOs

2011-10-19 Thread nobled
This avoids forming invalid pointers needlessly, which even if never dereferenced is undefined behavior. It also makes _mesa_validate_pbo_access() more comprehensible. --- src/mesa/drivers/dri/intel/intel_pixel_read.c |5 +++-- src/mesa/main/pbo.c | 25 +

[Mesa-dev] [PATCH 3/4] mesa: add _mesa_image_offset()

2011-10-19 Thread nobled
--- src/mesa/main/image.c | 67 src/mesa/main/image.h |7 + 2 files changed, 57 insertions(+), 17 deletions(-) diff --git a/src/mesa/main/image.c b/src/mesa/main/image.c index 3e0ca05..ba66c8a 100644 --- a/src/mesa/main/image.c +++ b/src/

[Mesa-dev] [PATCH 2/4] mesa/image: assert on bad format

2011-10-19 Thread nobled
NULL as an error indicator is meaningless, since it will return NULL on success anyway if the caller passes in zero as the image's address and asks to calculate the offset of the first pixel. For example, _mesa_validate_pbo_access() does this. This also matches the code in the non-GL_BITMAP codepa

[Mesa-dev] [PATCH 1/4] mesa/image: delete dead store

2011-10-19 Thread nobled
The return value here is a) always zero, b) never used. --- src/mesa/main/image.c |7 --- 1 files changed, 0 insertions(+), 7 deletions(-) diff --git a/src/mesa/main/image.c b/src/mesa/main/image.c index 7d95dd6..ca5771c 100644 --- a/src/mesa/main/image.c +++ b/src/mesa/main/image.c @@ -1

[Mesa-dev] [PATCH] texgetimage: add missing return on error

2011-10-19 Thread nobled
Missed this back in the arb_robustness branch <6b329b9274b18c50f4177eef7ee087d50ebc1525>. --- src/mesa/main/texgetimage.c |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/src/mesa/main/texgetimage.c b/src/mesa/main/texgetimage.c index f911886..e6edb45 100644 --- a/src/mesa/