Re: [Mesa-dev] [PATCH 2/2] mesa: fix unpack_ARGB1555_REV()

2011-12-01 Thread Michel Dänzer
On Mit, 2011-11-30 at 20:36 -0700, Brian Paul wrote: We weren't doing the necessary byte swap. I just stumbled over this as well. --- src/mesa/main/format_unpack.c |9 + 1 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/mesa/main/format_unpack.c

[Mesa-dev] [Bug 43404] Git head fails to build-No rule to make target 'default' in src/gallium/drivers/failover

2011-12-01 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=43404 José Fonseca jfons...@vmware.com changed: What|Removed |Added Status|NEW |RESOLVED

[Mesa-dev] [PATCH 0/6] patches to increase the brw eu instruction store size dynamically

2011-12-01 Thread Yuanhan Liu
Actually the first 5 patches are all prepare work for patch 6. I checked those patches will all intel oglc testcases, and found no regressions. What's better, it fixed something. Yuanhan Liu (6): i965: let all the brw_OPCODE functions return an instruction index instead i965: remove

[Mesa-dev] [PATCH 1/6] i965: let all the brw_OPCODE functions return an instruction index instead

2011-12-01 Thread Yuanhan Liu
Let all the brw_OPCODE functions return an instruction index instead, and use brw_insn_of(p, index) macro to reference the instruction stored at p-store[]. This is a prepare work of let us increase the instruction store size dynamically by reralloc. Signed-off-by: Yuanhan Liu

[Mesa-dev] [PATCH 2/6] i965: remove the second unused parameter of gen6_CONT

2011-12-01 Thread Yuanhan Liu
Signed-off-by: Yuanhan Liu yuanhan@linux.intel.com --- src/mesa/drivers/dri/i965/brw_eu.h |2 +- src/mesa/drivers/dri/i965/brw_eu_emit.c |2 +- src/mesa/drivers/dri/i965/brw_fs_emit.cpp |2 +- src/mesa/drivers/dri/i965/brw_vec4_emit.cpp |2 +-

[Mesa-dev] [PATCH 3/6] i965: let all the while loop stack to store an instruction index instead

2011-12-01 Thread Yuanhan Liu
Let all the while loop stack just store the instruction index. This is somehow more flexible than store the instruction memory address. This is a prepare work of let us increase the instruction store size dynamically by reralloc. Signed-off-by: Yuanhan Liu yuanhan@linux.intel.com ---

[Mesa-dev] [PATCH 4/6] i965: let if_stack just store the instruction index

2011-12-01 Thread Yuanhan Liu
Let if_stack just store the instruction pointer(an index). This is somehow more flexible than store the instruction memory address. This is a prepare work of let us increase the instruction store size dynamically by reralloc. Signed-off-by: Yuanhan Liu yuanhan@linux.intel.com ---

[Mesa-dev] [PATCH 5/6] i965: let brw_lan_fwd_jump() get the jmp_insn by the instruction index

2011-12-01 Thread Yuanhan Liu
This is a prepare work of let us increase the instruction store size dynamically by reralloc. Signed-off-by: Yuanhan Liu yuanhan@linux.intel.com --- src/mesa/drivers/dri/i965/brw_eu.h |3 +-- src/mesa/drivers/dri/i965/brw_eu_emit.c |4 ++--

[Mesa-dev] [PATCH 6/6] i965: increase the brw eu instruction store size dynamically

2011-12-01 Thread Yuanhan Liu
Here is the final patch to increase the brw eu instruction store size dynamically instead of just allocating it statically with a constant limit. This would fix something like 'GL_MAX_PROGRAM_INSTRUCTIONS_ARB was 16384 while the driver would limit it to 1'. Signed-off-by: Yuanhan Liu

Re: [Mesa-dev] [PATCH 2/2] mesa: fix unpack_ARGB1555_REV()

2011-12-01 Thread Brian Paul
On 12/01/2011 02:42 AM, Michel Dänzer wrote: On Mit, 2011-11-30 at 20:36 -0700, Brian Paul wrote: We weren't doing the necessary byte swap. I just stumbled over this as well. --- src/mesa/main/format_unpack.c |9 + 1 files changed, 5 insertions(+), 4 deletions(-) diff --git

