Re: [Mesa-dev] [PATCH] mesa-demos: fix opengles1/texture_from_pixmap test

2014-03-11 Thread Tapani Pälli
On 03/10/2014 06:05 PM, Chia-I Wu wrote: On Fri, Mar 7, 2014 at 6:56 PM, Tapani Pälli tapani.pa...@intel.com wrote: Remove GL_OES_EGL_image_external usage, this would work with current Mesa only if image was created with EGL_EXT_image_dma_buf_import, this makes test work again also if

Re: [Mesa-dev] [PATCH] i965: fix dma_buf import with non-zero offset.

2014-03-11 Thread Pohjolainen, Topi
On Mon, Mar 10, 2014 at 05:36:17PM +0100, Gwenole Beauchesne wrote: Fix eglCreateImage() from a packed dma_buf surface with a non-zero offset to pixels data. In particular, this fixes support for planar YUV surfaces when they are individually mapped on a per-plane basis, i.e. when the

Re: [Mesa-dev] [PATCH 1/5] r600g, radeonsi: fix MAX_TEXTURE_3D_LEVELS and MAX_TEXTURE_ARRAY_LAYERS limits

2014-03-11 Thread Michel Dänzer
On Mon, 2014-03-10 at 01:15 +0100, Marek Olšák wrote: From: Marek Olšák marek.ol...@amd.com This series is Reviewed-by: Michel Dänzer michel.daen...@amd.com diff --git a/src/gallium/drivers/radeonsi/si_pipe.c b/src/gallium/drivers/radeonsi/si_pipe.c index 040fc5c..95f022b 100644 ---

Re: [Mesa-dev] [PATCH 3/3] r600g, radeonsi: attempt to fix racy multi-context apps calling BufferData

2014-03-11 Thread Michel Dänzer
On Son, 2014-03-09 at 02:24 +0100, Marek Olšák wrote: From: Marek Olšák marek.ol...@amd.com Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=75061 [...] @@ -136,15 +137,23 @@ bool r600_init_resource(struct r600_common_screen *rscreen, res-domains = RADEON_DOMAIN_VRAM;

Re: [Mesa-dev] [PATCH] i965: fix dma_buf import with non-zero offset.

2014-03-11 Thread Gwenole Beauchesne
Hi, 2014-03-11 7:37 GMT+01:00 Pohjolainen, Topi topi.pohjolai...@intel.com: On Mon, Mar 10, 2014 at 05:36:17PM +0100, Gwenole Beauchesne wrote: Fix eglCreateImage() from a packed dma_buf surface with a non-zero offset to pixels data. In particular, this fixes support for planar YUV surfaces

Re: [Mesa-dev] [PATCH] i965: fix dma_buf import with non-zero offset.

2014-03-11 Thread Pohjolainen, Topi
On Tue, Mar 11, 2014 at 08:59:46AM +0100, Gwenole Beauchesne wrote: Hi, 2014-03-11 7:37 GMT+01:00 Pohjolainen, Topi topi.pohjolai...@intel.com: On Mon, Mar 10, 2014 at 05:36:17PM +0100, Gwenole Beauchesne wrote: Fix eglCreateImage() from a packed dma_buf surface with a non-zero offset to

Re: [Mesa-dev] [PATCH] i965: fix dma_buf import with non-zero offset.

2014-03-11 Thread Pohjolainen, Topi
On Tue, Mar 11, 2014 at 10:18:47AM +0200, Pohjolainen, Topi wrote: On Tue, Mar 11, 2014 at 08:59:46AM +0100, Gwenole Beauchesne wrote: Hi, 2014-03-11 7:37 GMT+01:00 Pohjolainen, Topi topi.pohjolai...@intel.com: On Mon, Mar 10, 2014 at 05:36:17PM +0100, Gwenole Beauchesne wrote: Fix

Re: [Mesa-dev] [PATCH] i965: fix dma_buf import with non-zero offset.

2014-03-11 Thread Pohjolainen, Topi
On Tue, Mar 11, 2014 at 08:59:46AM +0100, Gwenole Beauchesne wrote: Hi, 2014-03-11 7:37 GMT+01:00 Pohjolainen, Topi topi.pohjolai...@intel.com: On Mon, Mar 10, 2014 at 05:36:17PM +0100, Gwenole Beauchesne wrote: Fix eglCreateImage() from a packed dma_buf surface with a non-zero offset to

Re: [Mesa-dev] Wrong colors in 3D apps on big-endian systems

2014-03-11 Thread Richard Sandiford
Michel Dänzer mic...@daenzer.net writes: On Mon, 2014-03-10 at 10:11 +0100, Christian Zigotzky wrote: On 10.03.2014 02:49, Michel Dänzer wrote: Congratulations, you just broke llvmpipe again on big endian systems. ;) I'm sorry but Mesa classic works very well on Debian Sid and Lubuntu

