Re: [Mesa-dev] [PATCH] r600g: Include SH and SMX when invalidating read caches

2013-06-24 Thread Martin Andersson
On Sun, Jun 23, 2013 at 11:56 PM, Alex Deucher alexdeuc...@gmail.com wrote: On Sun, Jun 23, 2013 at 2:24 PM, Marek Olšák mar...@gmail.com wrote: Hi Alex, rctx-framebuffer.state.nr_cbufs might not contain what you think it does, because the framebuffer that needs flushing may have been

Re: [Mesa-dev] [PATCH] st/mesa: handle SNORM formats in generic CopyPixels path

2013-06-24 Thread Jose Fonseca
- Original Message - --- src/gallium/auxiliary/util/u_format.c | 14 ++ src/gallium/auxiliary/util/u_format.h | 3 +++ src/mesa/state_tracker/st_cb_drawpixels.c | 6 ++ 3 files changed, 23 insertions(+) diff --git a/src/gallium/auxiliary/util/u_format.c

Re: [Mesa-dev] [PATCH] st/mesa: handle SNORM formats in generic CopyPixels path

2013-06-24 Thread Dave Airlie
On Mon, Jun 24, 2013 at 6:12 PM, Jose Fonseca jfons...@vmware.com wrote: - Original Message - --- src/gallium/auxiliary/util/u_format.c | 14 ++ src/gallium/auxiliary/util/u_format.h | 3 +++ src/mesa/state_tracker/st_cb_drawpixels.c | 6 ++ 3 files

Re: [Mesa-dev] [PATCH] vl/mpeg12: implement inverse scan/quantization steps

