Re: [Mesa-dev] [PATCH] gallium/u_blitter: Remove the overlapped blit assert from util_blitter_blit_generic().

2012-12-14 Thread Michel Dänzer
On Fre, 2012-12-14 at 06:04 +0100, Henri Verbeet wrote: > This is used by st_BlitFramebuffer() / r600_blit(), and ARB_fbo allows > overlapped blits, even though the result is undefined. No piglit regressions > on r600g / CYPRESS. Missing Signed-off-by? Reviewed-by: Michel Dänzer -- Earthling

Re: [Mesa-dev] [PATCH] gallium/u_blitter: Remove the overlapped blit assert from util_blitter_blit_generic().

2012-12-14 Thread Matt Turner
On Fri, Dec 14, 2012 at 12:27 AM, Michel Dänzer wrote: > On Fre, 2012-12-14 at 06:04 +0100, Henri Verbeet wrote: >> This is used by st_BlitFramebuffer() / r600_blit(), and ARB_fbo allows >> overlapped blits, even though the result is undefined. No piglit regressions >> on r600g / CYPRESS. > > Miss

Re: [Mesa-dev] [PATCH] gallium/u_blitter: Remove the overlapped blit assert from util_blitter_blit_generic().

2012-12-14 Thread Dave Airlie
On Fri, Dec 14, 2012 at 7:06 PM, Matt Turner wrote: > On Fri, Dec 14, 2012 at 12:27 AM, Michel Dänzer wrote: >> On Fre, 2012-12-14 at 06:04 +0100, Henri Verbeet wrote: >>> This is used by st_BlitFramebuffer() / r600_blit(), and ARB_fbo allows >>> overlapped blits, even though the result is undefi

Re: [Mesa-dev] [PATCH] gallium/u_blitter: Remove the overlapped blit assert from util_blitter_blit_generic().

2012-12-14 Thread Marek Olšák
Reviewed-by: Marek Olšák Marek On Fri, Dec 14, 2012 at 6:04 AM, Henri Verbeet wrote: > This is used by st_BlitFramebuffer() / r600_blit(), and ARB_fbo allows > overlapped blits, even though the result is undefined. No piglit regressions > on r600g / CYPRESS. > --- > src/gallium/auxiliary/util/

[Mesa-dev] [PATCH] Backport cross-compilation fixes to 9.0

2012-12-14 Thread Ross Burton
The cross-compilation fixes to the GLSL builtin compiler in master are incredibly useful for those of us who cross-compile, and cherry-pick with minimal conflicts (one chunk in configure.ac) to the 9.0 branch. Ross ___ mesa-dev mailing list mesa-dev@lis

[Mesa-dev] [PATCH 1/2] build: Don't cross-compile GLSL builtin compiler

2012-12-14 Thread Ross Burton
From: Thierry Reding The builtin_compiler binary is used during the build process to generate code for the builtin GLSL functions. Since this binary needs to be run on the build host, it must not be cross-compiled. This patch fixes the build system to compile a second version of the source files

[Mesa-dev] [PATCH 2/2] glsl: Fix builtin_compiler build by -I $(top_srcdir)/include.

2012-12-14 Thread Ross Burton
From: Johannes Obermayr Reviewed-by: Kenneth Graunke Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=56664 --- src/glsl/builtin_compiler/Makefile.am |1 + 1 file changed, 1 insertion(+) diff --git a/src/glsl/builtin_compiler/Makefile.am b/src/glsl/builtin_compiler/Makefile.am index

[Mesa-dev] [RFC] intel: add support for EGL_KHR_gl_image

2012-12-14 Thread Abdiel Janulgue
This patch set adds support for KHR_gl_texture_2D_image, KHR_gl_texture_cubemap_image and KHR_gl_texture_3D_image for Gen 4 -> Gen7 HW. The extension enables us to be a bit more conformant to the spec in Android at least. I've tested it on SandyBridge and IvyBridge. The approach is to export a

[Mesa-dev] [PATCH 1/6] dri2: Create image from texture