Re: [Mesa-dev] [PATCH] u_vbuf: Silence uninitialized variable warnings.

2011-12-01 Thread Brian Paul
On 11/30/2011 04:35 PM, Vinson Lee wrote: Fixes these GCC warnings. u_vbuf.c: In function ‘u_vbuf_draw_begin’: u_vbuf.c:839:20: warning: ‘max_index’ may be used uninitialized in this function [-Wuninitialized] u_vbuf.c:838:20: warning: ‘min_index’ may be used uninitialized in this function

Re: [Mesa-dev] [PATCH 2/2] mesa: fix unpack_ARGB1555_REV()

2011-12-01 Thread Michel Dänzer
On Don, 2011-12-01 at 07:28 -0700, Brian Paul wrote: On 12/01/2011 02:42 AM, Michel Dänzer wrote: On Mit, 2011-11-30 at 20:36 -0700, Brian Paul wrote: diff --git a/src/mesa/main/format_unpack.c b/src/mesa/main/format_unpack.c index 4b4ee6b..fc0db34 100644 ---

Re: [Mesa-dev] Use of nested functions in nouveau_array.c

2011-12-01 Thread İsmail Dönmez
Hi; On Wed, Nov 9, 2011 at 8:08 PM, İsmail Dönmez ism...@namtrac.org wrote: Another thing to notice that nested functions require executable stack. This is also another reason to get rid of them. On Wed, Nov 9, 2011 at 3:11 PM, İsmail Dönmez ism...@namtrac.org wrote: Hi; nouveau_array.c

Re: [Mesa-dev] [PATCH 2/2] mesa: fix unpack_ARGB1555_REV()

2011-12-01 Thread Brian Paul
On 12/01/2011 07:35 AM, Michel Dänzer wrote: On Don, 2011-12-01 at 07:28 -0700, Brian Paul wrote: On 12/01/2011 02:42 AM, Michel Dänzer wrote: On Mit, 2011-11-30 at 20:36 -0700, Brian Paul wrote: diff --git a/src/mesa/main/format_unpack.c b/src/mesa/main/format_unpack.c index

Re: [Mesa-dev] Use of nested functions in nouveau_array.c

2011-12-01 Thread Brian Paul
On 12/01/2011 07:36 AM, İsmail Dönmez wrote: Hi; On Wed, Nov 9, 2011 at 8:08 PM, İsmail Dönmez ism...@namtrac.org mailto:ism...@namtrac.org wrote: Another thing to notice that nested functions require executable stack. This is also another reason to get rid of them. On Wed, Nov 9,

Re: [Mesa-dev] Use of nested functions in nouveau_array.c

2011-12-01 Thread İsmail Dönmez
Hi; On Thu, Dec 1, 2011 at 3:46 PM, Brian Paul bri...@vmware.com wrote: On 12/01/2011 07:36 AM, İsmail Dönmez wrote: Hi; On Wed, Nov 9, 2011 at 8:08 PM, İsmail Dönmez ism...@namtrac.org mailto:ism...@namtrac.org wrote: Another thing to notice that nested functions require executable

Re: [Mesa-dev] [PATCH] mesa: fix unpack_ARGB1555_REV()

2011-12-01 Thread Michel Dänzer
On Don, 2011-12-01 at 07:44 -0700, Brian Paul wrote: We weren't doing the necessary byte swap. v2: use same arithmetic as unpack_ARGB1555() to be consistent. --- src/mesa/main/format_unpack.c |9 + 1 files changed, 5 insertions(+), 4 deletions(-) diff --git

[Mesa-dev] UBO support update, working on some demo