Re: [Mesa-dev] [PATCH 1/5] r600g, radeonsi: fix MAX_TEXTURE_3D_LEVELS and MAX_TEXTURE_ARRAY_LAYERS limits

2014-03-11 Thread Marek Olšák
On Tue, Mar 11, 2014 at 8:10 AM, Michel Dänzer mic...@daenzer.net wrote: On Mon, 2014-03-10 at 01:15 +0100, Marek Olšák wrote: From: Marek Olšák marek.ol...@amd.com This series is Reviewed-by: Michel Dänzer michel.daen...@amd.com diff --git a/src/gallium/drivers/radeonsi/si_pipe.c

[Mesa-dev] [Bug 63269] explicitly symlinking libraries without libtool breaks OpenBSD build

2014-03-11 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=63269 Emil Velikov emil.l.veli...@gmail.com changed: What|Removed |Added Status|NEW |RESOLVED

[Mesa-dev] [Bug 63269] explicitly symlinking libraries without libtool breaks OpenBSD build

2014-03-11 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=63269 --- Comment #2 from Jonathan Gray j...@openbsd.org --- Hi Emil, I saw your series of patches on the list and pulled them into my branch with some other fixes required to build with and I could indeed complete a build. Unfortunately since then

Re: [Mesa-dev] [PATCH 1/6] glsl: Optimize pow(x, 2) into x * x.

2014-03-11 Thread Erik Faye-Lund
On Mon, Mar 10, 2014 at 11:54 PM, Matt Turner matts...@gmail.com wrote: Cuts two instructions out of SynMark's Gl32VSInstancing benchmark. --- src/glsl/opt_algebraic.cpp | 8 1 file changed, 8 insertions(+) diff --git a/src/glsl/opt_algebraic.cpp b/src/glsl/opt_algebraic.cpp index

[Mesa-dev] [Bug 63269] explicitly symlinking libraries without libtool breaks OpenBSD build

2014-03-11 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=63269 --- Comment #3 from Emil Velikov emil.l.veli...@gmail.com --- Kind of unrelated to the symlinking but afaics you have three options * revert commit 8c136b53b79 * update binutils * nag the patch author to add a *BSD quirk :-) I'm not entirely

[Mesa-dev] [PATCH 1/3] r600g, radeonsi: use a fallback in dma_copy instead of failing

2014-03-11 Thread Marek Olšák
From: Marek Olšák marek.ol...@amd.com v2: - allow byte-aligned DMA buffer copies on Evergreen - fix piglit/texsubimage regression - use the fallback for 3D copies (depth 1) as well --- src/gallium/drivers/r600/evergreen_state.c | 40 +

Re: [Mesa-dev] [PATCH 1/6] glsl: Optimize pow(x, 2) into x * x.

2014-03-11 Thread Erik Faye-Lund
On Tue, Mar 11, 2014 at 2:50 PM, Erik Faye-Lund kusmab...@gmail.com wrote: On Mon, Mar 10, 2014 at 11:54 PM, Matt Turner matts...@gmail.com wrote: Cuts two instructions out of SynMark's Gl32VSInstancing benchmark. --- src/glsl/opt_algebraic.cpp | 8 1 file changed, 8 insertions(+)

Re: [Mesa-dev] Wrong colors in 3D apps on big-endian systems

2014-03-11 Thread Christian Zigotzky
Am 11.03.14 12:08, schrieb Richard Sandiford: Michel Dänzer mic...@daenzer.net writes: On Mon, 2014-03-10 at 10:11 +0100, Christian Zigotzky wrote: On 10.03.2014 02:49, Michel Dänzer wrote: Congratulations, you just broke llvmpipe again on big endian systems. ;) I'm sorry but Mesa classic

Re: [Mesa-dev] Wrong colors in 3D apps on big-endian systems

