[Mesa-dev] GLSL IR int-to-float pass

2011-05-24 Thread Bryan Cain
Hi, In the past few days, I've been working on native integer support in my GLSL to TGSI translator. Something that's come to my attention is that supporting Gallium targets with and without integer support using a single GLSL IR backend will more or less require a GLSL IR pass to convert int, ui

[Mesa-dev] [PATCH 01/18] i965: Fix assertion failures in unused brw_reg setup by deleting it.

2011-05-24 Thread Eric Anholt
I was using undefined values to create an unused value. Go me. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=37366 --- src/mesa/drivers/dri/i965/brw_fs.cpp |1 - 1 files changed, 0 insertions(+), 1 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_fs.cpp b/src/mesa/drivers/d

[Mesa-dev] [PATCH 06/18] i965: Move prepare_wm_surfaces texobj declarations inside of _ReallyEnabled.

2011-05-24 Thread Eric Anholt
Interestingly, the compiler wasn't doing this for us at -O2, so we were doing the computation for every non-_ReallyEnabled unit. --- src/mesa/drivers/dri/i965/brw_wm_surface_state.c |5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_wm_surfac

[Mesa-dev] [PATCH 04/18] i965/fs: Track fixed GRF regs separate from allocated GRF file in scheduling.

2011-05-24 Thread Eric Anholt
There's an assumption here that fixed GRFs will never intersect with the allocated GRFs. That's true today, though it might change some day if we decide to register-allocate the regs containing push constants once they're dead. This fixes a regression in 0f7325b89038937bd428f7c89ed9859189a0ab0b i

[Mesa-dev] [PATCH 08/18] i965: Don't compute brw->wm.input_size_masks when it's unused.

2011-05-24 Thread Eric Anholt
It's only used in the old fragment program path, to avoid projection when w is always 1. We do want to do this in the new path pre-gen6 too, but we'll probably do it through the ir. --- src/mesa/drivers/dri/i965/brw_vs_constval.c | 12 +++- 1 files changed, 11 insertions(+), 1 deletions

[Mesa-dev] [PATCH 16/18] i965: Remove linear_color for GL_PERSPECTIVE_CORRECTION_HINT.

2011-05-24 Thread Eric Anholt
>From the GL 2.1 spec: "Required perspective-correct interpolation for all fragment attributes except depth in sections 3.4.1 and 3.5.1, effectively making GL PERSPECTIVE CORRECT HINT a no-op." --- src/mesa/drivers/dri/i965/brw_fs.cpp|2 +- src/mesa/drivers/dri/i965/brw_sf.c

[Mesa-dev] [PATCH 05/18] i965/fs: Move the computation of register block count from unit to compile.

2011-05-24 Thread Eric Anholt
No net code size change, but unit update is down 0.8% code size. --- src/mesa/drivers/dri/i965/brw_context.h | 15 +-- src/mesa/drivers/dri/i965/brw_fs.cpp |4 ++-- src/mesa/drivers/dri/i965/brw_wm.c |2 +- src/mesa/drivers/dri/i965/brw_wm_state.c |4 ++-- 4 fi

[Mesa-dev] [PATCH 17/18] i965: Remove dead shadowtex_mask entry in the WM key.

2011-05-24 Thread Eric Anholt
--- src/mesa/drivers/dri/i965/brw_wm.c |3 --- src/mesa/drivers/dri/i965/brw_wm.h |1 - 2 files changed, 0 insertions(+), 4 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_wm.c b/src/mesa/drivers/dri/i965/brw_wm.c index 5abf0cf..8cb1612 100644 --- a/src/mesa/drivers/dri/i965/brw_

[Mesa-dev] [PATCH 02/18] i965: Warnings cleanup.

2011-05-24 Thread Eric Anholt
--- src/mesa/drivers/dri/i965/brw_eu_emit.c |3 --- src/mesa/drivers/dri/i965/gen7_vs_state.c |1 - 2 files changed, 0 insertions(+), 4 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_eu_emit.c b/src/mesa/drivers/dri/i965/brw_eu_emit.c index 2d41302..e7370f3 100644 --- a/src/me

[Mesa-dev] [PATCH 15/18] i965: Avoid generating MOVs for assignments of expressions.

2011-05-24 Thread Eric Anholt
No statistically significant difference in 3dbenchmark egypt/pro. --- src/mesa/drivers/dri/i965/brw_fs.cpp | 82 +- src/mesa/drivers/dri/i965/brw_fs.h |5 ++- 2 files changed, 75 insertions(+), 12 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_fs.c

[Mesa-dev] [PATCH 03/18] i965/fs: Add a helper function for add_dep(before, after, before->latency).

2011-05-24 Thread Eric Anholt
This lets us avoid a bunch of before==NULL checks in the callers. --- .../dri/i965/brw_fs_schedule_instructions.cpp | 50 +++ 1 files changed, 19 insertions(+), 31 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_fs_schedule_instructions.cpp b/src/mesa/drivers/dri/i