2011-12-01 Thread Vincent Lejeune
Hi, Here are an updated set of patches adding UBO support to Mesa. It still work in progress, however I got some demo working on gallium (namely blinking-teapot submitted to mesa-demos via another patch). However not every gallium works, nouveau and softpipe does but llvmpipe crashes (seems not

[Mesa-dev] [PATCH 1/9] glapi: Add Uniform Buffer Object API

2011-12-01 Thread Vincent Lejeune
v2: Fix a typo spotted by Eric Anholt. --- src/mapi/glapi/gen/ARB_Uniform_Buffer_Object.xml | 115 ++ src/mapi/glapi/gen/Makefile |1 + src/mapi/glapi/gen/gl_API.xml|2 + 3 files changed, 118 insertions(+), 0 deletions(-)

[Mesa-dev] [PATCH 3/9] mesa : advertise GL_ARB_Uniform_Buffer_Object extension

2011-12-01 Thread Vincent Lejeune
--- src/glsl/glsl_parser_extras.cpp |1 + src/glsl/glsl_parser_extras.h |2 ++ src/mesa/main/mfeatures.h |1 + 3 files changed, 4 insertions(+), 0 deletions(-) diff --git a/src/glsl/glsl_parser_extras.cpp b/src/glsl/glsl_parser_extras.cpp index 0b4ccac..71b4c5c 100644 ---

[Mesa-dev] [PATCH 4/9] mesa: Uniform Buffer Objects data structures

2011-12-01 Thread Vincent Lejeune
v2:Big cleanup of data structures used v3:Data structures moved to mtypes.h --- src/mesa/main/config.h|4 ++ src/mesa/main/mtypes.h| 109 + src/mesa/main/shaderobj.c | 25 - src/mesa/program/prog_parameter.h

[Mesa-dev] [PATCH 5/9] glsl: change IR to add UBO information

2011-12-01 Thread Vincent Lejeune
--- src/glsl/ir.cpp|1 + src/glsl/ir.h |6 ++ src/glsl/ir_clone.cpp |1 + src/glsl/opt_dead_code.cpp |6 ++ 4 files changed, 14 insertions(+), 0 deletions(-) diff --git a/src/glsl/ir.cpp b/src/glsl/ir.cpp index a5eca5a..bf11e4f 100644 ---

[Mesa-dev] [PATCH 6/9] glsl: parser UBO support

2011-12-01 Thread Vincent Lejeune
v2:Instance name an UBO array are not supported. The parser will now return an error message if they are met. --- src/glsl/ast.h | 23 +++ src/glsl/ast_to_hir.cpp | 75 +- src/glsl/glsl_lexer.ll |3 +- src/glsl/glsl_parser.yy | 333

[Mesa-dev] [PATCH 7/9] glsl : Linker support for UBO

2011-12-01 Thread Vincent Lejeune
v2 : - Fix format issue thank to Brian Paul comments. - UBOs are now sent to program correctly. --- src/glsl/link_uniforms.cpp |2 +- src/glsl/linker.cpp| 310 +++- 2 files changed, 309 insertions(+), 3 deletions(-) diff --git

[Mesa-dev] [PATCH 8/9] mesa: add Uniform Buffer Object API implementation

2011-12-01 Thread Vincent Lejeune
v2:Move implementation to ubo.cpp and ubo.h as suggested by Brian Paul --- src/mesa/main/api_exec.c |2 + src/mesa/main/bufferobj.c| 11 + src/mesa/main/ubo.c | 268 ++ src/mesa/main/ubo.cpp

[Mesa-dev] [PATCH 9/9] gallium : st_glsl_to_tgsi handles UBO

2011-12-01 Thread Vincent Lejeune
--- src/mesa/main/ubo.c| 268 src/mesa/state_tracker/st_atom_constbuf.c |8 + src/mesa/state_tracker/st_extensions.c |4 + src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 92 +- 4 files changed, 59 insertions(+), 313

Re: [Mesa-dev] [PATCH] st/mesa: only resolve is number of samples is 1

2011-12-01 Thread Roland Scheidegger
Am 30.11.2011 21:43, schrieb Jose Fonseca: - Original Message - On 11/30/2011 09:10 PM, Dave Airlie wrote: From: Dave Airlie airl...@redhat.com This fixes the firefox crash but I've no idea if its correct. I don't think it is. Visual.samples is the value passed to

[Mesa-dev] [Bug 43404] Git head fails to build-No rule to make target 'default' in src/gallium/drivers/failover

2011-12-01 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=43404 --- Comment #4 from idun...@lavabit.com 2011-12-01 08:18:11 PST --- OK. Well, now to get autogen.sh to work--I don't have an intel card, but autogen.sh needs libdrm_intel updated anyhow. -- Configure bugmail:

[Mesa-dev] [Bug 43404] Git head fails to build-No rule to make target 'default' in src/gallium/drivers/failover

2011-12-01 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=43404 --- Comment #5 from José Fonseca jfons...@vmware.com 2011-12-01 08:22:28 PST --- ./autogen.sh invokes ./configure automatically. You can pass the same arguments as configure has, and tell it not to build intel drivers. -- Configure bugmail:

Re: [Mesa-dev] [PATCH 5/9] glsl: change IR to add UBO information

2011-12-01 Thread Matt Turner
On Thu, Dec 1, 2011 at 3:35 PM, Vincent Lejeune v...@ovi.com wrote: ---  src/glsl/ir.cpp            |    1 +  src/glsl/ir.h              |    6 ++  src/glsl/ir_clone.cpp      |    1 +  src/glsl/opt_dead_code.cpp |    6 ++  4 files changed, 14 insertions(+), 0 deletions(-) diff

[Mesa-dev] [PATCH 1/2] r600g: Make tiling alignment restrictions match the DDX

2011-12-01 Thread Simon Farnsworth
It's unclear exactly what the alignment requirements are for Radeon tiled surfaces, but they differ between the DDX and Mesa. Make Mesa match the DDX. Signed-off-by: Simon Farnsworth simon.farnswo...@onelan.co.uk --- This basically copies across the DDX versions of the restrictions. They differ,

[Mesa-dev] [PATCH 2/2] r600g: Set tile_type correctly when textures are created

2011-12-01 Thread Simon Farnsworth
From discussion on IRC, tile_type should be 1 for depth or stencil textures. On Evergreen, it should also be 1 for some color buffers, but that's handled in the evergreen_cb function when required. Signed-off-by: Simon Farnsworth simon.farnswo...@onelan.co.uk --- Doesn't fix my tiled scanout

[Mesa-dev] [PATCH 0/2] update tnl module to the recent VERT_ATTRIB* changes.

2011-12-01 Thread Mathias Fröhlich
These two patches should fix: https://bugs.freedesktop.org/show_bug.cgi?id=3D43353 Please review. Mathias Fröhlich (2): mesa: Extend BITSET64_*_RANGE to work on arbitrary ranges. mesa: Renumber the tnl attributes to match VERT_ATTRIB*. src/mesa/main/bitset.h | 21 ++--

[Mesa-dev] [PATCH 1/2] mesa: Extend BITSET64_*_RANGE to work on arbitrary ranges.

2011-12-01 Thread Mathias Fröhlich
The BITSET64_{TEST,SET,CLEAR}_RANGE macros only work on ranges wither in the lower 32 or in the upper 32 bits of the bitset. This change extends these macros to work on arbitrary ranges possibly crossing the bitset word boundary. Signed-off-by: Mathias Froehlich mathias.froehl...@web.de ---

[Mesa-dev] [PATCH 2/2] mesa: Renumber the tnl attributes to match VERT_ATTRIB*.

2011-12-01 Thread Mathias Fröhlich
Also renumber the tnl modules vertex attributes to match the renumbered VERT_ATTRIB_* values. This should fix https://bugs.freedesktop.org/show_bug.cgi?id=43353 Signed-off-by: Mathias Froehlich mathias.froehl...@web.de --- src/mesa/tnl/t_context.h | 58

[Mesa-dev] [PATCH] swrast: Fix signed/unsigned problems with negative strides.

2011-12-01 Thread Mathias Fröhlich
Hi, The attached patch fixes a core dump in glReadPixels with traditional swrast. The problem looks pretty much the same like the one the VTK guy Kevin H. Hobbs reports. At least his backtrace is mostly the same. Please review. Thanks Mathias From 92eaecb0f471d6705121ca346b43e3709989847f Mon

Re: [Mesa-dev] [PATCH] swrast: Fix signed/unsigned problems with negative strides.

2011-12-01 Thread Brian Paul
On 12/01/2011 01:14 PM, Mathias Fröhlich wrote: Hi, The attached patch fixes a core dump in glReadPixels with traditional swrast. The problem looks pretty much the same like the one the VTK guy Kevin H. Hobbs reports. At least his backtrace is mostly the same. Please review. Thanks Mathias

Re: [Mesa-dev] [PATCH 0/2] update tnl module to the recent VERT_ATTRIB* changes.

2011-12-01 Thread Brian Paul
On 12/01/2011 01:03 PM, Mathias Fröhlich wrote: These two patches should fix: https://bugs.freedesktop.org/show_bug.cgi?id=3D43353 Please review. Mathias Fröhlich (2): mesa: Extend BITSET64_*_RANGE to work on arbitrary ranges. mesa: Renumber the tnl attributes to match VERT_ATTRIB*.

Re: [Mesa-dev] [PATCH 2/2] Add depth cube map support to mesa swrast

2011-12-01 Thread Anuj Phogat
On Thu 01 Dec 2011 06:56:09 AM PST, Brian Paul wrote: On 11/30/2011 12:39 PM, Anuj Phogat wrote: From: Anuj Phogatanuj.pho...@gmail.com I made the suggested changes to swrast/s_texfilter.c (see the patch listed below). Now it render polygons without any texture (black) in depth-cube-map test

[Mesa-dev] [PATCH 1/6] vl: Add missing mpeg fields to pipe_mpeg12_picture_desc

2011-12-01 Thread Maarten Lankhorst
Signed-off-by: Maarten Lankhorst m.b.lankho...@gmail.com --- src/gallium/include/pipe/p_video_state.h |3 +++ src/gallium/state_trackers/vdpau/decode.c |3 +++ 2 files changed, 6 insertions(+), 0 deletions(-) diff --git a/src/gallium/include/pipe/p_video_state.h

[Mesa-dev] [PATCH 2/6] vl: Get rid of video_buffer.sampler_view_components

2011-12-01 Thread Maarten Lankhorst
No point in having it when just having sampler_view_planes is good enough. :-) Signed-off-by: Maarten Lankhorst m.b.lankho...@gmail.com --- src/gallium/auxiliary/vl/vl_compositor.c| 36 ++- src/gallium/auxiliary/vl/vl_compositor.h|2 +-