2013-06-24 Thread Christian König
Am 23.06.2013 18:59, schrieb Ilia Mirkin: Signed-off-by: Ilia Mirkin imir...@alum.mit.edu --- These changes make MPEG2 I-frames generate the correct macroblock data (as compared to mplayer via xvmc). Other MPEG2 frames are still misparsed, and MPEG1 I-frames have some errors (but largely match

Re: [Mesa-dev] [PATCH] st/mesa: handle SNORM formats in generic CopyPixels path

2013-06-24 Thread Jose Fonseca
- Original Message - On Mon, Jun 24, 2013 at 6:12 PM, Jose Fonseca jfons...@vmware.com wrote: - Original Message - ---  src/gallium/auxiliary/util/u_format.c     | 14 ++  src/gallium/auxiliary/util/u_format.h     |  3 +++  

Re: [Mesa-dev] [PATCH] st/mesa: handle SNORM formats in generic CopyPixels path

2013-06-24 Thread Marek Olšák
Wouldn't it be easier to just make util_format_description table-based and inline instead of switch-based? Something like: return format PIPE_FORMAT_COUNT ? table[format] : NULL; Marek On Mon, Jun 24, 2013 at 10:12 AM, Jose Fonseca jfons...@vmware.com wrote: - Original Message -

Re: [Mesa-dev] [PATCH] st/mesa: handle SNORM formats in generic CopyPixels path

2013-06-24 Thread Jose Fonseca
Yes, that's a very good idea. The implementation would be fast, furthermore the implementation body would be small, so it could be an inline function in u_format.h, therefore allowing the compiler to coalesce multiple calls too. It implies that the u_format_table.py script needs to parse

Re: [Mesa-dev] [PATCH] r600g/compute: disable unused colorbuffer slots

2013-06-24 Thread Alex Deucher
On Sun, Jun 23, 2013 at 9:31 PM, Marek Olšák mar...@gmail.com wrote: This might fix the lockups caused by colorbuffer flushes and it's generally the right thing to do. Untested. Looks good to me. Reviewed-by: Alex Deucher alexander.deuc...@amd.com ---

[Mesa-dev] [PATCH 1/2] util/debug: Make debug_backtrace_capture work for 64bit windows.

2013-06-24 Thread jfonseca
From: José Fonseca jfons...@vmware.com Rely on Windows' CaptureStackBackTrace to do the grunt work. --- src/gallium/auxiliary/util/u_debug_stack.c | 56 -- src/gallium/auxiliary/util/u_debug_stack.h | 7 2 files changed, 61 insertions(+), 2 deletions(-) diff

[Mesa-dev] [PATCH 2/2] util/debug: Cleanup/improve debug_symbol_name_dbghelp.

2013-06-24 Thread jfonseca
From: José Fonseca jfons...@vmware.com - use mgwhelp -- the successor for bfdhelp which does not have a hard dependency on BFD, and works on 64bits. - use a macro instead of hand-typing to dispatch DbgHelp functions - dump line numbers - dump module names when symbols are not available -

Re: [Mesa-dev] [PATCH 2/2] util/debug: Cleanup/improve debug_symbol_name_dbghelp.

2013-06-24 Thread Brian Paul
On 06/24/2013 06:44 AM, jfons...@vmware.com wrote: From: José Fonseca jfons...@vmware.com - use mgwhelp -- the successor for bfdhelp which does not have a hard dependency on BFD, and works on 64bits. - use a macro instead of hand-typing to dispatch DbgHelp functions - dump line numbers -

Re: [Mesa-dev] [PATCH] vl/mpeg12: implement inverse scan/quantization steps

2013-06-24 Thread Ilia Mirkin
On Mon, Jun 24, 2013 at 4:48 AM, Christian König deathsim...@vodafone.de wrote: Am 23.06.2013 18:59, schrieb Ilia Mirkin: Signed-off-by: Ilia Mirkin imir...@alum.mit.edu --- These changes make MPEG2 I-frames generate the correct macroblock data (as compared to mplayer via xvmc). Other MPEG2

[Mesa-dev] [PATCH] gallium/hud: do not use free() for the free_query_data hook

2013-06-24 Thread Brian Paul
That confuses Gallium's memory debugging code where CALLOC/MALLOC must be matched with FREE, not free(). --- src/gallium/auxiliary/hud/hud_cpu.c | 12 +++- src/gallium/auxiliary/hud/hud_fps.c | 12 +++- src/gallium/auxiliary/hud/hud_private.h |2 +- 3 files

Re: [Mesa-dev] [PATCH] r600g/compute: disable unused colorbuffer slots

2013-06-24 Thread Tom Stellard
On Mon, Jun 24, 2013 at 03:31:50AM +0200, Marek Olšák wrote: This might fix the lockups caused by colorbuffer flushes and it's generally the right thing to do. Untested. Unfortunately, this doesn't fix the lockups on Cayman with VM enabled, but there are no regressions with it, so go ahead and

Re: [Mesa-dev] [PATCH] r600g: Include SH and SMX when invalidating read caches

2013-06-24 Thread Tom Stellard
On Sun, Jun 23, 2013 at 05:56:15PM -0400, Alex Deucher wrote: On Sun, Jun 23, 2013 at 2:24 PM, Marek Olšák mar...@gmail.com wrote: Hi Alex, rctx-framebuffer.state.nr_cbufs might not contain what you think it does, because the framebuffer that needs flushing may have been replaced by a

Re: [Mesa-dev] [PATCH] vl/mpeg12: implement inverse scan/quantization steps

2013-06-24 Thread Christian König
Am 24.06.2013 18:39, schrieb Ilia Mirkin: On Mon, Jun 24, 2013 at 4:48 AM, Christian König deathsim...@vodafone.de wrote: Am 23.06.2013 18:59, schrieb Ilia Mirkin: Signed-off-by: Ilia Mirkin imir...@alum.mit.edu --- These changes make MPEG2 I-frames generate the correct macroblock data (as

[Mesa-dev] [PATCH] i965: Be more careful with the interleaved user array upload optimization

2013-06-24 Thread Ian Romanick
From: Ian Romanick ian.d.roman...@intel.com The checks to determine when the data can be uploaded in an interleaved fashion can be tricked by certain data layouts. For example, float data[...]; glVertexAttribPointer(0, 4, GL_FLOAT, GL_FALSE, 16, data[0]); glVertexAttribPointer(1,

[Mesa-dev] [PATCH 1/2] i965/blorp: Add bilinear filtering of samples for multisample scaled blits

2013-06-24 Thread Anuj Phogat
Current implementation of ext_framebuffer_multisample_blit_scaled in i965/blorp uses nearest filtering for multisample scaled blits. Using nearest filtering produces blocky artifacts and negates the benefits of MSAA. That is the reason why extension was not enabled on i965. This patch implements

Re: [Mesa-dev] [PATCH] r600g/compute: disable unused colorbuffer slots

2013-06-24 Thread Marek Olšák
Does setting R600_CONTEXT_FLUSH_AND_INV after evergreen_emit_direct_dispatch help? I think we should always flush the write caches at the end of CS and invalidate the read caches at the beginning, not the other way around. Marek On Mon, Jun 24, 2013 at 7:25 PM, Tom Stellard t...@stellard.net

Re: [Mesa-dev] [PATCH] gallium/hud: do not use free() for the free_query_data hook

2013-06-24 Thread Marek Olšák
Reviewed-by: Marek Olšák mar...@gmail.com Marek On Mon, Jun 24, 2013 at 6:44 PM, Brian Paul bri...@vmware.com wrote: That confuses Gallium's memory debugging code where CALLOC/MALLOC must be matched with FREE, not free(). --- src/gallium/auxiliary/hud/hud_cpu.c | 12 +++-

Re: [Mesa-dev] [PATCH 4/4] glsl opt_flip_matrices: Silence unused variable warning in the release build

2013-06-24 Thread Ian Romanick
On 06/22/2013 08:43 AM, Emil Velikov wrote: Resolves the following gcc warning opt_flip_matrices.cpp:84:32: warning: unused variable 'deref' Signed-off-by: Emil Velikov emil.l.veli...@gmail.com --- src/glsl/opt_flip_matrices.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)

Re: [Mesa-dev] [PATCH 3/4] glsl ast_to_hir: Silence uninitialized variable warnings in the release build

2013-06-24 Thread Ian Romanick
On 06/22/2013 08:43 AM, Emil Velikov wrote: Resolves the following gcc warnings warning: 'iface_type_name' may be used uninitialized in this function warning: 'var_mode' may be used uninitialized in this function Note: The variables are initialised to UNKNOWN and ir_var_auto

Re: [Mesa-dev] Mesa driver for VirtualBox

2013-06-24 Thread Dave Airlie
Thank you, that looks very interesting. I will need a bit of time to get into the code, but for a start the shader conversion code looks very understandably written. If I turn it into a driver like I described, is it something you would be interested in interfacing to? By the way, is the

[Mesa-dev] [PATCH 1/2] draw: avoid overflows in the llvm draw loop

2013-06-24 Thread Zack Rusin
Before we could easily overflow if start+countmax integer. To avoid it we can just iterate over the count. This makes sure that we never crash, since most of the overflow conditions is already handled. Signed-off-by: Zack Rusin za...@vmware.com --- src/gallium/auxiliary/draw/draw_llvm.c | 14

[Mesa-dev] [PATCH 2/2] draw: allow overflows in the llvm paths

2013-06-24 Thread Zack Rusin
Because our code couldn't handle it we were skipping rendering if we detected overflows. According to the spec we should still render but with all 0 vertices, which is what the llvm code already does. So for the llvm paths lets enable processing even if an overflow condition has been detected.

[Mesa-dev] [PATCH] llvmpipe: rework query logic

2013-06-24 Thread sroland
From: Roland Scheidegger srol...@vmware.com Previously lp_rast_begin_query commands were always inserted into each bin, and re-issued if the scene was restarted, while lp_rast_end_query commands were executed for each still active query at the end of tile rasterization. Also, the ps_invocations

Re: [Mesa-dev] [PATCH 1/2] R600: Add support for i32 loads from the constant address space on Cayman

2013-06-24 Thread Aaron Watry
Tested-By: Aaron Watry awa...@gmail.com Tested on an A6-3500 (SUMO) On Tue, Jun 18, 2013 at 11:54 AM, Tom Stellard t...@stellard.net wrote: From: Tom Stellard thomas.stell...@amd.com --- lib/Target/R600/R600Instructions.td | 9 + test/CodeGen/R600/load.ll | 1 + 2 files

Re: [Mesa-dev] [PATCH 4/4] glsl opt_flip_matrices: Silence unused variable warning in the release build

2013-06-24 Thread Kenneth Graunke
On 06/24/2013 01:22 PM, Ian Romanick wrote: On 06/22/2013 08:43 AM, Emil Velikov wrote: Resolves the following gcc warning opt_flip_matrices.cpp:84:32: warning: unused variable 'deref' Signed-off-by: Emil Velikov emil.l.veli...@gmail.com --- src/glsl/opt_flip_matrices.cpp | 4 ++-- 1

[Mesa-dev] Mesa for Nios ii system

2013-06-24 Thread ZhiLi
Hi there, I am a new user of OpenGL and Nios ii soft processor. Currently, I am working on a project related to OpenGL and Nios ii. For this project, I will implement Nios ii soft core processor on Altera DE2 ( an FPGA board). Then I will compile some OpenGL applications with Nios ii IDE for