[Mesa-dev] [PATCH 12/18] i965: Replace struct with bit shifting for WM null surfaces.

2011-05-24 Thread Eric Anholt
Reduces compiled size of brw_wm_surface_state.o another 1.9%. Overall, this brw_wm_surface_state reduction series cuts firefox-talos-gfx runtime by 0.68% +/- 0.42% (n=6). --- src/mesa/drivers/dri/i965/brw_wm_surface_state.c | 26 +++--- 1 files changed, 13 insertions(+), 13 dele

[Mesa-dev] [PATCH 14/18] i965: Remove brw_surface_state struct that is now unused.

2011-05-24 Thread Eric Anholt
--- src/mesa/drivers/dri/i965/brw_structs.h | 74 --- 1 files changed, 0 insertions(+), 74 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_structs.h b/src/mesa/drivers/dri/i965/brw_structs.h index ad31222..7b9cdba 100644 --- a/src/mesa/drivers/dri/i965/brw_s

[Mesa-dev] [PATCH 11/18] i965: Replace struct with bit shifting for WM pull constant surfaces.

2011-05-24 Thread Eric Anholt
This reduces compiled size (4.7% of brw_wm_surface_state.o). --- src/mesa/drivers/dri/i965/brw_defines.h |1 + src/mesa/drivers/dri/i965/brw_wm_surface_state.c | 51 +++--- 2 files changed, 17 insertions(+), 35 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw

[Mesa-dev] [PATCH 10/18] i965: Replace struct with bit shifting for WM render target surfaces.

2011-05-24 Thread Eric Anholt
This massively reduces compiled size (6.7% of brw_wm_surface_state.o). --- src/mesa/drivers/dri/i965/brw_defines.h |5 ++ src/mesa/drivers/dri/i965/brw_wm_surface_state.c | 71 -- 2 files changed, 45 insertions(+), 31 deletions(-) diff --git a/src/mesa/drivers/d

[Mesa-dev] [PATCH 07/18] i965: Drop a gratuitous "if" that the compiler didn't eliminate at -O2.

2011-05-24 Thread Eric Anholt
Oddly, this increases compiled code size. (marking the 'if' as likely also increases code size, but not as much). --- src/mesa/drivers/dri/i965/brw_wm_surface_state.c | 18 -- 1 files changed, 8 insertions(+), 10 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_wm_surfac

[Mesa-dev] [PATCH 18/18] i965: Pack the lookup and line_aa bits into the first dword of the key.

2011-05-24 Thread Eric Anholt
They were occupying whole 32-bit words, despite being only 10 or so bits. Reduces code size slightly (80/3300 bytes). --- src/mesa/drivers/dri/i965/brw_wm.h |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_wm.h b/src/mesa/drivers/dri/i965/

[Mesa-dev] [PATCH 13/18] i965: Switch brw_state_dump to using bitshifting for surface state.

2011-05-24 Thread Eric Anholt
--- src/mesa/drivers/dri/i965/brw_defines.h|4 src/mesa/drivers/dri/i965/brw_state_dump.c | 22 +- 2 files changed, 17 insertions(+), 9 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_defines.h b/src/mesa/drivers/dri/i965/brw_defines.h index d8f4bef..6d

[Mesa-dev] [PATCH 09/18] i965: Replace structs with bitfield shifting for WM texture surfaces.

2011-05-24 Thread Eric Anholt
This massively reduces compiled size (4.9% of brw_wm_surface_state.o). --- src/mesa/drivers/dri/i965/brw_defines.h | 34 +++- src/mesa/drivers/dri/i965/brw_wm_surface_state.c | 67 +++-- 2 files changed, 68 insertions(+), 33 deletions(-) diff --git a/src/mesa/