[Mesa-dev] [PATCH 3/6] nvc0: Add support for autobinding

2011-12-01 Thread Maarten Lankhorst
Signed-off-by: Maarten Lankhorst m.b.lankho...@gmail.com --- src/gallium/drivers/nvc0/nvc0_winsys.h | 19 --- 1 files changed, 12 insertions(+), 7 deletions(-) diff --git a/src/gallium/drivers/nvc0/nvc0_winsys.h b/src/gallium/drivers/nvc0/nvc0_winsys.h index 0fcf994..dd4c887

[Mesa-dev] [PATCH 4/6] nvc0: Add NVC0_RESOURCE_FLAG_VIDEO

2011-12-01 Thread Maarten Lankhorst
Video buffers require a specific tiling mode. Signed-off-by: Maarten Lankhorst m.b.lankho...@gmail.com --- src/gallium/drivers/nvc0/nvc0_miptree.c |2 ++ src/gallium/drivers/nvc0/nvc0_resource.h |1 + 2 files changed, 3 insertions(+), 0 deletions(-) diff --git

[Mesa-dev] [PATCH 5/6] vl: Remove most members of pipe_video_decoder

2011-12-01 Thread Maarten Lankhorst
create_buffer, destroy_buffer and set_buffer are a curiosity of vl_mpeg12_decoder and shouldn't be part of the api. set_quant_matrix and set_reference_frames shouldn't be separate calls, but part of picparm, which is a requirement for h264 to work. set_decode_target and set_picture_parameters