2012-12-14 Thread Abdiel Janulgue
Add create image from texture extension. Signed-off-by: Abdiel Janulgue --- include/GL/internal/dri_interface.h | 12 + src/egl/drivers/dri2/egl_dri2.c | 83 +++ 2 files changed, 95 insertions(+) diff --git a/include/GL/internal/dri_interface.h b/inc

[Mesa-dev] [PATCH 2/6] intel: create a miptree for a region based on an offset, size, and level.

2012-12-14 Thread Abdiel Janulgue
Add intel_miptree_create_for_offset which adds support for creating a single- level miptree based on the existing offsets and dimensions of another mip-tree level. Use this function as well in intel_miptree_create_for_region, but for the whole region. Signed-off-by: Abdiel Janulgue --- src/mesa/

[Mesa-dev] [PATCH 3/6] intel: add new miptree helper functions for linear copying of a miptree and calculating x and y offsets of a miptree level within a tiled region.

2012-12-14 Thread Abdiel Janulgue
Signed-off-by: Abdiel Janulgue --- src/mesa/drivers/dri/intel/intel_mipmap_tree.c | 31 src/mesa/drivers/dri/intel/intel_mipmap_tree.h | 10 2 files changed, 41 insertions(+) diff --git a/src/mesa/drivers/dri/intel/intel_mipmap_tree.c b/src/mesa/drivers/dri

[Mesa-dev] [PATCH 4/6] i965: Account for offsets when emitting SURFACE_STATE.

2012-12-14 Thread Abdiel Janulgue
If the offsets are present, this lets us specify a particular level and slice in a shared region using the base level of an exported mip-map tree. Signed-off-by: Abdiel Janulgue --- src/mesa/drivers/dri/i965/brw_wm_surface_state.c | 12 +++- src/mesa/drivers/dri/i965/gen7_wm_surface_s

[Mesa-dev] [PATCH 5/6] intel: implement create image from texture

2012-12-14 Thread Abdiel Janulgue
Save miptree level info to DRIImage, taking offsets into consideration. For <= gen4 hw which doesn't support non-tile aligned offset, re-create the mipmap tree internally before exporting the updated offsets to avoid alignment problems. Signed-off-by: Abdiel Janulgue --- src/mesa/drivers/dri/int

[Mesa-dev] [PATCH 6/6] intel: Create a miptree using offsets in intel_set_texture_image_region

2012-12-14 Thread Abdiel Janulgue
When binding a region to a texture image, re-create the miptree base-level considering the offset and dimension information exported by DRIImage. Signed-off-by: Abdiel Janulgue --- src/mesa/drivers/dri/intel/intel_tex_image.c | 27 -- 1 file changed, 21 insertions(+), 6

Re: [Mesa-dev] [RFC] intel: add support for EGL_KHR_gl_image

2012-12-14 Thread Abdiel Janulgue
On Friday, December 14, 2012 03:28:12 PM Abdiel Janulgue wrote: > This patch set adds support for KHR_gl_texture_2D_image, > KHR_gl_texture_cubemap_image and KHR_gl_texture_3D_image for Gen 4 -> Gen7 > HW. The extension enables us to be a bit more conformant to the spec in > Android at least. I've

Re: [Mesa-dev] [PATCH] r600g: tgsi to llvm emits stream output intrinsics.