[Mesa-dev] [PATCH] glx/dri2: Paper over errors in DRI2Connect when indirect (#28125)

2011-05-24 Thread Adam Jackson
DRI2 will throw BadRequest for this when the client is not local, but DRI2 is an implementation detail and not something callers should have to know about. Silently swallow errors in this case, and just propagate the failure through DRI2Connect's return code. Signed-off-by: Adam Jackson --- src

[Mesa-dev] [Bug 37253] SIGSEGV in dri2FlushFrontBuffer/MakeContextCurrent

2011-05-24 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=37253 Karl Tomlinson changed: What|Removed |Added CC||bugs.freedesk...@karlt.net -- Configur

[Mesa-dev] [Bug 37150] sRGB textures are too bright in Starcraft 2

2011-05-24 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=37150 Pavel Ondračka changed: What|Removed |Added Status|NEW |RESOLVED Resolution|

[Mesa-dev] [Bug 37150] sRGB textures are too bright in Starcraft 2

2011-05-24 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=37150 --- Comment #23 from Benjamin Bellec 2011-05-24 13:11:43 PDT --- (In reply to comment #19) > Curiously, running ETQW with gallium-swrast is totally playable, almost like > r600g. Forget that. -- Configure bugmail: https://bugs.freedesktop.org

[Mesa-dev] [Bug 37150] sRGB textures are too bright in Starcraft 2

2011-05-24 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=37150 --- Comment #22 from Sven Arvidsson 2011-05-24 12:12:32 PDT --- Yep, it's working fine- -- Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email --- You are receiving this mail because: --- You are the assignee for the

[Mesa-dev] [Bug 37150] sRGB textures are too bright in Starcraft 2

2011-05-24 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=37150 --- Comment #21 from Benjamin Bellec 2011-05-24 10:56:21 PDT --- (In reply to comment #20) > Can you guys retest with Mesa commit d3b6e8a2b8e3581e07a6dd7277d4d4c6c0407760? It's the same for me: - fix Wine/CivilizationIV - doesn't fix ETQW --

[Mesa-dev] [Bug 37253] SIGSEGV in dri2FlushFrontBuffer/MakeContextCurrent

2011-05-24 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=37253 Benoit Jacob changed: What|Removed |Added Component|Drivers/Gallium/r600|Mesa core AssignedTo|dri-devel@li

[Mesa-dev] [Bug 33188] st/dri: WebGL Conformance Test Runner crash

2011-05-24 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=33188 Benoit Jacob changed: What|Removed |Added Status|NEW |RESOLVED Resolution|

[Mesa-dev] [Bug 37150] sRGB textures are too bright in Starcraft 2

2011-05-24 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=37150 --- Comment #20 from Brian Paul 2011-05-24 08:08:14 PDT --- Can you guys retest with Mesa commit d3b6e8a2b8e3581e07a6dd7277d4d4c6c0407760? -- Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email --- You are receiving thi

Re: [Mesa-dev] [PATCH] mesa: fix glGetTexImage for srgb textures when srgb decode is skipped

2011-05-24 Thread Brian Paul
This looks good. I'll commit it soon. -Brian On 05/23/2011 10:33 PM, Mike Kaplinskiy wrote: I see; that sounds fine. I was a bit wary of changing the code since I don't know what else calls it. Would something like the attached work? I also included an attempt at changing the tex-srgb piglit

Re: [Mesa-dev] [PATCH] st/mesa: prefer formats without stencil for DEPTH_COMPONENT

2011-05-24 Thread Brian Paul
On 05/24/2011 06:32 AM, Marek Olšák wrote: for fast Z clears to be used more often --- Looks good. I'm going to push my table-driven replacement for st_choose_format() and rebase your patch on top of it. -Brian ___ mesa-dev mailing list mesa-dev@

Re: [Mesa-dev] gallium st incorrect drawable <-> context bindings.

2011-05-24 Thread Thomas Hellstrom
On 05/24/2011 12:13 PM, Jakob Bornecrantz wrote: On Tue, May 24, 2011 at 11:53 AM, Thomas Hellstrom wrote: Hi, I'm not sure when this use of drawable<-> context bindings started, but the below commit uses an invalid assumption to fix a problem the root cause of which is also an invalid a

[Mesa-dev] [PATCH] st/mesa: prefer formats without stencil for DEPTH_COMPONENT

2011-05-24 Thread Marek Olšák
for fast Z clears to be used more often --- src/mesa/state_tracker/st_format.c | 22 ++ 1 files changed, 14 insertions(+), 8 deletions(-) diff --git a/src/mesa/state_tracker/st_format.c b/src/mesa/state_tracker/st_format.c index b136210..d42bcb4 100644 --- a/src/mesa/state_

Re: [Mesa-dev] gallium st incorrect drawable <-> context bindings.

2011-05-24 Thread Jose Fonseca
- Original Message - > On Tue, May 24, 2011 at 11:53 AM, Thomas Hellstrom > wrote: > > Hi, > > > > I'm not sure when this use of drawable <-> context bindings > > started, but the > > below commit uses an invalid assumption to fix a problem the root > > cause of > > which is also an inva

Re: [Mesa-dev] gallium st incorrect drawable <-> context bindings.

2011-05-24 Thread Jose Fonseca
- Original Message - > Hi, > > I'm not sure when this use of drawable <-> context bindings started, > but > the below commit uses an invalid assumption to fix a problem the root > cause of which is also an invalid assumption. > > It's incorrect to associate a drawable with a context. >

Re: [Mesa-dev] gallium st incorrect drawable <-> context bindings.

2011-05-24 Thread Jakob Bornecrantz
On Tue, May 24, 2011 at 11:53 AM, Thomas Hellstrom wrote: > Hi, > > I'm not sure when this use of drawable <-> context bindings started, but the > below commit uses an invalid assumption to fix a problem the root cause of > which is also an invalid assumption. > > It's incorrect to associate a dra

[Mesa-dev] gallium st incorrect drawable <-> context bindings.

2011-05-24 Thread Thomas Hellstrom
Hi, I'm not sure when this use of drawable <-> context bindings started, but the below commit uses an invalid assumption to fix a problem the root cause of which is also an invalid assumption. It's incorrect to associate a drawable with a context. A drawable may have multiple contexts bound t