[Mesa-dev] [PATCH 6/6] vl: Add support for h264

2011-12-01 Thread Maarten Lankhorst
And the reason why I needed quant/reference_frames calls gone.. Signed-off-by: Maarten Lankhorst m.b.lankho...@gmail.com --- src/gallium/include/pipe/p_video_state.h | 47 + src/gallium/state_trackers/vdpau/decode.c | 63 + 2 files changed,

[Mesa-dev] [PATCH 2/6] mesa: fix potential mem leak in generate_mipmap_compressed()

2011-12-01 Thread Brian Paul
Fixes a coverity warning. --- src/mesa/main/mipmap.c |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/src/mesa/main/mipmap.c b/src/mesa/main/mipmap.c index c621800..fd6e582 100644 --- a/src/mesa/main/mipmap.c +++ b/src/mesa/main/mipmap.c @@ -2048,6 +2048,7 @@

[Mesa-dev] [PATCH 3/6] mesa: move _mesa_error() call in compressedteximage()

2011-12-01 Thread Brian Paul
We shouldn't call _mesa_error() if the target is a proxy texture. Errors are handled later in the function. Fixes a Coverity warning. --- src/mesa/main/teximage.c |9 ++--- 1 files changed, 2 insertions(+), 7 deletions(-) diff --git a/src/mesa/main/teximage.c b/src/mesa/main/teximage.c