2014-03-11 Thread Richard Sandiford
Christian Zigotzky chzigot...@xenosoft.de writes: Am 11.03.14 12:08, schrieb Richard Sandiford: Michel Dänzer mic...@daenzer.net writes: On Mon, 2014-03-10 at 10:11 +0100, Christian Zigotzky wrote: On 10.03.2014 02:49, Michel Dänzer wrote: Congratulations, you just broke llvmpipe again on big

Re: [Mesa-dev] [PATCH 1/3] r600g, radeonsi: use a fallback in dma_copy instead of failing

2014-03-11 Thread Jan Vesely
On Tue, 2014-03-11 at 15:09 +0100, Marek Olšák wrote: From: Marek Olšák marek.ol...@amd.com v2: - allow byte-aligned DMA buffer copies on Evergreen - fix piglit/texsubimage regression - use the fallback for 3D copies (depth 1) as well ---

[Mesa-dev] [PATCH 3/3] r600g, radeonsi: attempt to fix racy multi-context apps calling BufferData

2014-03-11 Thread Marek Olšák
From: Marek Olšák marek.ol...@amd.com Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=75061 v2: minimize the window where cs_buf != new_buf --- src/gallium/drivers/r600/r600_state_common.c| 5 + src/gallium/drivers/radeon/r600_buffer_common.c | 22 --

Re: [Mesa-dev] Wrong colors in 3D apps on big-endian systems

2014-03-11 Thread Christian Zigotzky
Am 11.03.14 16:25, schrieb Richard Sandiford: Christian Zigotzky chzigot...@xenosoft.de writes: Am 11.03.14 12:08, schrieb Richard Sandiford: Michel Dänzer mic...@daenzer.net writes: On Mon, 2014-03-10 at 10:11 +0100, Christian Zigotzky wrote: On 10.03.2014 02:49, Michel Dänzer wrote:

Re: [Mesa-dev] Interested in contributing to WGL support in Waffle Project, for GSoC 2014

2014-03-11 Thread Jordan Justen
On Mon, Mar 10, 2014 at 11:19 AM, Vidudaya Bandara vnband...@gmail.com wrote: Hi all, I'm Vidudaya Neranjan Bandara , Currently I'm an undergraduate from University of Moratuwa , Department of Computer Science and Engineering, Sri Lanka. I'm very much interested in open source software

Re: [Mesa-dev] [PATCH 1/6] glsl: Optimize pow(x, 2) into x * x.

2014-03-11 Thread Ian Romanick
On 03/10/2014 07:21 PM, Roland Scheidegger wrote: Am 11.03.2014 01:23, schrieb Ian Romanick: I had a pretty similar patch on the top of my pow-optimization branch. I also expand x**3 and x**4. I had hoped that would enable some cases to expand then merge to MADs. It should also be faster on

Re: [Mesa-dev] [PATCH 1/3] r600g, radeonsi: use a fallback in dma_copy instead of failing

