Re: [Mesa-dev] [RFC PATCH 4/5] ralloc: Make the C++ macros arrange for class destructors to be called.

2013-09-21 Thread Ian Romanick
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 09/21/2013 11:41 AM, Eric Anholt wrote: > Ian Romanick writes: > >> Premature "send" strikes again... >> >> On 09/19/2013 05:26 PM, Ian Romanick wrote: >>> On 09/18/2013 04:55 PM, Kenneth Graunke wrote: Previously, almost all classes didn't

Re: [Mesa-dev] [PATCH 6/7] glsl: Hide many classes local to individual .cpp files in anon namespaces.

2013-09-21 Thread Ian Romanick
On 09/21/2013 03:16 PM, Kenneth Graunke wrote: > On 09/20/2013 06:52 PM, Eric Anholt wrote: >> This gives the compiler the chance to inline and not export class symbols >> even in the absence of LTO. Saves about 60kb on disk. > > This is probably worth doing. > Reviewed-by: Kenneth Graunke > >

[Mesa-dev] [PATCH] i965/blorp: Fix the register types on blorp's push constants.

2013-09-21 Thread Eric Anholt
The UD values were getting set up as floats. This happened to work out because they were used as the second argument where the first was a dword, and gen6+ doesn't do source conversions. But it did trigger fulsim warnings, and it meant if you used the push constant as the first operand you would

[Mesa-dev] [PATCH] i965: Reenable glBitmap() after the sRGB winsys enabling.

2013-09-21 Thread Eric Anholt
The format of the window system framebuffer changed from ARGB to SARGB8, but we're still supposed to render to it the same as ARGB unless the user flipped the GL_FRAMEBUFFER_SRGB switch. --- src/mesa/drivers/dri/i965/intel_pixel_bitmap.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion

Re: [Mesa-dev] [PATCH 6/7] glsl: Hide many classes local to individual .cpp files in anon namespaces.

2013-09-21 Thread Kenneth Graunke
On 09/20/2013 06:52 PM, Eric Anholt wrote: > This gives the compiler the chance to inline and not export class symbols > even in the absence of LTO. Saves about 60kb on disk. This is probably worth doing. Reviewed-by: Kenneth Graunke Another important reason for doing this is that it avoids nam

Re: [Mesa-dev] [PATCH 3/7] mesa: Shrink the size of the enum string lookup struct.

2013-09-21 Thread Paul Berry
On 21 September 2013 09:03, Kenneth Graunke wrote: > On 09/21/2013 07:59 AM, Brian Paul wrote: > > On Fri, Sep 20, 2013 at 7:52 PM, Eric Anholt wrote: > >> Since it's only used for debug information, we can misalign the struct > and > >> save the disk space. Another 19k on a 64-bit build. > >>

Re: [Mesa-dev] [PATCH 2/2] implement NV_vdpau_interop v3

2013-09-21 Thread Christian König
Am 21.09.2013 17:35, schrieb Stephan Raue: Am 21.09.2013 16:56, schrieb Marek Olšák: 8) Do we actually have enough tests, so that we can say this feature works? I have integrated v2 of this patches yesterday in OpenELEC, an embedded XBMC distro and it looks already nice. I will start to cr

Re: [Mesa-dev] [PATCH 2/2] implement NV_vdpau_interop v3

2013-09-21 Thread Christian König
Exactly as I though. It's code that I never worked with and I only implemented it so far that XBMC does indeed work, but clearly following the spec is something different. I've committed the rest of the patchset, but I have my doubts that Tim wants me to spend any more time on it, so we have

Re: [Mesa-dev] [RFC] Consolidate the remaining source files to Makefile.sources

2013-09-21 Thread Emil Velikov
On 12/09/13 18:04, Jakob Bornecrantz wrote: > On Thu, Aug 15, 2013 at 7:04 PM, Emil Velikov wrote: > >> Hello list >> >> Feeling inspired by the automake work done in mesa, I felt like >> finishing a few things that did not receive too much attention >> * use Makefile.sources wherever possible >>

[Mesa-dev] [PATCH 2/2] st/xorg: add sanity checks after malloc

2013-09-21 Thread Emil Velikov
Signed-off-by: Emil Velikov --- src/gallium/state_trackers/xorg/xorg_driver.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/src/gallium/state_trackers/xorg/xorg_driver.c b/src/gallium/state_trackers/xorg/xorg_driver.c index 9d7713c..49e726b 100644 --- a/src/gallium/state_trackers/xor