[Mesa-dev] [PATCH 5/6] mesa: remove unreachable code in _mesa_unpack_color_span_ubyte()

2011-12-01 Thread Brian Paul
We checked if srcType == GL_UNSIGNED_BYTE earlier so there was no way to reach this code. This was left-over code from the GLchan removal work. --- src/mesa/main/pack.c | 64 -- 1 files changed, 0 insertions(+), 64 deletions(-) diff --git

[Mesa-dev] [PATCH 6/6] mesa: add casts to fix unpack_SIGNED_GR1616()

2011-12-01 Thread Brian Paul
We were passing unsigned values to the macro before. --- src/mesa/main/format_unpack.c |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mesa/main/format_unpack.c b/src/mesa/main/format_unpack.c index 26f9243..d8fa0cb 100644 --- a/src/mesa/main/format_unpack.c +++

[Mesa-dev] [PATCH] mesa: Reject glDrawPixels(integer format).

2011-12-01 Thread Eric Anholt
When folding GL_EXT_texture_integer into the core, a new (and very sensible) restriction was added. --- src/mesa/main/drawpix.c | 18 ++ 1 files changed, 18 insertions(+), 0 deletions(-) diff --git a/src/mesa/main/drawpix.c b/src/mesa/main/drawpix.c index 412cc15..c9e714b

[Mesa-dev] [PATCH 2/2] mesa: Fix assertions for block size handling in glCompressedTexSubImage2D.

2011-12-01 Thread Eric Anholt
Anything of less than (bw, bh) size is possible when you consider rectangular textures, and this code is (now) safe for those. Even for power-of-two textures, width could be 4 for FXT1 while not being aligned to block size. Fixes piglit compressedteximage GL_COMPRESSED_RGB_FXT1_3DFX ---

[Mesa-dev] [PATCH 1/2] mesa: Fix glCompressedTexSubImage (and non-Sub) for height == 2 or 1.

2011-12-01 Thread Eric Anholt
Generally this code works with width and height aligned to compressed blocks, but but at the 2x2 and 1x1 levels of a square texture (or height bh in general), we were skipping uploading our single row of blocks. Fixes piglit compressedteximage GL_COMPRESSED_RGBA_S3TC_DXT5_EXT. ---

Re: [Mesa-dev] [PATCH 2/6] mesa: fix potential mem leak in generate_mipmap_compressed()

2011-12-01 Thread Vinson Lee
On Dec 1, 2011, at 4:45 PM, Brian Paul wrote: Fixes a coverity warning. --- src/mesa/main/mipmap.c |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/src/mesa/main/mipmap.c b/src/mesa/main/mipmap.c index c621800..fd6e582 100644 --- a/src/mesa/main/mipmap.c +++

[Mesa-dev] [PATCH] mesa: Use VERT_{ATTRIB, BIT}* for ARB input validation.

2011-12-01 Thread Mathias Fröhlich
Hi, Attached is a change to the ARB program parser that should fix https://bugs.freedesktop.org/show_bug.cgi?id=43407 Please review. Thanks Mathias From 4a3d9f06651c5cd51edcb394fa598153e5fea2f3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mathias=20Fr=C3=B6hlich?= mathias.froehl...@web.de Date: