Re: [Mesa-dev] [v4 06/10] intel: prepare for dri images having more than one plane

2013-05-28 Thread Pohjolainen, Topi
On Fri, May 24, 2013 at 11:55:00AM +0300, Pohjolainen, Topi wrote: > On Thu, May 23, 2013 at 09:39:57PM -0700, Chad Versace wrote: > > On 05/02/2013 12:08 AM, Topi Pohjolainen wrote: > > >v2 (as advised by Eric): > > >- use ARRAY_SIZE > > >- re-use 'image_destroy' for cleaning up after fail

[Mesa-dev] [v6] EXT_image_dma_buf_import for intel

2013-05-28 Thread Topi Pohjolainen
The set introduces new target for 'eglCreateImageKHR()' allowing one to create EGL images out of externally allocated buffers. Especially one can combine up to three separate buffers into one single logical entity. Low level native buffers may not support planar formats and hence EGL layer will ins

[Mesa-dev] [v6 1/9] intel: allow packed prime buffers to be treated normally

2013-05-28 Thread Topi Pohjolainen
v2: - fix earlier rebase error breaking bisect (loaderPriv -> loaderPrivate) Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_screen.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/mesa/drivers/dri/intel/intel_screen.c b/src/mesa/driver

[Mesa-dev] [v6 2/9] intel: do not create renderbuffers out of planar images

2013-05-28 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_fbo.c | 4 1 file changed, 4 insertions(+) diff --git a/src/mesa/drivers/dri/intel/intel_fbo.c b/src/mesa/drivers/dri/intel/intel_fbo.c index 69f8629..7ccbaa8 100644 --- a/src/mesa/drivers/dri/intel/intel_fbo.c +++ b/src/

[Mesa-dev] [v6 3/9] intel: replace single region with a vector of regions

2013-05-28 Thread Topi Pohjolainen
No functional change in preparation for supporting multiple planes per image each having its own region. v2 (Chad): Clarify how valid regions are detected. Originally I thought one could also support cases where one region is shared between multiple planes. This is not really

[Mesa-dev] [v6 4/9] intel: refactor planar format lookup

2013-05-28 Thread Topi Pohjolainen
v2: - refactor both occurences, not just one Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_screen.c | 31 ++- 1 file changed, 18 insertions(+), 13 deletions(-) diff --git a/src/mesa/drivers/dri/intel/intel_screen.c b/src/mesa/drivers/dri/in

[Mesa-dev] [v6 5/9] intel: set dri image dimensions even when creating out of primes

2013-05-28 Thread Topi Pohjolainen
Otherwise 'intel_set_texture_image_region()' won't have enough details to work with. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_screen.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/mesa/drivers/dri/intel/intel_screen.c b/src/mesa/drivers/dri/intel/intel_s

[Mesa-dev] [v6 6/9] intel: prepare for dri images having more than one plane

2013-05-28 Thread Topi Pohjolainen
v2 (Eric): - use ARRAY_SIZE - re-use 'image_destroy' for cleaning up after failure - check directly the region pointer instead of the buffer object when determining if a region exists v3 (Chad): - do not duplicate an image without any valid planes - do not refactor region setti

[Mesa-dev] [v6 7/9] dri: propagate extra dma_buf import attributes to the drivers

2013-05-28 Thread Topi Pohjolainen
v2: - do not break ABI, but instead introduce new entry point for dma buffers and bump up the dri-interface version to eight v3 (Chad): - allow the hook to specify an error originating from the driver. For now only unsupported format is considered. I thought about rejecting th

[Mesa-dev] [v6 8/9] egl: definitions for EXT_image_dma_buf_import

2013-05-28 Thread Topi Pohjolainen
As specified in: http://www.khronos.org/registry/egl/extensions/EXT/EGL_EXT_image_dma_buf_import.txt Checking for the valid fourcc values is left for drivers avoiding dependency to drm header files here. v2: enforce EGL_NO_CONTEXT v3: declare the extension as EGL (not GLES) v4: do not update e

[Mesa-dev] [v6 9/9] egl/dri2: support for creating images out of dma buffers

2013-05-28 Thread Topi Pohjolainen
v2: - upon success close the given file descriptors v3: - use specific entry for dma buffers instead of the basic for primes, and enable the extension based on the availability of the hook v4 (Chad): - use ARRAY_SIZE - improve the comment about the number of file descriptors

Re: [Mesa-dev] [PATCH] radeonsi needs libLLVMipo.

2013-05-28 Thread Michel Dänzer
On Die, 2013-05-28 at 04:16 +0200, Andreas Hartmetz wrote: > --- > configure.ac | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/configure.ac b/configure.ac > index eef4327..486a4e9 100644 > --- a/configure.ac > +++ b/configure.ac > @@ -1786,6 +1786,7 @@ if test "x$with_gallium_drivers" !

Re: [Mesa-dev] [PATCH 0/4] V2 Multiple viewports in Gallium

2013-05-28 Thread Jose Fonseca
- Original Message - > > There's no documentation of PIPE_CAP_MAX_VIEWPORTS but otherwise the > > series looks good. > > I've just sent another patch with it. Let me know if that's enough. The updated series looks good to me too. Thanks for changes. Jose ___

Re: [Mesa-dev] [PATCH] gallium/docs: adds documentation for multi viewport cap

2013-05-28 Thread Jose Fonseca
- Original Message - > > Signed-off-by: Zack Rusin > --- > src/gallium/docs/source/screen.rst |4 > 1 file changed, 4 insertions(+) > > diff --git a/src/gallium/docs/source/screen.rst > b/src/gallium/docs/source/screen.rst > index 2630491..0957e56 100644 > --- a/src/gallium/d

Re: [Mesa-dev] [PATCH 03/13] gallium: Introduce 32-bit bytewise format names

2013-05-28 Thread Richard Sandiford
Michel Dänzer writes: > On Fre, 2013-05-24 at 09:11 -0700, Jose Fonseca wrote: >> >> I agree that with non-array formats, like B5G6R5 and R5G6B5, replacing >> them with endian-variant BGR565 and RGB565 makes a lot of sense (as >> the swapped version will probably never be needed). >> >> But I'm

Re: [Mesa-dev] EGL_BAD_CONTEXT error when creating shared context

2013-05-28 Thread Divick Kishore
Hi Brian, sorry to send you direct email but I have been trying to find answers to couple of issues that I am facing but so far I have not received any response. Please find below the question that I posted to mesa-dev mailing list. I can send the sample if need be which tries to creat

[Mesa-dev] [RFC 0/7] XA patches to for freedreno/a3xx DDX

2013-05-28 Thread Rob Clark
From: Rob Clark The newer snapdragon devices (at least, the one I have in nexus4) no longer has a dedicated 2D core. For these devices, DDX needs to use the 3D core. I've implemented support to use XA in the DDX, but it requires some changes which break the current API in XA. In particular, mo

[Mesa-dev] [RFC 1/7] xa: add xa_surface_from_handle()