[Mesa-dev] [PATCH 1/2] targets/xorg-nouveau: drop usage of dri1 function DRICreatePCIBusID

2013-09-21 Thread Emil Velikov
The function should have never used it in the first place as it was a left over from the DRI1 days of the nouveau ddx. While we're around check if KMS is supported before opening the nouveau device, and add support for Fermi & Kepler cards. Compile tested only due to the lack of a Fermi/Kepler car

[Mesa-dev] Minor st/xorg related cleanups

2013-09-21 Thread Emil Velikov
A couple of small things that I've noticed while going through. Bit curious if there would be anyone to review and/or commit the nouveau patch so I've decided to send it along the st/xorg one :P Cheers Emil [PATCH 1/2] targets/xorg-nouveau: drop usage of dri1 function [PATCH 2/2] st/xorg: add san

Re: [Mesa-dev] [RFC PATCH 4/5] ralloc: Make the C++ macros arrange for class destructors to be called.

2013-09-21 Thread Eric Anholt
Ian Romanick writes: > Premature "send" strikes again... > > On 09/19/2013 05:26 PM, Ian Romanick wrote: >> On 09/18/2013 04:55 PM, Kenneth Graunke wrote: >>> Previously, almost all classes didn't actually call their destructors, >>> which is non-intuitive for C++ code. Setting them up to be cal

Re: [Mesa-dev] [PATCH 1/5] ralloc: Introduce new macros for defining C++ new/delete operators.

2013-09-21 Thread Kenneth Graunke
On 09/19/2013 03:35 PM, Ian Romanick wrote: > I like this approach a lot... certainly a lot more than various > inheritance-based approaches that we had discussed before. > > Patches 1, 2, 3, and 5 are > > Reviewed-by: Ian Romanick > > Patch 4 probably is too (with the comment addition that I s

Re: [Mesa-dev] [PATCH 3/7] mesa: Shrink the size of the enum string lookup struct.

2013-09-21 Thread Kenneth Graunke
On 09/21/2013 07:59 AM, Brian Paul wrote: > On Fri, Sep 20, 2013 at 7:52 PM, Eric Anholt wrote: >> Since it's only used for debug information, we can misalign the struct and >> save the disk space. Another 19k on a 64-bit build. >> --- >> src/mapi/glapi/gen/gl_enums.py | 6 -- >> 1 file chan

Re: [Mesa-dev] [PATCH 2/2] implement NV_vdpau_interop v3

2013-09-21 Thread Stephan Raue
Am 21.09.2013 16:56, schrieb Marek Olšák: 8) Do we actually have enough tests, so that we can say this feature works? I have integrated v2 of this patches yesterday in OpenELEC, an embedded XBMC distro and it looks already nice. I will start to create and provide testbuilds for our Users wit

Re: [Mesa-dev] [PATCH 1/5] winsys/radeon: fix killing the CS thread

2013-09-21 Thread Marek Olšák
For all patches except NV_vdpau_interop: Reviewed-by: Marek Olšák For NV_vdpau_interop, I sent another review a while ago. Mare On Sat, Sep 21, 2013 at 4:41 PM, Christian König wrote: > From: Christian König > > Kill the thread only after we checked that it's not used any more, not before. >

Re: [Mesa-dev] [PATCH 1/3] mesa: Add core support for the GL_AMD_performance_monitor extension.

2013-09-21 Thread Brian Paul
On Fri, Sep 20, 2013 at 3:42 PM, Kenneth Graunke wrote: > On 09/20/2013 07:55 AM, Brian Paul wrote: >> On Thu, Sep 19, 2013 at 5:27 PM, Kenneth Graunke >> wrote: > [snip] >>> diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h >>> index 6d700ec..70dba6e 100644 >>> --- a/src/mesa/main/mt

Re: [Mesa-dev] [PATCH 5/7] mesa: Drop an extra copy-and-pasted copy in the program clone function.

2013-09-21 Thread Brian Paul
On Fri, Sep 20, 2013 at 7:52 PM, Eric Anholt wrote: > --- > src/mesa/program/program.c | 1 - > 1 file changed, 1 deletion(-) > > diff --git a/src/mesa/program/program.c b/src/mesa/program/program.c > index 5dd68d9..aa3c5b4 100644 > --- a/src/mesa/program/program.c > +++ b/src/mesa/program/progra

Re: [Mesa-dev] [PATCH 3/7] mesa: Shrink the size of the enum string lookup struct.