2012-12-14 Thread Aaron Watry
diff --git a/src/gallium/drivers/r600/r600_llvm.c b/src/gallium/drivers/r600/r600_llvm.c index 8f1ed26..14c0205 100644 --- a/src/gallium/drivers/r600/r600_llvm.c +++ b/src/gallium/drivers/r600/r600_llvm.c @@ -229,11 +229,32 @@ static void llvm_emit_epilogue(struct lp_build_tgsi_context * bld_bas

Re: [Mesa-dev] [PATCH] gallium/u_blitter: Remove the overlapped blit assert from util_blitter_blit_generic().

2012-12-14 Thread Henri Verbeet
On 14 December 2012 09:27, Michel Dänzer wrote: > On Fre, 2012-12-14 at 06:04 +0100, Henri Verbeet wrote: >> This is used by st_BlitFramebuffer() / r600_blit(), and ARB_fbo allows >> overlapped blits, even though the result is undefined. No piglit regressions >> on r600g / CYPRESS. > > Missing Sig

Re: [Mesa-dev] Mesa master branch: forced update

2012-12-14 Thread Chia-I Wu
Hi Kristian, On Wed, Jul 11, 2012 at 7:15 AM, Kristian Høgsberg wrote: [snip] > Chia-I hasn't been active for a long time and the suddenly pushes a > forced update of the repo, I don't think anything was compromised or > any history lost. The freedesktop.org account has been disabled until > we

Re: [Mesa-dev] Mesa master branch: forced update

2012-12-14 Thread Kristian Høgsberg
Yeah, I got your email, sorry about that. I think the best way to go is to open an fd.o site-wrangler request, put your username in there and ask for the account to be reopened. Kristian On Fri, Dec 14, 2012 at 11:14 AM, Chia-I Wu wrote: > Hi Kristian, > > On Wed, Jul 11, 2012 at 7:15 AM, Krist

[Mesa-dev] [PATCH 2/2] softpipe: fix up FS variant unbinding / deletion

2012-12-14 Thread Brian Paul
The old call to tgsi_exec_machine_bind_shader() in softpipe_delete_fs_state() was never called since the shader's original tokens are never passed to the tgsi interpreter (only shader _variant_ tokens are). Now, unbind the variant's tokens from the tgsi interpreter when we free the variant. This

[Mesa-dev] [PATCH 1/2] softpipe: fix unreliable FS variant binding bug

2012-12-14 Thread Brian Paul
In exec_prepare() we were comparing pointers to see if the fragment shader variant had changed before calling tgsi_exec_machine_bind_shader(). This didn't work reliably when there was a lot of shader token malloc/ freeing going on because the memory might get reused. Instead, bind the shader varian

Re: [Mesa-dev] [PATCH] android: build fix for libmesa_glsl_utils

2012-12-14 Thread Chad Versace
On 12/13/2012 12:56 AM, Tapani Pälli wrote: > hash_table.c compilation requires ralloc.h include path > > Signed-off-by: Tapani Pälli > --- > src/mesa/Android.libmesa_glsl_utils.mk | 4 Thanks. Fix is committed. ___ mesa-dev mailing list mesa-dev

Re: [Mesa-dev] [PATCH 7/7] i965/fs: Add empirically-determined instruction latencies for gen7.

2012-12-14 Thread Eric Anholt
Kenneth Graunke writes: > On 12/07/2012 02:58 PM, Eric Anholt wrote: >> + case SHADER_OPCODE_TEX: >> + case SHADER_OPCODE_TXD: >> + case SHADER_OPCODE_TXF: >> + case SHADER_OPCODE_TXL: >> + case SHADER_OPCODE_TXS: >> + /* 18 cycles: >> + * mov(8) g115<1>F 0F

Re: [Mesa-dev] [RFC] intel: add support for EGL_KHR_gl_image

2012-12-14 Thread Eric Anholt
Abdiel Janulgue writes: > This patch set adds support for KHR_gl_texture_2D_image, > KHR_gl_texture_cubemap_image and KHR_gl_texture_3D_image for Gen 4 -> > Gen7 HW. The extension enables us to be a bit more conformant to the > spec in Android at least. I've tested it on SandyBridge and IvyBridge

[Mesa-dev] [PATCH] gallivm: fix texel fetch for array textures (2)

2012-12-14 Thread sroland
From: Roland Scheidegger a460aea3f14222af46f88d1bc686f82180b8a872 wasn't entirely correct, since all coords are already ints hence need to skip the iround. Passes piglit texelFetch with sampler1DArray/sampler2DArray. --- src/gallium/auxiliary/gallivm/lp_bld_sample_soa.c |5 +++-- 1 file chan

[Mesa-dev] [PATCH] mesa: add bounds checking for uniform array access

2012-12-14 Thread Frank Henigman
No piglet regressions and now passes glsl-uniform-out-of-bounds-2. validate_uniform_parameters now checks that the array index is valid. This means if an index is out of bounds, glGetUniform* now fails with GL_INVALID_OPERATION, as it should. _mesa_uniform and _mesa_uniform_matrix also call vali

Re: [Mesa-dev] [PATCH] gallivm: fix texel fetch for array textures (2)

2012-12-14 Thread Dave Airlie
On Sat, Dec 15, 2012 at 6:25 AM, wrote: > From: Roland Scheidegger > > a460aea3f14222af46f88d1bc686f82180b8a872 wasn't entirely correct, > since all coords are already ints hence need to skip the iround. > Passes piglit texelFetch with sampler1DArray/sampler2DArray. > --- > src/gallium/auxiliar

[Mesa-dev] [PATCH 0/5] GLES3 transform feedback fixes.

2012-12-14 Thread Paul Berry
Here's a series of loosely-related fixes to transform feedback behaviour for GLES3. Patches 1-4 implement a difference between GLES3 and desktop GL: in GLES3, transform feedback can only be used with DrawArrays and DrawArraysInstanced, and it is supposed to generate an error if there is not enough

[Mesa-dev] [PATCH 1/5] mesa: Change args to vbo_count_tessellated_primitives.

2012-12-14 Thread Paul Berry
No functional change--this simply paves the way to allow futures patches to call vbo_count_tessellated_primitives() during error checking, before the _mesa_prim struct has been constructed. This will be needed for GLES3, which requires draw calls to fail if there is not enough space available in t

[Mesa-dev] [PATCH 2/5] mesa: refactor _mesa_compute_max_transform_feedback_vertices from i965.

2012-12-14 Thread Paul Berry
Previously, the i965 driver contained code to compute the maximum number of vertices that could be written without overflowing any transform feedback buffers. This code wasn't driver-specific, and for GLES3 support we're going to need to use it in core mesa. So this patch moves the code into a co

[Mesa-dev] [PATCH 3/5] mesa/gles3: Generate error on DrawElements* calls if transform feedback active.

2012-12-14 Thread Paul Berry
In GLES3, only glDrawArrays() and glDrawArraysInstanced() calls are allowed when transform feedback is active. --- src/mesa/main/api_validate.c | 45 1 file changed, 45 insertions(+) diff --git a/src/mesa/main/api_validate.c b/src/mesa/main/api_validat

[Mesa-dev] [PATCH 4/5] mesa/gles3: Generate error on draw call if transform feedback would overflow.

2012-12-14 Thread Paul Berry
In desktop GL, if a draw call would cause transform feedback buffers to overflow, the draw call should succeed, and the extra primitives should simply not be recorded in the transform feedback buffers. In GLES3, however, if a draw call would cause transform feedback buffers to overflow, the draw c

[Mesa-dev] [PATCH 5/5] mesa: Fix GL_TRANSFORM_FEEDBACK_BUFFER_SIZE query when glBindBufferBase used.

2012-12-14 Thread Paul Berry
>From the GL 4.3 spec, section 6.7.1 (Indexed Buffer Object Limits and Binding Queries): To query the starting offset or size of the range of a buffer object binding in an indexed array, call GetInteger64i v with target set to respectively the starting offset or binding size name f

Re: [Mesa-dev] [PATCH] mesa: add bounds checking for uniform array access

2012-12-14 Thread Stéphane Marchesin
On Fri, Dec 14, 2012 at 12:52 PM, Frank Henigman wrote: > No piglet regressions and now passes glsl-uniform-out-of-bounds-2. > > > validate_uniform_parameters now checks that the array index is > valid. This means if an index is out of bounds, glGetUniform* now > fails with GL_INVALID_OPERATION,

Re: [Mesa-dev] [PATCH 1/5] i965/fs: Add a note explaining a detail of register_coalesce_2().

2012-12-14 Thread Kenneth Graunke
On 12/11/2012 01:42 PM, Eric Anholt wrote: --- src/mesa/drivers/dri/i965/brw_fs.cpp | 21 + 1 file changed, 21 insertions(+) diff --git a/src/mesa/drivers/dri/i965/brw_fs.cpp b/src/mesa/drivers/dri/i965/brw_fs.cpp index f428a83..c520364 100644 --- a/src/mesa/drivers/dri

Re: [Mesa-dev] [PATCH 3/8] egl/gbm: Implement EGL_EXT_buffer_age

2012-12-14 Thread Eric Anholt
Kristian Høgsberg writes: > --- > src/egl/drivers/dri2/egl_dri2.h |1 + > src/egl/drivers/dri2/platform_drm.c | 23 +++ > 2 files changed, 24 insertions(+) > > diff --git a/src/egl/drivers/dri2/egl_dri2.h b/src/egl/drivers/dri2/egl_dri2.h > index be359d3..fa2a9f3 10

Re: [Mesa-dev] [PATCH 5/8] egl/wayland: Remove confusing comment about front buffer rendering

2012-12-14 Thread Ian Romanick
On 12/13/2012 09:05 PM, Kristian Høgsberg wrote: At least the way I build, this will cause unused parameter warnings. --- src/egl/drivers/dri2/platform_wayland.c | 12 1 file changed, 12 deletions(-) diff --git a/src/egl/drivers/dri2/platform_wayland.c b/src/egl/drivers/dri2

[Mesa-dev] [PATCH 1/2] mesa: Refactor getting a uniform's name to a helper function

2012-12-14 Thread Ian Romanick
From: Ian Romanick We currently have a bug in this code, and I don't want to fix it in two places. Signed-off-by: Ian Romanick --- src/mesa/main/uniform_query.cpp | 2 +- src/mesa/main/uniforms.c| 12 ++-- src/mesa/main/uniforms.h| 5 + 3 files changed, 16 inserti

[Mesa-dev] [PATCH 2/2] mesa: Array uniform names are supposed to have [0] appended

2012-12-14 Thread Ian Romanick
From: Ian Romanick This is required by OpenGL ES 3.0 and desktop OpenGL 4.2. Previous version were ambiguous. This also matches the behavior of NVIDIA's closed-source driver (version 304.64). Fixed gles3conformance test uniform_buffer_object_getactiveuniform. Several piglit tests expect glGet

[Mesa-dev] [PATCH] i965: Add missing autoconf bits so test_vec4_register_coalesce will build

2012-12-14 Thread Ian Romanick
From: Ian Romanick Signed-off-by: Ian Romanick Cc: Eric Anholt --- src/mesa/drivers/dri/i965/Makefile.am | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/mesa/drivers/dri/i965/Makefile.am b/src/mesa/drivers/dri/i965/Makefile.am index 8e96467..fb4f56c 100644 --- a/src/mesa/drivers/dr

Re: [Mesa-dev] [PATCH 3/5] mesa/gles3: Generate error on DrawElements* calls if transform feedback active.

2012-12-14 Thread Ian Romanick
On 12/14/2012 01:01 PM, Paul Berry wrote: In GLES3, only glDrawArrays() and glDrawArraysInstanced() calls are allowed when transform feedback is active. --- src/mesa/main/api_validate.c | 45 1 file changed, 45 insertions(+) diff --git a/src/mesa/m

Re: [Mesa-dev] [PATCH 4/5] mesa/gles3: Generate error on draw call if transform feedback would overflow.

2012-12-14 Thread Ian Romanick
On 12/14/2012 01:01 PM, Paul Berry wrote: In desktop GL, if a draw call would cause transform feedback buffers to overflow, the draw call should succeed, and the extra primitives should simply not be recorded in the transform feedback buffers. In GLES3, however, if a draw call would cause transf

Re: [Mesa-dev] [PATCH 0/5] GLES3 transform feedback fixes.

2012-12-14 Thread Ian Romanick
On 12/14/2012 01:01 PM, Paul Berry wrote: Here's a series of loosely-related fixes to transform feedback behaviour for GLES3. The series looks good. Other than a couple infinitesimal nits, Reviewed-by: Ian Romanick Patches 1-4 implement a difference between GLES3 and desktop GL: in GLES3,

Re: [Mesa-dev] [PATCH 3/8] egl/gbm: Implement EGL_EXT_buffer_age

2012-12-14 Thread Kristian Høgsberg
On Fri, Dec 14, 2012 at 04:54:32PM -0800, Eric Anholt wrote: > Kristian Høgsberg writes: > > > --- > > src/egl/drivers/dri2/egl_dri2.h |1 + > > src/egl/drivers/dri2/platform_drm.c | 23 +++ > > 2 files changed, 24 insertions(+) > > > > diff --git a/src/egl/drivers/

Re: [Mesa-dev] [PATCH 5/8] egl/wayland: Remove confusing comment about front buffer rendering

2012-12-14 Thread Kristian Høgsberg
On Fri, Dec 14, 2012 at 04:57:07PM -0800, Ian Romanick wrote: > On 12/13/2012 09:05 PM, Kristian Høgsberg wrote: > > At least the way I build, this will cause unused parameter warnings. Oh, right, I'll add the (void) driDrawable back in. Kristian > >--- > > src/egl/drivers/dri2/platform_waylan

[Mesa-dev] [PATCH 2/2] i965: Move BRW_MAX_GRF and similar defines to brw_reg.h.

2012-12-14 Thread Kenneth Graunke
These don't really belong in brw_structs.h. --- src/mesa/drivers/dri/i965/brw_reg.h | 17 + src/mesa/drivers/dri/i965/brw_structs.h | 18 -- 2 files changed, 17 insertions(+), 18 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_reg.h b/src/mesa/drivers/

[Mesa-dev] [PATCH 1/2] i965: Split struct brw_reg out from brw_eu.h into its own header.

2012-12-14 Thread Kenneth Graunke
struct brw_instruction and the related instruction emitting code won't be useful on Gen8+, as the instruction encoding changed. However, the struct brw_reg code is still extremely valuable. While we're at it, fix up some style points: - s/GLuint/unsigned/g - s/GLint/int/g - s/GLshort/int16_t/g -

[Mesa-dev] segfaults in softpipe with tbo test since varying packing

2012-12-14 Thread Dave Airlie
build softpipe with debug enabled, force sample_count > 4 so 3.0/3.1 is reported, run arb_texture_buffer_object-formats fs core =20835== Memcheck, a memory error detector ==20835== Copyright (C) 2002-2012, and GNU GPL'd, by Julian Seward et al. ==20835== Using Valgrind-3.8.1 and LibVEX; rerun wit

[Mesa-dev] [PATCH] glsl: avoid using gl context as a memory context

2012-12-14 Thread Dave Airlie
Not sure what was going on here, but running piglit with debug builds might be a good plan :-) Signed-off-by: Dave Airlie --- src/glsl/linker.cpp | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/glsl/linker.cpp b/src/glsl/linker.cpp index 83d0e87..be08156 100644 -

[Mesa-dev] [PATCH 1/2] mesa: add support for ARB_texture_buffer_object_rgb32

2012-12-14 Thread Dave Airlie
This adds the extensions + the tex buffer support for checking the formats. There is a piglit test enhancement sent to that list. Signed-off-by: Dave Airlie --- src/mesa/main/extensions.c | 1 + src/mesa/main/mtypes.h | 1 + src/mesa/main/teximage.c | 13 + 3 files changed,

[Mesa-dev] [PATCH 2/2] st/mesa: add texture buffer object rgb32 support.

2012-12-14 Thread Dave Airlie
This checks if the pipe driver can support RGB32 formats. --- src/mesa/state_tracker/st_extensions.c | 14 +- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/src/mesa/state_tracker/st_extensions.c b/src/mesa/state_tracker/st_extensions.c index f3f01eb..262cc3d 100644 ---

[Mesa-dev] [PATCH] mesa: Array uniform name length includes length of [0]

2012-12-14 Thread Ian Romanick
From: Ian Romanick This is required by OpenGL ES 3.0 and desktop OpenGL 4.2. Previous version were ambiguous. This also matches the behavior of NVIDIA's closed-source driver (version 304.64). Fixed gles3conformance test uniform_buffer_object_getactiveuniformsiv and uniform_buffer_object_struct

Re: [Mesa-dev] [PATCH] glsl: avoid using gl context as a memory context

2012-12-14 Thread Kenneth Graunke
On 12/14/2012 07:26 PM, Dave Airlie wrote: Not sure what was going on here, but running piglit with debug builds might be a good plan :-) Signed-off-by: Dave Airlie --- src/glsl/linker.cpp | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) Reviewed-by: Kenneth Graunke