2013-05-28 Thread Rob Clark
From: Rob Clark For freedreno DDX, we have to create the scanout GEM bo in a special way (until we have our own KMS/DRM kernel driver.. and even then for phones/tablets you probably need to use the android drivers if you don't want to port the lcd panel driver support). The easiest way to handle

[Mesa-dev] [RFC 2/7] xa: add handle type parameter to get handle

2013-05-28 Thread Rob Clark
From: Jerome Glisse Allow to retrieve non shared handle. Signed-off-by: Jerome Glisse --- src/gallium/state_trackers/xa/xa_tracker.c | 11 ++- src/gallium/state_trackers/xa/xa_tracker.h | 9 - 2 files changed, 18 insertions(+), 2 deletions(-) diff --git a/src/gallium/state_tr

[Mesa-dev] [RFC 3/7] xa: export a common context flush function

2013-05-28 Thread Rob Clark
From: Jerome Glisse First step before moving flushing inside the ddx. Signed-off-by: Jerome Glisse --- src/gallium/state_trackers/xa/xa_composite.c | 2 +- src/gallium/state_trackers/xa/xa_context.c | 17 +++-- src/gallium/state_trackers/xa/xa_context.h | 2 ++ src/gallium/st

[Mesa-dev] [RFC 4/7] xa: fix dma copy function

2013-05-28 Thread Rob Clark
From: Jerome Glisse pipe_transfer_map already offset the surface properly so using the offset again with util_copy_rect might lead to read/write outside the surface. Signed-off-by: Jerome Glisse --- src/gallium/state_trackers/xa/xa_context.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deleti

[Mesa-dev] [RFC 5/7] xa: let ddx handle flush

2013-05-28 Thread Rob Clark
From: Jerome Glisse Signed-off-by: Jerome Glisse --- src/gallium/state_trackers/xa/xa_composite.c | 1 - src/gallium/state_trackers/xa/xa_context.c | 10 ++ 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/src/gallium/state_trackers/xa/xa_composite.c b/src/gallium/stat

[Mesa-dev] [RFC 7/7] freedreno: add xa-freedreno target

2013-05-28 Thread Rob Clark
From: Rob Clark Signed-off-by: Rob Clark --- configure.ac | 4 +- src/gallium/targets/Makefile.am | 3 ++ src/gallium/targets/xa-freedreno/Makefile.am | 65 src/gallium/targets/xa-freedreno/fd_target.c | 20

Re: [Mesa-dev] [PATCH] mesa: Add missing break statement in _mesa_choose_tex_format.

2013-05-28 Thread Brian Paul
On 05/27/2013 07:04 PM, Vinson Lee wrote: Fixes "Missing break in switch" defect reported by Coverity. Signed-off-by: Vinson Lee --- src/mesa/main/texformat.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/mesa/main/texformat.c b/src/mesa/main/texformat.c index fda5d74..0ae79ea 1006

[Mesa-dev] [RFC 6/7] xa: move surface to ref/unref api

2013-05-28 Thread Rob Clark
From: Jerome Glisse This make ddx life easier. Signed-off-by: Jerome Glisse --- src/gallium/state_trackers/xa/xa_priv.h| 1 + src/gallium/state_trackers/xa/xa_tracker.c | 19 +-- src/gallium/state_trackers/xa/xa_tracker.h | 3 ++- 3 files changed, 20 insertions(+), 3 dele

[Mesa-dev] [PATCH] llvmpipe: get rid of tiled/linear layout remains

2013-05-28 Thread sroland
From: Roland Scheidegger Eliminate the rest of the no longer needed layout logic. (It is possible some code could be simplified a bit further still.) --- src/gallium/drivers/llvmpipe/lp_scene.c |6 +- src/gallium/drivers/llvmpipe/lp_setup.c |6 +- src/gallium/drivers/llvm

Re: [Mesa-dev] [PATCH] llvmpipe: get rid of tiled/linear layout remains

2013-05-28 Thread Jose Fonseca
Looks alright AFAICT. Jose - Original Message - > From: Roland Scheidegger > > Eliminate the rest of the no longer needed layout logic. > (It is possible some code could be simplified a bit further still.) > --- > src/gallium/drivers/llvmpipe/lp_scene.c |6 +- > src/gallium

Re: [Mesa-dev] [PATCH] radeonsi needs libLLVMipo.

2013-05-28 Thread Tom Stellard
On Tue, May 28, 2013 at 12:21:20PM +0200, Michel Dänzer wrote: > On Die, 2013-05-28 at 04:16 +0200, Andreas Hartmetz wrote: > > --- > > configure.ac | 1 + > > 1 file changed, 1 insertion(+) > > > > diff --git a/configure.ac b/configure.ac > > index eef4327..486a4e9 100644 > > --- a/configure.ac

Re: [Mesa-dev] [PATCH] mesa: Add missing break statement in _mesa_choose_tex_format.

2013-05-28 Thread Eric Anholt
Vinson Lee writes: > Fixes "Missing break in switch" defect reported by Coverity. Reviewed-by: Eric Anholt pgpY0NueXgNrW.pgp Description: PGP signature ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/lis

Re: [Mesa-dev] [RFC 3/7] xa: export a common context flush function

2013-05-28 Thread Brian Paul
On 05/28/2013 08:13 AM, Rob Clark wrote: From: Jerome Glisse First step before moving flushing inside the ddx. Signed-off-by: Jerome Glisse --- src/gallium/state_trackers/xa/xa_composite.c | 2 +- src/gallium/state_trackers/xa/xa_context.c | 17 +++-- src/gallium/state_trac

Re: [Mesa-dev] [RFC 6/7] xa: move surface to ref/unref api

2013-05-28 Thread Brian Paul
On 05/28/2013 08:13 AM, Rob Clark wrote: From: Jerome Glisse This make ddx life easier. Signed-off-by: Jerome Glisse --- src/gallium/state_trackers/xa/xa_priv.h| 1 + src/gallium/state_trackers/xa/xa_tracker.c | 19 +-- src/gallium/state_trackers/xa/xa_tracker.h | 3

Re: [Mesa-dev] EGL_BAD_CONTEXT error when creating shared context

2013-05-28 Thread Brian Paul
On 05/27/2013 02:05 AM, Divick Kishore wrote: Hi, Does anyone know if mesa supports creation of shared context using egl? When I create a shared context with a call to eglCreateContext where the third argument is a valid context, I get EGL_BAD_CONTEXT error. I took at look at eglCreateCon

Re: [Mesa-dev] [RFC 6/7] xa: move surface to ref/unref api

2013-05-28 Thread Rob Clark
On Tue, May 28, 2013 at 11:56 AM, Brian Paul wrote: > On 05/28/2013 08:13 AM, Rob Clark wrote: >> >> From: Jerome Glisse >> >> This make ddx life easier. >> >> Signed-off-by: Jerome Glisse >> --- >> src/gallium/state_trackers/xa/xa_priv.h| 1 + >> src/gallium/state_trackers/xa/xa_tracker

Re: [Mesa-dev] [PATCH 10/17] intel: Make a temporary miptree when doing blit uploads for glTexSubImage().

2013-05-28 Thread Eric Anholt
Ian Romanick writes: > On 05/24/2013 01:56 PM, Eric Anholt wrote: >> - temp_bo = drm_intel_bo_alloc_tiled(intel->bufmgr, >> - "subimage blit bo", >> - width, height, >> - intelImage->mt->cpp, >> -

Re: [Mesa-dev] [PATCH 5/5] i965/fs: Fix test for smearing enabled on an instruction.

2013-05-28 Thread Eric Anholt
Ian Romanick writes: > On 05/21/2013 06:11 PM, Eric Anholt wrote: >> We were expanding the live range too far, breaking register_coalesce_2() >> and compute_to_mrf() on 16-wide shaders. Turning it back on improves >> GLB2.7 performance by 0.239355% +/- 0.0850649% (n=398), though some >> 16-wide

[Mesa-dev] [PATCH] intel: Extend the force_y_tiling flag to allow forcing no tiling.

2013-05-28 Thread Eric Anholt
For a blit-uploaded temporary, it's faster on current hardware to memcpy the data into a linear CPU mapping than to go through the GTT. v2: Turn the not-fully-supported mask into 3 supported enum values. Reviewed-and-tested-by: Ian Romanick (v1) Reviewed-by: Kenneth Graunke (v1) --- Paul wrote

[Mesa-dev] [PATCH] intel: Enable blit glCopyTexSubImage/glBlitFramebuffer with sRGB.

2013-05-28 Thread Eric Anholt
Since the introduction of default-to-SARGB8 window system framebuffers, non-blorp hardware lost blit acceleration for these two paths between the window system and ARGB textures. Since we shouldn't be doing any conversion anyway, just compatibility-check the linear variants of the formats. Bu

Re: [Mesa-dev] [PATCH] intel: Extend the force_y_tiling flag to allow forcing no tiling.

2013-05-28 Thread Paul Berry
On 28 May 2013 10:55, Eric Anholt wrote: > For a blit-uploaded temporary, it's faster on current hardware to memcpy > the data into a linear CPU mapping than to go through the GTT. > > v2: Turn the not-fully-supported mask into 3 supported enum values. > > Reviewed-and-tested-by: Ian Romanick (v

[Mesa-dev] [PATCH] mesa: Add ARB_separate_shader_objects to dispatch_sanity

2013-05-28 Thread Ian Romanick
From: Ian Romanick This should get squashed into the commit that adds XML definitions for ARB_separate_shader_objects so that git-bisect will work for people who run 'make check' (everyone, right?). Signed-off-by: Ian Romanick Cc: Gregory Hainaut --- src/mesa/main/tests/dispatch_sanity.cpp |

Re: [Mesa-dev] [PATCH] mesa: Add ARB_separate_shader_objects to dispatch_sanity

2013-05-28 Thread Matt Turner
On Tue, May 28, 2013 at 11:26 AM, Ian Romanick wrote: > -// { "glValidateProgramPipeline", 43, -1 }, // XXX: Add to xml > -// { "glGetProgramPipelineInfoLog", 43, -1 }, // XXX: Add to xml > + { "glValidateProgramPipeline", 43, -1 }, > + { "glGetProgramPipelineInfoLog", 43

Re: [Mesa-dev] [PATCH] intel: Extend the force_y_tiling flag to allow forcing no tiling.

2013-05-28 Thread Chad Versace
On 05/28/2013 10:55 AM, Eric Anholt wrote: For a blit-uploaded temporary, it's faster on current hardware to memcpy the data into a linear CPU mapping than to go through the GTT. v2: Turn the not-fully-supported mask into 3 supported enum values. Reviewed-and-tested-by: Ian Romanick (v1) Revie

Re: [Mesa-dev] [PATCH 02/12] sso: Add pipeline container/state

2013-05-28 Thread Ian Romanick
On 05/03/2013 10:44 AM, Gregory Hainaut wrote: V1: * Extend gl_shader_state as pipeline object state * Add a new container gl_pipeline_shader_state that contains binding point of the previous object * Update mesa init/free shader state due to the extension of the attibute * Add an init/free

[Mesa-dev] [Bug 60518] glDrawElements segfault when compiled into display list

2013-05-28 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=60518 --- Comment #3 from cor...@gmx.net --- I've had another look at the trace created with apitrace. And it looks like the issue is caused by glGenerateMipmap(GL_TEXTURE_2D). It seems to use the first and second vertex attribute array, but doesn't dis

Re: [Mesa-dev] [PATCH] mesa: Add ARB_separate_shader_objects to dispatch_sanity

2013-05-28 Thread Ian Romanick
On 05/28/2013 12:31 PM, Matt Turner wrote: On Tue, May 28, 2013 at 11:26 AM, Ian Romanick wrote: -// { "glValidateProgramPipeline", 43, -1 }, // XXX: Add to xml -// { "glGetProgramPipelineInfoLog", 43, -1 }, // XXX: Add to xml + { "glValidateProgramPipeline", 43, -1 }, +

Re: [Mesa-dev] [PATCH 03/12] sso: add support of GL_PROGRAM_SEPARABLE and CreateShaderProgramv

2013-05-28 Thread Ian Romanick
On 05/03/2013 10:44 AM, Gregory Hainaut wrote: V1: CreateShaderProgramv is similar as CreateShaderProgramEXT. The 2 differences are 1/ it an array of strings 2/ it support the GL_PROGRAM_SEPARABLE (aka SeparateShader) flag V2: Formatting improvement --- src/mesa/main/mtypes.h|5 +++ s

Re: [Mesa-dev] [PATCH 04/12] sso: implement ActiveShaderProgram & GetProgramPipelineiv

2013-05-28 Thread Ian Romanick
On 05/03/2013 10:44 AM, Gregory Hainaut wrote: V2: * Rename object * Formatting improvement This really should be two separate commits. --- src/mesa/main/pipelineobj.c | 77 +++ 1 file changed, 77 insertions(+) diff --git a/src/mesa/main/pipelineo

Re: [Mesa-dev] [PATCH 10/12] sso: update glGet: GL_PROGRAM_PIPELINE_BINDING

2013-05-28 Thread Ian Romanick
On 05/24/2013 01:17 PM, gregory hainaut wrote: On Sat, 4 May 2013 11:35:22 +0200 gregory hainaut wrote: On Fri, 3 May 2013 12:04:48 -0700 Matt Turner wrote: On Fri, May 3, 2013 at 10:44 AM, Gregory Hainaut wrote: --- src/mesa/main/get.c |9 + src/mesa/main/get_

Re: [Mesa-dev] [PATCH 10/12] sso: update glGet: GL_PROGRAM_PIPELINE_BINDING

2013-05-28 Thread Ian Romanick
On 05/24/2013 01:17 PM, gregory hainaut wrote: On Sat, 4 May 2013 11:35:22 +0200 gregory hainaut wrote: On Fri, 3 May 2013 12:04:48 -0700 Matt Turner wrote: On Fri, May 3, 2013 at 10:44 AM, Gregory Hainaut wrote: --- src/mesa/main/get.c |9 + src/mesa/main/get_

Re: [Mesa-dev] [v6 2/9] intel: do not create renderbuffers out of planar images

2013-05-28 Thread Eric Anholt
Topi Pohjolainen writes: > Signed-off-by: Topi Pohjolainen > --- > src/mesa/drivers/dri/intel/intel_fbo.c | 4 > 1 file changed, 4 insertions(+) > > diff --git a/src/mesa/drivers/dri/intel/intel_fbo.c > b/src/mesa/drivers/dri/intel/intel_fbo.c > index 69f8629..7ccbaa8 100644 > --- a/src/m

Re: [Mesa-dev] [v6 6/9] intel: prepare for dri images having more than one plane

2013-05-28 Thread Eric Anholt
Topi Pohjolainen writes: > diff --git a/src/mesa/drivers/dri/intel/intel_screen.c > b/src/mesa/drivers/dri/intel/intel_screen.c > index 57c8417..e8ed622 100644 > --- a/src/mesa/drivers/dri/intel/intel_screen.c > +++ b/src/mesa/drivers/dri/intel/intel_screen.c > @@ -491,8 +491,18 @@ intel_create_i

Re: [Mesa-dev] [PATCH 08/17] intle: Add an assert for glCopyTexSubImage() being called on MSAA buffers.

2013-05-28 Thread Marek Olšák
CopyTexSubImage can be called on a multisample renderbuffer if the renderbuffer is part of the window-system framebuffer (i.e. comes from the visual). IIRC, the game Cogs uses it if both MSAA and Post Filters are enabled. Marek On Fri, May 24, 2013 at 10:56 PM, Eric Anholt wrote: > This is just

Re: [Mesa-dev] [PATCH 07/17] i965: Allow glCopyTexSubImage() on depth textures.

2013-05-28 Thread Chad Versace
On 05/24/2013 01:56 PM, Eric Anholt wrote: If the hw is pre-gen5 and can't blit depth, it'll cleanly error out. Did you mean pre-gen6? If I read the code correctly, it is this snippet in intelEmitCopyBlit that is responsible for cleanly erroring out. if (dst_tiling != I915_TILING_NONE) {

Re: [Mesa-dev] [PATCH 04/17] intel: Make a wrapper for intelEmitCopyBlit using miptrees.

2013-05-28 Thread Chad Versace
On 05/24/2013 01:56 PM, Eric Anholt wrote: I had previously asserted that it was hard to write a useful, simpler blit function, but I think this might be it. This has the side effect of extending the 32k pitch check to a few more places that were missing it. --- src/mesa/drivers/dri/intel/inte

Re: [Mesa-dev] [PATCH 08/17] intle: Add an assert for glCopyTexSubImage() being called on MSAA buffers.

2013-05-28 Thread Eric Anholt
Marek Olšák writes: > CopyTexSubImage can be called on a multisample renderbuffer if the > renderbuffer is part of the window-system framebuffer (i.e. comes from > the visual). > > IIRC, the game Cogs uses it if both MSAA and Post Filters are enabled. Good to note; I hadn't thought about this.

Re: [Mesa-dev] [PATCH 08/17] intle: Add an assert for glCopyTexSubImage() being called on MSAA buffers.

2013-05-28 Thread Chad Versace
On 05/28/2013 01:54 PM, Eric Anholt wrote: Marek Olšák writes: CopyTexSubImage can be called on a multisample renderbuffer if the renderbuffer is part of the window-system framebuffer (i.e. comes from the visual). IIRC, the game Cogs uses it if both MSAA and Post Filters are enabled. Good t

Re: [Mesa-dev] [PATCH 02/12] sso: Add pipeline container/state

2013-05-28 Thread gregory hainaut
On Tue, 28 May 2013 12:30:56 -0700 Ian Romanick wrote: > On 05/03/2013 10:44 AM, Gregory Hainaut wrote: > > V1: > > * Extend gl_shader_state as pipeline object state > > * Add a new container gl_pipeline_shader_state that contains > >binding point of the previous object > > * Update mesa init

Re: [Mesa-dev] [PATCH 09/17] intel: Extend the force_y_tiling flag to allow forcing no tiling.

2013-05-28 Thread Chad Versace
For patches 1 2 3 5 6: Reviewed-by. For patches 4 and 7, with the comments fixed: Reviewed-by. Patch 8, I don't agree with it. Patch 9, I gave an r-b for v2. Patch 10-17: I have to walk away now. I plan to finish review this evening. On 05/24/2013 01:56 PM, Eric Anholt wrote: For a blit-uploade

[Mesa-dev] [PATCH 2/8] mesa: Add a helper function for determining the restart index.

2013-05-28 Thread Kenneth Graunke
The derived state approach currently used (_RestartIndex) doesn't work: in the GL_PRIMITIVE_RESTART_FIXED_INDEX case, the restart index depends on the index buffer's data type, and that isn't known until draw time. The existing code also fails to obey the GL 4.3 rules which say that FIXED_INDEX ta

[Mesa-dev] [PATCH 1/8] vbo: Ignore PRIMITIVE_RESTART_FIXED_INDEX for glDrawArrays().

2013-05-28 Thread Kenneth Graunke
The derived _PrimitiveRestart enable flag combines the PrimitiveRestart and PrimitiveRestartFixedIndex enable flags. However, DrawArrays is not supposed to do FixedIndex restart: >From the OpenGL 4.3 Core specification, section 10.3.5 (page 302): "If PRIMITIVE_RESTART_FIXED_INDEX is enabled, prim

[Mesa-dev] [PATCH 4/8] i965: Use the correct restart index for fixed index mode on Haswell.

2013-05-28 Thread Kenneth Graunke
The code that updates the ctx->Array._RestartIndex derived state mashed it to 0x when GL_PRIMITIVE_RESTART_FIXED_INDEX was enabled regardless of the index buffer type. It's supposed to be 0xFF for byte, 0x for short, or 0x for integer types. The new _mesa_primitive_restart_ind

[Mesa-dev] [PATCH 5/8] i965: Fix can_cut_index_handle_restart_index() for byte/short types.

2013-05-28 Thread Kenneth Graunke
Pre-Haswell hardware doesn't support an arbitrary restart index, and instead compares the index buffer value against 0xFF for byte-size buffers, 0x for short-size buffers, or 0x for unsigned integer buffers. OpenGL allows the restart index to be an arbitrary unsigned integer. When comp

[Mesa-dev] [PATCH 6/8] st/mesa: Go back to using ctx->Array.RestartIndex, not _RestartIndex.

2013-05-28 Thread Kenneth Graunke
The derived _RestartIndex field is an attempt to support both GL_PRIMITIVE_RESTART and GL_PRIMITIVE_RESTART_FIXED_INDEX (part of ES 3.0). Gallium drivers don't appear to support ES 3.0 yet, so they don't need to use it. Plus, it's broken and going to go away soon. NOTE: This is a candidate for t

[Mesa-dev] [PATCH 3/8] vbo: Use the new primitive restart index helper function.

2013-05-28 Thread Kenneth Graunke
This gets the correct restart index for unsigned byte/short types when using GL_PRIMITIVE_RESTART_FIXED_INDEX. NOTE: This is a candidate for the 9.1 branch. Signed-off-by: Kenneth Graunke --- src/mesa/vbo/vbo_exec_array.c| 2 +- src/mesa/vbo/vbo_primitive_restart.c | 3 ++- 2 files chan

[Mesa-dev] [PATCH 7/8] mesa: Ignore fixed-index primitive restart in ArrayElement().

2013-05-28 Thread Kenneth Graunke
GL_PRIMITIVE_RESTART_FIXED_INDEX is only supposed to apply to glDrawElements*. This code is for legacy drawing paths and display lists, so it shouldn't apply. NOTE: This is a candidate for the 9.1 branch. Signed-off-by: Kenneth Graunke --- src/mesa/main/api_arrayelt.c | 2 +- 1 file changed, 1

[Mesa-dev] [PATCH 8/8] mesa: Delete the ctx->Array._RestartIndex derived state.

2013-05-28 Thread Kenneth Graunke
It's incorrect and isn't used any longer. NOTE: This is a candidate for the 9.1 branch. Signed-off-by: Kenneth Graunke --- src/mesa/main/attrib.c | 1 - src/mesa/main/enable.c | 5 - src/mesa/main/mtypes.h | 4 +--- src/mesa/main/varray.c | 3 +-- 4 files changed, 2 insertions(+), 11 deleti

Re: [Mesa-dev] [PATCH] intel: Extend the force_y_tiling flag to allow forcing no tiling.

2013-05-28 Thread Kenneth Graunke
On 05/28/2013 10:55 AM, Eric Anholt wrote: For a blit-uploaded temporary, it's faster on current hardware to memcpy the data into a linear CPU mapping than to go through the GTT. v2: Turn the not-fully-supported mask into 3 supported enum values. Reviewed-and-tested-by: Ian Romanick (v1) Revie

Re: [Mesa-dev] [PATCH] intel: Enable blit glCopyTexSubImage/glBlitFramebuffer with sRGB.

2013-05-28 Thread Kenneth Graunke
On 05/28/2013 11:18 AM, Eric Anholt wrote: Since the introduction of default-to-SARGB8 window system framebuffers, non-blorp hardware lost blit acceleration for these two paths between the window system and ARGB textures. Since we shouldn't be doing any conversion anyway, just compatibility-

Re: [Mesa-dev] [PATCH 08/17] intle: Add an assert for glCopyTexSubImage() being called on MSAA buffers.

2013-05-28 Thread Kenneth Graunke
On 05/28/2013 01:41 PM, Marek Olšák wrote: CopyTexSubImage can be called on a multisample renderbuffer if the renderbuffer is part of the window-system framebuffer (i.e. comes from the visual). IIRC, the game Cogs uses it if both MSAA and Post Filters are enabled. Marek Oh, very good point.

[Mesa-dev] [PATCH v2] radeonsi needs libLLVMipo.

2013-05-28 Thread Andreas Hartmetz
r600g needs it too, so add ipo in the common radeon_llvm_check(). radeonsi compiled and linked, but it failed at dynamic link time with a missing symbol. --- configure.ac | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index eef4327..521331b 100

Re: [Mesa-dev] [PATCH 08/17] intle: Add an assert for glCopyTexSubImage() being called on MSAA buffers.

2013-05-28 Thread Eric Anholt
Chad Versace writes: > On 05/28/2013 01:54 PM, Eric Anholt wrote: >> Marek Olšák writes: >> >>> CopyTexSubImage can be called on a multisample renderbuffer if the >>> renderbuffer is part of the window-system framebuffer (i.e. comes from >>> the visual). >>> >>> IIRC, the game Cogs uses it if bo

Re: [Mesa-dev] [PATCH 09/17] intel: Extend the force_y_tiling flag to allow forcing no tiling.

2013-05-28 Thread Eric Anholt
Chad Versace writes: > For patches 1 2 3 5 6: Reviewed-by. > For patches 4 and 7, with the comments fixed: Reviewed-by. > Patch 8, I don't agree with it. > Patch 9, I gave an r-b for v2. > Patch 10-17: I have to walk away now. I plan to finish review this evening. Sorry, at the point that I had

[Mesa-dev] [Bug 65103] New: mesa: fix build on uclibc system

2013-05-28 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=65103 Priority: medium Bug ID: 65103 Assignee: mesa-dev@lists.freedesktop.org Summary: mesa: fix build on uclibc system Severity: normal Classification: Unclassified OS: All

Re: [Mesa-dev] [PATCH 8/8] mesa: Delete the ctx->Array._RestartIndex derived state.

2013-05-28 Thread Eric Anholt
Kenneth Graunke writes: > diff --git a/src/mesa/main/varray.c b/src/mesa/main/varray.c > index dff0070..5f10f0c 100644 > --- a/src/mesa/main/varray.c > +++ b/src/mesa/main/varray.c > @@ -1110,9 +1110,8 @@ _mesa_PrimitiveRestartIndex(GLuint index) > } > > ctx->Array.RestartIndex = index;

[Mesa-dev] [PATCH] i965/vs: Fix implied_mrf_writes() for integer division.

2013-05-28 Thread Eric Anholt
Previously it would assertion fail in debug builds (though the correct value was returned in a non-debug build). Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=64727 --- src/mesa/drivers/dri/i965/brw_vec4.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/mesa/drivers/dri/i965/

Re: [Mesa-dev] [PATCH] i965/vs: Fix implied_mrf_writes() for integer division.

2013-05-28 Thread Eric Anholt
Eric Anholt writes: > Previously it would assertion fail in debug builds (though the correct > value was returned in a non-debug build). The subject should clarify "... on pre-gen6" pgp7QYTJTHswi.pgp Description: PGP signature ___ mesa-dev mailing li

Re: [Mesa-dev] [PATCH 08/17] intle: Add an assert for glCopyTexSubImage() being called on MSAA buffers.

2013-05-28 Thread Marek Olšák
I recommend you to force an MSAA visual and run piglit. It may also be useful to test all MSAA sample counts when you're at it (that's what I did when I was working on MSAA). Marek On Wed, May 29, 2013 at 12:55 AM, Eric Anholt wrote: > Chad Versace writes: > >> On 05/28/2013 01:54 PM, Eric Anho

[Mesa-dev] [Bug 63650] gallium/opencl opencl-examples test failures

2013-05-28 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=63650 --- Comment #5 from Tom Stellard --- I can't reproduce this any more. Are you still seeing this bug? -- You are receiving this mail because: You are the assignee for the bug. ___ mesa-dev mailing lis

[Mesa-dev] [PATCH 1/3] draw: clamp the viewports to always be between 0 and max

2013-05-28 Thread Zack Rusin
The spec says that everything beyond last set viewport is reset to zero so make sure to preserve that behavior. Signed-off-by: Zack Rusin --- src/gallium/auxiliary/draw/draw_cliptest_tmp.h |8 src/gallium/auxiliary/draw/draw_context.c | 14 ++ src/gallium/auxiliar

[Mesa-dev] [PATCH 2/3] llvmpipe: clamp scissors to be between 0 and max

2013-05-28 Thread Zack Rusin
We need to clamp to make sure invalid shader doesn't crash our driver. The spec says to return 0-th index for everything that's out of bounds and to reset everything above the last scissor to zero. Signed-off-by: Zack Rusin --- src/gallium/drivers/llvmpipe/lp_setup.h |3 +++ src/galliu

[Mesa-dev] [PATCH 3/3] draw: make sure viewport index is fetched from leading vertex

2013-05-28 Thread Zack Rusin
Viewport index should only be used on a per primitive basis, so instead of fetching it from each vertex, potentially making each vertex in a primitive use a different viewport index, which is obviously broken, make sure that we only fetch from the first vertex in the primitive making the viewport i

Re: [Mesa-dev] [PATCH] intel: Enable blit glCopyTexSubImage/glBlitFramebuffer with sRGB.

2013-05-28 Thread Eric Anholt
Kenneth Graunke writes: > On 05/28/2013 11:18 AM, Eric Anholt wrote: >> Since the introduction of default-to-SARGB8 window system framebuffers, >> non-blorp hardware lost blit acceleration for these two paths between the >> window system and ARGB textures. Since we shouldn't be doing any >>

Re: [Mesa-dev] [PATCH 5/5] i965/fs: Fix test for smearing enabled on an instruction.

2013-05-28 Thread Eric Anholt
Eric Anholt writes: > Ian Romanick writes: > >> On 05/21/2013 06:11 PM, Eric Anholt wrote: >>> We were expanding the live range too far, breaking register_coalesce_2() >>> and compute_to_mrf() on 16-wide shaders. Turning it back on improves >>> GLB2.7 performance by 0.239355% +/- 0.0850649% (n=

Re: [Mesa-dev] [PATCH 8/8] mesa: Delete the ctx->Array._RestartIndex derived state.

2013-05-28 Thread Kenneth Graunke
On 05/28/2013 04:06 PM, Eric Anholt wrote: Kenneth Graunke writes: diff --git a/src/mesa/main/varray.c b/src/mesa/main/varray.c index dff0070..5f10f0c 100644 --- a/src/mesa/main/varray.c +++ b/src/mesa/main/varray.c @@ -1110,9 +1110,8 @@ _mesa_PrimitiveRestartIndex(GLuint index) } ct

[Mesa-dev] [PATCH] llvmpipe: reduce alignment requirement for resources from 64x64 to 4x4

2013-05-28 Thread sroland
From: Roland Scheidegger The overallocation was very bad especially for things like 1d array textures which got blown up by a factor of 64. (Even ordinary smallish 2d textures benefit a lot from this, a mipmapped 64x64 rgba8 texture previously used 7*16kB = 112kB instead of now ~22kB.) 4x4 is cho

Re: [Mesa-dev] [PATCH] llvmpipe: reduce alignment requirement for resources from 64x64 to 4x4

2013-05-28 Thread Roland Scheidegger
FWIW this change is built on top of "llvmpipe: Remove x/y from cmd_bin", which was discussed on the list but hasn't been commited yet. Roland Am 29.05.2013 03:41, schrieb srol...@vmware.com: > From: Roland Scheidegger > > The overallocation was very bad especially for things like 1d array > tex

Re: [Mesa-dev] [PATCH v2] radeonsi needs libLLVMipo.

2013-05-28 Thread Tom Stellard
On Tue, May 28, 2013 at 11:59:41PM +0200, Andreas Hartmetz wrote: > r600g needs it too, so add ipo in the common radeon_llvm_check(). > > radeonsi compiled and linked, but it failed at dynamic link time > with a missing symbol. Pushed, thanks! -Tom > --- > configure.ac | 4 ++-- > 1 file chang

Re: [Mesa-dev] [PATCH] i965/vs: Fix implied_mrf_writes() for integer division.

2013-05-28 Thread Kenneth Graunke
On 05/28/2013 04:12 PM, Eric Anholt wrote: Previously it would assertion fail in debug builds (though the correct value was returned in a non-debug build). Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=64727 --- src/mesa/drivers/dri/i965/brw_vec4.cpp | 2 ++ 1 file changed, 2 inserti

Re: [Mesa-dev] [PATCH 8/8] mesa: Delete the ctx->Array._RestartIndex derived state.

2013-05-28 Thread Eric Anholt
Kenneth Graunke writes: > On 05/28/2013 04:06 PM, Eric Anholt wrote: >> Kenneth Graunke writes: >>> diff --git a/src/mesa/main/varray.c b/src/mesa/main/varray.c >>> index dff0070..5f10f0c 100644 >>> --- a/src/mesa/main/varray.c >>> +++ b/src/mesa/main/varray.c >>> @@ -1110,9 +1110,8 @@ _mesa_Pri

Re: [Mesa-dev] EGL_BAD_CONTEXT error when creating shared context

2013-05-28 Thread Divick Kishore
Hi Brian, thanks for your reply. On Tue, May 28, 2013 at 9:33 PM, Brian Paul wrote: > I took at look at eglCreateContext(). It's basically: > > EGLContext > eglCreateContext(EGLDisplay dpy, EGLConfig config, EGLContext share_list, > const EGLint *attrib_list) > { >