2013-09-21 Thread Brian Paul
On Fri, Sep 20, 2013 at 7:52 PM, Eric Anholt wrote: > Since it's only used for debug information, we can misalign the struct and > save the disk space. Another 19k on a 64-bit build. > --- > src/mapi/glapi/gen/gl_enums.py | 6 -- > 1 file changed, 4 insertions(+), 2 deletions(-) > > diff --g

Re: [Mesa-dev] [PATCH 2/2] implement NV_vdpau_interop v3

2013-09-21 Thread Marek Olšák
1) The Errors section of the spec isn't implemented properly. 2) Passing GL_TEXTURE_RECTANGLE to the new functions should generate an error if ctx->Extensions.NV_texture_rectangle is false. 3) There should also probably be some checking for GL_ARB_texture_non_power_of_two, but the spec doesn't sa

Re: [Mesa-dev] [PATCH 4/7] mesa: Convert some runtime asserts to static asserts.

2013-09-21 Thread Brian Paul
On Fri, Sep 20, 2013 at 7:52 PM, Eric Anholt wrote: > Noticed while grepping through the code for something else. > --- > src/mesa/program/program.c | 36 ++-- > 1 file changed, 22 insertions(+), 14 deletions(-) > > diff --git a/src/mesa/program/program.c b/src/mes

[Mesa-dev] [PATCH 2/5] winsys/radeon: remove cs_queue_empty

2013-09-21 Thread Christian König
From: Christian König Waiting for an empty queue is nonsense and can lead to deadlocks if we have multiple waiters or another thread that continuously sends down new commands. Just post the cs to the queue and immediately wait for it to finish. This is a candidate for the stable branch. Signed

[Mesa-dev] [PATCH 3/5] winsys/radeon: share winsys between different fd's

2013-09-21 Thread Christian König
From: Christian König Share the winsys between different fd's if they point to the same device. Signed-off-by: Christian König --- src/gallium/winsys/radeon/drm/radeon_drm_winsys.c | 19 +-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/src/gallium/winsys/radeo

[Mesa-dev] [PATCH 5/5] radeon/uvd: async flush the UVD cs

2013-09-21 Thread Christian König
From: Christian König No need to block for the CS thread here. Signed-off-by: Christian König --- src/gallium/drivers/radeon/radeon_uvd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gallium/drivers/radeon/radeon_uvd.c b/src/gallium/drivers/radeon/radeon_uvd.c index

[Mesa-dev] [PATCH 4/5] implement NV_vdpau_interop v3

2013-09-21 Thread Christian König
From: Christian König v2: Actually implement interop between the gallium state tracker and the VDPAU backend. v3: Make it also available in non legacy contexts, fix video buffer sharing. Signed-off-by: Christian König --- src/gallium/include/state_tracker/vdpau_interop.h | 49 s

[Mesa-dev] [PATCH 1/5] winsys/radeon: fix killing the CS thread

2013-09-21 Thread Christian König
From: Christian König Kill the thread only after we checked that it's not used any more, not before. Signed-off-by: Christian König --- src/gallium/winsys/radeon/drm/radeon_drm_winsys.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/gallium/winsys/radeon/drm/ra

Re: [Mesa-dev] The long way to a faster build with shared libs and some fixes ...

2013-09-21 Thread Marek Olšák
On Thu, Sep 12, 2013 at 3:32 PM, Christian König wrote: > Am 12.09.2013 14:52, schrieb Marek Olšák: > >> I think current Gallium drivers only need one exported symbol to work: >> __driDriverExtensions. See: >> http://lists.freedesktop.org/archives/mesa-dev/2013-August/043038.html > > > Yes that's

[Mesa-dev] [PATCH 2/2] implement NV_vdpau_interop v3

2013-09-21 Thread Christian König
From: Christian König v2: Actually implement interop between the gallium state tracker and the VDPAU backend. v3: Make it also available in non legacy contexts, fix video buffer sharing. Signed-off-by: Christian König --- src/gallium/include/state_tracker/vdpau_interop.h | 49 s

[Mesa-dev] [PATCH 1/2] winsys/radeon: share winsys between different fd's

2013-09-21 Thread Christian König
From: Christian König Share the winsys between different fd's if they point to the same device. Signed-off-by: Christian König --- src/gallium/winsys/radeon/drm/radeon_drm_winsys.c | 19 +-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/src/gallium/winsys/radeo