2014-03-11 Thread Jan Vesely
On Tue, 2014-03-11 at 11:37 -0400, Jan Vesely wrote: On Tue, 2014-03-11 at 15:09 +0100, Marek Olšák wrote: From: Marek Olšák marek.ol...@amd.com v2: - allow byte-aligned DMA buffer copies on Evergreen - fix piglit/texsubimage regression - use the fallback for 3D copies (depth

Re: [Mesa-dev] [PATCH 1/3] r600g, radeonsi: use a fallback in dma_copy instead of failing

2014-03-11 Thread Tom Stellard
On Tue, Mar 11, 2014 at 12:37:15PM -0400, Jan Vesely wrote: On Tue, 2014-03-11 at 11:37 -0400, Jan Vesely wrote: On Tue, 2014-03-11 at 15:09 +0100, Marek Olšák wrote: From: Marek Olšák marek.ol...@amd.com v2: - allow byte-aligned DMA buffer copies on Evergreen - fix

Re: [Mesa-dev] Wrong colors in 3D apps on big-endian systems

2014-03-11 Thread Christian Zigotzky
On 11.03.2014 16:25, Richard Sandiford wrote: I just mean changing instances of things like PIPE_FORMAT_A8R8G8B8_UNORM to PIPE_FORMAT_ARGB_UNORM in the relevant parts of the r600 support (which is I think what Michel also meant -- like I say, I'm not really adding anything new here).

Re: [Mesa-dev] [PATCH 1/3] r600g, radeonsi: use a fallback in dma_copy instead of failing

2014-03-11 Thread Jan Vesely
On Tue, 2014-03-11 at 12:49 -0400, Tom Stellard wrote: On Tue, Mar 11, 2014 at 12:37:15PM -0400, Jan Vesely wrote: On Tue, 2014-03-11 at 11:37 -0400, Jan Vesely wrote: On Tue, 2014-03-11 at 15:09 +0100, Marek Olšák wrote: From: Marek Olšák marek.ol...@amd.com v2: - allow

Re: [Mesa-dev] [PATCH 1/6] glsl: Optimize pow(x, 2) into x * x.

2014-03-11 Thread Roland Scheidegger
Am 11.03.2014 17:29, schrieb Ian Romanick: On 03/10/2014 07:21 PM, Roland Scheidegger wrote: Am 11.03.2014 01:23, schrieb Ian Romanick: I had a pretty similar patch on the top of my pow-optimization branch. I also expand x**3 and x**4. I had hoped that would enable some cases to expand then

Re: [Mesa-dev] [Mesa-stable] [PATCH] glsl: Allow overlapping locations for vertex input attributes

2014-03-11 Thread Ian Romanick
On 03/10/2014 04:15 PM, Anuj Phogat wrote: On Mon, Mar 10, 2014 at 3:27 PM, Ian Romanick i...@freedesktop.org mailto:i...@freedesktop.org wrote: On 03/10/2014 11:19 AM, Anuj Phogat wrote: Currently overlapping locations of input variables are not allowed for all the

Re: [Mesa-dev] [PATCH] i965: fix dma_buf import with non-zero offset.

2014-03-11 Thread Eric Anholt
Gwenole Beauchesne gb.de...@gmail.com writes: Fix eglCreateImage() from a packed dma_buf surface with a non-zero offset to pixels data. In particular, this fixes support for planar YUV surfaces when they are individually mapped on a per-plane basis, i.e. when the OES_EGL_image_external is not

Re: [Mesa-dev] [PATCH 1/6] glsl: Optimize pow(x, 2) into x * x.

2014-03-11 Thread Eric Anholt
Erik Faye-Lund kusmab...@gmail.com writes: On Tue, Mar 11, 2014 at 2:50 PM, Erik Faye-Lund kusmab...@gmail.com wrote: On Mon, Mar 10, 2014 at 11:54 PM, Matt Turner matts...@gmail.com wrote: Cuts two instructions out of SynMark's Gl32VSInstancing benchmark. --- src/glsl/opt_algebraic.cpp | 8

Re: [Mesa-dev] [PATCH 1/3] r600g, radeonsi: use a fallback in dma_copy instead of failing

2014-03-11 Thread Marek Olšák
I pushed this patch without a review because of bugs that needed to be fixed. Marek On Tue, Mar 11, 2014 at 3:09 PM, Marek Olšák mar...@gmail.com wrote: From: Marek Olšák marek.ol...@amd.com v2: - allow byte-aligned DMA buffer copies on Evergreen - fix piglit/texsubimage regression

Re: [Mesa-dev] [PATCH 1/6] glsl: Optimize pow(x, 2) into x * x.

2014-03-11 Thread Paul Berry
On 10 March 2014 17:23, Ian Romanick i...@freedesktop.org wrote: I had a pretty similar patch on the top of my pow-optimization branch. I also expand x**3 and x**4. I had hoped that would enable some cases to expand then merge to MADs. It should also be faster on older GENs where POW perf

Re: [Mesa-dev] [PATCH 1/6] glsl: Optimize pow(x, 2) into x * x.

2014-03-11 Thread Matt Turner
On Tue, Mar 11, 2014 at 10:35 AM, Roland Scheidegger srol...@vmware.com wrote: Am 11.03.2014 17:29, schrieb Ian Romanick: and there was much rejoicing. The timings that we use in the compiler backend are 22 cycles for POW, and 14 cycles for MUL on Haswell. The numbers are similar (but

Re: [Mesa-dev] [RFC PATCH 3/4] mesa: Prefer non-swizzled formats when prefer_no_swizzle set

2014-03-11 Thread Francisco Jerez
Chris Forbes chr...@ijw.co.nz writes: Hi Michel, and thanks for the quick feedback. This is why it's tagged RFC :) After thinking about it a bit more, I'm not convinced it's the right thing either. You're right, the spec is very careful not to say anything about the memory layout. The

Re: [Mesa-dev] [RFC PATCH 3/4] mesa: Prefer non-swizzled formats when prefer_no_swizzle set

2014-03-11 Thread Chris Forbes
There's cases where BGRA or ARGB or whatever avoids having to juggle things either in texture upload paths, or blits to scanout buffers -- if we didn't care about that, then yes, we could just default to the canonical layout. I think we can also detect the cases for views via

Re: [Mesa-dev] [RFC PATCH 3/4] mesa: Prefer non-swizzled formats when prefer_no_swizzle set

2014-03-11 Thread Francisco Jerez
Chris Forbes chr...@ijw.co.nz writes: There's cases where BGRA or ARGB or whatever avoids having to juggle things either in texture upload paths, or blits to scanout buffers -- if we didn't care about that, then yes, we could just default to the canonical layout. Right, but wouldn't it make

Re: [Mesa-dev] [RFC PATCH 3/4] mesa: Prefer non-swizzled formats when prefer_no_swizzle set

2014-03-11 Thread Francisco Jerez
Chris Forbes chr...@ijw.co.nz writes: If prefer_no_swizzle is set, try: - The exact matching format - Formats with the required components in the correct order, plus a junk component - finally, swizzled formats (BGRA etc) Signed-off-by: Chris Forbes chr...@ijw.co.nz ---

Re: [Mesa-dev] [PATCH] mesa: mark GL_RGB9_E5 as not color-renderable

2014-03-11 Thread Ian Romanick
On 03/09/2014 05:10 PM, Marek Olšák wrote: From: Marek Olšák marek.ol...@amd.com The GL 4.4 spec says it's not color-renderable and not accepted by RenderBufferStorage. The EXT_texture_shared_exponent spec says it's not color-renderable but it's accepted by RenderBufferStorageEXT. This

[Mesa-dev] static version of osmesa is missing llvm symbols, bug?

2014-03-11 Thread Burlen Loring
Hi All, When I make a static build of mesa with osmesa+llvm, all of the llvm related symbols are undefined in the resulting libOSMesa.a archive. There is an la file produced that lists the dependencies, however shouldn't those all be linked into the installed archive? for reference see my

Re: [Mesa-dev] [PATCH 1/6] glsl: Optimize pow(x, 2) into x * x.

2014-03-11 Thread Erik Faye-Lund
On Tue, Mar 11, 2014 at 7:27 PM, Eric Anholt e...@anholt.net wrote: Erik Faye-Lund kusmab...@gmail.com writes: On Tue, Mar 11, 2014 at 2:50 PM, Erik Faye-Lund kusmab...@gmail.com wrote: On Mon, Mar 10, 2014 at 11:54 PM, Matt Turner matts...@gmail.com wrote: Cuts two instructions out of

Re: [Mesa-dev] [PATCH 5/6] glsl: Optimize (v.x + v.y) + (v.z + v.w) into dot(v, 1.0).

2014-03-11 Thread Eric Anholt
Matt Turner matts...@gmail.com writes: Cuts five instructions out of SynMark's Gl32VSInstancing benchmark. --- Could be made more general, but I don't see any cases we could optimize in our existing shader collection. src/glsl/opt_algebraic.cpp | 35 +++ 1

Re: [Mesa-dev] static version of osmesa is missing llvm symbols, bug?

2014-03-11 Thread Emil Velikov
On 11/03/14 20:31, Burlen Loring wrote: Hi All, Hi Burlen When I make a static build of mesa with osmesa+llvm, all of the llvm related symbols are undefined in the resulting libOSMesa.a archive. There is an la file produced that lists the dependencies, however shouldn't those all be linked

Re: [Mesa-dev] Interested in contributing to WGL support in Waffle Project, for GSoC 2014

2014-03-11 Thread Chad Versace
On Tue, Mar 11, 2014 at 04:20:41PM +, Jordan Justen wrote: On Mon, Mar 10, 2014 at 11:19 AM, Vidudaya Bandara vnband...@gmail.com wrote: Hi all, I'm Vidudaya Neranjan Bandara , Currently I'm an undergraduate from University of Moratuwa , Department of Computer Science and Engineering,

Re: [Mesa-dev] [PATCH 2/6] glsl: Rebalance expression trees that are reduction operations.

2014-03-11 Thread Eric Anholt
Matt Turner matts...@gmail.com writes: The intention of this pass was to give us better instruction scheduling opportunities, but it unexpectedly reduced some instruction counts as well: total instructions in shared programs: 139 - 1666073 (-0.03%) instructions in affected programs:

Re: [Mesa-dev] Interested in contributing to WGL support in Waffle Project, for GSoC 2014

2014-03-11 Thread Chad Versace
Vidudaya, I have some comments on Jordan's list of subgoals. 1. Waffle's examples/gl_basic.c gl_basic is a little toy program that developers can use to test Waffle when adding support for new platforms, such as WGL. If you can get gl_basic to work on WGL, then that

Re: [Mesa-dev] [PATCH 1/6] glsl: Optimize pow(x, 2) into x * x.

2014-03-11 Thread Eric Anholt
Erik Faye-Lund kusmab...@gmail.com writes: On Tue, Mar 11, 2014 at 7:27 PM, Eric Anholt e...@anholt.net wrote: Erik Faye-Lund kusmab...@gmail.com writes: On Tue, Mar 11, 2014 at 2:50 PM, Erik Faye-Lund kusmab...@gmail.com wrote: On Mon, Mar 10, 2014 at 11:54 PM, Matt Turner

Re: [Mesa-dev] [RFC PATCH 3/4] mesa: Prefer non-swizzled formats when prefer_no_swizzle set

2014-03-11 Thread Chris Forbes
Yeah, you're right -- that looks bogus. There's been piles of confusion recently in formats.h about which end things are laid out from; the truth though is obviously in the pack/unpack code and the hardware format documentation. On Wed, Mar 12, 2014 at 9:12 AM, Francisco Jerez

Re: [Mesa-dev] static version of osmesa is missing llvm symbols, bug?

2014-03-11 Thread Burlen Loring
yep, I'm using 10.1.0 and also noticed the same in 9.2.2. in short static linking is essential for reasonable performance of parallel applications on Cray systems. In this scenario the application is duplicated across 100s/1000s of compute nodes which share a remote-parallel file system

Re: [Mesa-dev] static version of osmesa is missing llvm symbols, bug?

2014-03-11 Thread Emil Velikov
On 12/03/14 00:08, Burlen Loring wrote: yep, I'm using 10.1.0 and also noticed the same in 9.2.2. In that case it wasn't me ;-) in short static linking is essential for reasonable performance of parallel applications on Cray systems. In this scenario the application is duplicated across

Re: [Mesa-dev] [PATCH] Release gl_debug_state when destroying context.

2014-03-11 Thread Brian Paul
On 03/11/2014 05:07 PM, Mike Stroyan wrote: Commit 6e8d04a caused a leak by allocating ctx-Debug but never freeing it. Release the memory in _mesa_free_errors_data when destroying a context. Use FREE to match CALLOC_STRUCT from _mesa_get_debug_state. --- src/mesa/main/errors.c | 5 - 1

Re: [Mesa-dev] [PATCH 1/6] glsl: Optimize pow(x, 2) into x * x.

2014-03-11 Thread Erik Faye-Lund
On Wed, Mar 12, 2014 at 12:00 AM, Eric Anholt e...@anholt.net wrote: Erik Faye-Lund kusmab...@gmail.com writes: On Tue, Mar 11, 2014 at 7:27 PM, Eric Anholt e...@anholt.net wrote: Erik Faye-Lund kusmab...@gmail.com writes: On Tue, Mar 11, 2014 at 2:50 PM, Erik Faye-Lund kusmab...@gmail.com

Re: [Mesa-dev] [PATCH 1/6] glsl: Optimize pow(x, 2) into x * x.

2014-03-11 Thread Eric Anholt
Erik Faye-Lund kusmab...@gmail.com writes: On Wed, Mar 12, 2014 at 12:00 AM, Eric Anholt e...@anholt.net wrote: Erik Faye-Lund kusmab...@gmail.com writes: On Tue, Mar 11, 2014 at 7:27 PM, Eric Anholt e...@anholt.net wrote: Erik Faye-Lund kusmab...@gmail.com writes: On Tue, Mar 11, 2014 at

[Mesa-dev] [PATCH] Release gl_debug_state when destroying context.

2014-03-11 Thread Mike Stroyan
Commit 6e8d04a caused a leak by allocating ctx-Debug but never freeing it. Release the memory in _mesa_free_errors_data when destroying a context. Use FREE to match CALLOC_STRUCT from _mesa_get_debug_state. --- src/mesa/main/errors.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff

[Mesa-dev] [PATCH] mesa: Add an error condition in glGetFramebufferAttachmentParameteriv()

2014-03-11 Thread Anuj Phogat
From the OpenGL 4.4 spec page 275: If pname is FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE, param will contain the format of components of the specified attachment, one of FLOAT, INT, UNSIGNED_INT, SIGNED_NORMALIZED, or UNSIGNED_NORMALIZED for floating-point, signed integer, unsigned

Re: [Mesa-dev] Wrong colors in 3D apps on big-endian systems

2014-03-11 Thread Michel Dänzer
On Die, 2014-03-11 at 17:51 +0100, Christian Zigotzky wrote: On 11.03.2014 16:25, Richard Sandiford wrote: I just mean changing instances of things like PIPE_FORMAT_A8R8G8B8_UNORM to PIPE_FORMAT_ARGB_UNORM in the relevant parts of the r600 support (which is I think what Michel also

Re: [Mesa-dev] Wrong colors in 3D apps on big-endian systems

2014-03-11 Thread Michel Dänzer
On Die, 2014-03-11 at 11:08 +, Richard Sandiford wrote: Michel Dänzer mic...@daenzer.net writes: On Mon, 2014-03-10 at 10:11 +0100, Christian Zigotzky wrote: The Fedora guys have solved the problem with the patch mesa-9.2-llvmpipe-on-big-endian.patch. What do you think of this

Re: [Mesa-dev] [PATCH] i965: fix dma_buf import with non-zero offset.

2014-03-11 Thread Gwenole Beauchesne
Hi, 2014-03-11 19:06 GMT+01:00 Eric Anholt e...@anholt.net: Gwenole Beauchesne gb.de...@gmail.com writes: Fix eglCreateImage() from a packed dma_buf surface with a non-zero offset to pixels data. In particular, this fixes support for planar YUV surfaces when they are individually mapped on a

[Mesa-dev] [PATCH 4/4] i965/fs: Invalidate live intervals when demoting uniforms to pull params.

2014-03-11 Thread Kenneth Graunke
Normally, nothing uses live intervals at this point, so this isn't necessary. However, dump_instructions() calculates them and uses them to show register pressure. So, calling dump_instructions() in this area of the code would segfault due to the arrays being the wrong size. This is not a

[Mesa-dev] [PATCH 1/4] i965/fs: Fix register comparisons in saturate propagation.

2014-03-11 Thread Kenneth Graunke
opt_saturate_propagation_local compares scan_inst-dst.reg/reg_offset with inst-src[0].reg/reg_offset, and ensures that scan_inst-dst.file is GRF. But nothing ensured that inst-src[0].file was GRF. In the following program, this resulted in u1:F matching vgrf1:UW, and a saturate being incorrectly

[Mesa-dev] [PATCH 3/4] i965/fs: Print +reladdr on variably-indexed uniform arrays.

2014-03-11 Thread Kenneth Graunke
Previously, dump_instruction() would print output such as: { 2}3: mov vgrf1:F, u0:F { 3}4: mov vgrf7:F, u0:F { 4}5: mov vgrf8:F, u0:F which looked like either a scalar access or perhaps a constant-indexed access of element 0, when it was really a variable index.t

[Mesa-dev] [PATCH 2/4] i965: Fix register types in dump_instructions(), again.

2014-03-11 Thread Kenneth Graunke
In commit e57d77280efcbfd6579a88f071426653287ef833, I fixed this for destinations in the Vec4 backend, and sources in the scalar backend. But not both types in both backends. To prevent this mess from continuing, make the reg_encoding table static, so only the disassembler can use it.

Re: [Mesa-dev] [PATCH 3/4] i965/fs: Print +reladdr on variably-indexed uniform arrays.

2014-03-11 Thread Matt Turner
On Tue, Mar 11, 2014 at 10:15 PM, Kenneth Graunke kenn...@whitecape.org wrote: Previously, dump_instruction() would print output such as: { 2}3: mov vgrf1:F, u0:F { 3}4: mov vgrf7:F, u0:F { 4}5: mov vgrf8:F, u0:F which looked like either a scalar access or perhaps a