Re: [Mesa-dev] [PATCH v4 (part2) 29/59] nir: Implement __intrinsic_store_ssbo

2015-08-07 Thread Iago Toral
On Fri, 2015-08-07 at 07:43 +0200, Iago Toral wrote: > On Thu, 2015-08-06 at 11:06 -0700, Connor Abbott wrote: > > On Thu, Aug 6, 2015 at 12:30 AM, Iago Toral wrote: > > > On Wed, 2015-08-05 at 12:17 -0700, Connor Abbott wrote: > > >> On Wed, Aug 5, 2015 at 1:30 AM, Iago Toral Quiroga > > >> wro

[Mesa-dev] [PATCH v4] clover: stub missing CL 1.2 functions

2015-08-07 Thread Serge Martin (EdB)
As sugested by Tom a long time ago and in order to be able to create Piglit tests v2: replace NOT_SUPPORTED_BY_CL_1_1 macro with an inline function remove extra space in clLinkProgram arg v3: use __func__ v4: back to a macro, it make more sense to use it with __func__ --- src/gallium/state_trac

Re: [Mesa-dev] [PATCH 10/13] hash: Add _mesa_HashRemoveLocked() function.

2015-08-07 Thread Timothy Arceri
On Thu, 2015-08-06 at 17:11 -0700, Matt Turner wrote: > --- > src/mesa/main/hash.c | 19 +++ > src/mesa/main/hash.h | 2 ++ > 2 files changed, 17 insertions(+), 4 deletions(-) > > diff --git a/src/mesa/main/hash.c b/src/mesa/main/hash.c > index 315b5d6..aa1c6a1 100644 > --- a/src

Re: [Mesa-dev] [PATCH 11/13] mesa: Replace uses of Shared->Mutex with hash-table mutexes

2015-08-07 Thread Timothy Arceri
On Thu, 2015-08-06 at 17:11 -0700, Matt Turner wrote: > We were locking the Shared->Mutex and then using calling functions like > _mesa_HashInsert that do additional per-hash-table locking internally. > > Instead just lock each hash-table's mutex and use functions like > _mesa_HashInsertLocked and

Re: [Mesa-dev] [PATCH 00/13] mesa: Locking improvements and optimizations

2015-08-07 Thread Timothy Arceri
On Thu, 2015-08-06 at 17:10 -0700, Matt Turner wrote: > Patches 1-11 improve performance of SynMark OglBatch7 by 6.29586% +/- > 0.277734% > (n=337) and OglMultithread by 1.12564% +/- 0.424038% (n=209). I haven't > benchmarked individual patches because I'd like to not waste all that time > if I >

Re: [Mesa-dev] [PATCH v2] gles/es3.1: Implement glMemoryBarrierByRegion

2015-08-07 Thread Tapani Pälli
Super, I've verified that this makes ES31-CTS.shader_image_load_store.basic-api-barrier-byRegion pass with one of Curro's branches. Reviewed-by: Tapani Pälli On 08/04/2015 11:22 AM, Marta Lofstedt wrote: From: Marta Lofstedt Signed-off-by: Marta Lofstedt --- src/mapi/glapi/gen/gl_API.xm

Re: [Mesa-dev] [PATCH v4 (part2) 02/59] i965/vec4: Import helpers to convert vectors into arrays and back.

2015-08-07 Thread Iago Toral
On Wed, 2015-08-05 at 10:29 +0200, Iago Toral Quiroga wrote: > From: Francisco Jerez > > These functions handle the conversion of a vec4 into the form expected > by the dataport unit in message and message return payloads. The > conversion is not always trivial because some messages don't suppor

Re: [Mesa-dev] [PATCH v4 (part2) 02/59] i965/vec4: Import helpers to convert vectors into arrays and back.

2015-08-07 Thread Francisco Jerez
Iago Toral writes: > On Wed, 2015-08-05 at 10:29 +0200, Iago Toral Quiroga wrote: >> From: Francisco Jerez >> >> These functions handle the conversion of a vec4 into the form expected >> by the dataport unit in message and message return payloads. The >> conversion is not always trivial becaus

Re: [Mesa-dev] driDriverAPI help

2015-08-07 Thread Marek Olšák
Hi, All Gallium drivers use this directory, because it contains some common driver loader code: src/mesa/drivers/dri/common Marek On Wed, Aug 5, 2015 at 3:24 PM, Daniel Melo Jorge da Cunha wrote: > Yes, yes... I know this is an expert group but I searched the whole web, > sent a few > emails a

[Mesa-dev] [Bug 28130] vbo: premature flushing breaks GL_LINE_LOOP

2015-08-07 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=28130 Marek Olšák changed: What|Removed |Added QA Contact|marius.pre...@intel.com |mesa-dev@lists.freedesktop.

Re: [Mesa-dev] driDriverAPI help

2015-08-07 Thread Emil Velikov
On 7 August 2015 at 11:54, Marek Olšák wrote: > Hi, > > All Gallium drivers use this directory, because it contains some > common driver loader code: > src/mesa/drivers/dri/common > To prevent any possible confusion - all gallium DRI drivers. Other drivers such as vdpau/opencl/etc do not use it.

Re: [Mesa-dev] [PATCH v3 4/4] i965/vec4: Don't unspill the same register in consecutive instructions

2015-08-07 Thread Francisco Jerez
Iago Toral writes: > On Thu, 2015-08-06 at 18:27 +0300, Francisco Jerez wrote: >> Iago Toral Quiroga writes: >> >> > If we have spilled/unspilled a register in the current instruction, avoid >> > emitting unspills for the same register in the same instruction or >> > consecutive >> > instructi

Re: [Mesa-dev] [PATCH v3 4/4] i965/vec4: Don't unspill the same register in consecutive instructions

2015-08-07 Thread Iago Toral
On Fri, 2015-08-07 at 14:14 +0300, Francisco Jerez wrote: > Iago Toral writes: > > > On Thu, 2015-08-06 at 18:27 +0300, Francisco Jerez wrote: > >> Iago Toral Quiroga writes: > >> > >> > If we have spilled/unspilled a register in the current instruction, avoid > >> > emitting unspills for the s

Re: [Mesa-dev] [PATCH v4] clover: stub missing CL 1.2 functions

2015-08-07 Thread Francisco Jerez
"Serge Martin (EdB)" writes: > As sugested by Tom a long time ago > and in order to be able to create Piglit tests > > v2: > replace NOT_SUPPORTED_BY_CL_1_1 macro with an inline function > remove extra space in clLinkProgram arg > > v3: > use __func__ > > v4: > back to a macro, it make more sense

Re: [Mesa-dev] [PATCH v4] clover: stub missing CL 1.2 functions

2015-08-07 Thread Serge Martin
On Friday 07 August 2015 14:45:56 Francisco Jerez wrote: > "Serge Martin (EdB)" writes: > > As sugested by Tom a long time ago > > and in order to be able to create Piglit tests > > > > v2: > > replace NOT_SUPPORTED_BY_CL_1_1 macro with an inline function > > remove extra space in clLinkProgram a

[Mesa-dev] clover: image resource management

2015-08-07 Thread Zoltán Gilián
Hi! I've noticed that clover::kernel::image_wr_argument::unbind destroys the surface. What kind of behaviour is expected from the driver to allow later access to the resource (e.g. by clEnqueueReadImage)? Zoltan ___ mesa-dev mailing list mesa-dev@lists.

Re: [Mesa-dev] clover: image resource management

2015-08-07 Thread Francisco Jerez
Zoltán Gilián writes: > Hi! > > I've noticed that clover::kernel::image_wr_argument::unbind destroys > the surface. What kind of behaviour is expected from the driver to > allow later access to the resource (e.g. by clEnqueueReadImage)? It only destroys the cached view into the image, of course

[Mesa-dev] [PATCH] util: Rename PURE to ATTRIBUTE_PURE.

2015-08-07 Thread Jose Fonseca
To avoid collission with windows.h's PURE macro. We could consider eventually renaming to __pure, but that would require further care, so it's left to the future. --- src/util/macros.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/util/macros.h b/src/util/macros.h in

Re: [Mesa-dev] [Intel-gfx] [PATCH libdrm v3 1/2] intel: Add EXEC_OBJECT_SUPPORTS_48B_ADDRESS flag

2015-08-07 Thread Michel Thierry
On 8/7/2015 11:56 AM, Michał Winiarski wrote: On Fri, Aug 07, 2015 at 10:45:21AM +0100, Michel Thierry wrote: Gen8+ supports 48-bit virtual addresses, but some objects must always be allocated inside the 32-bit address range. In specific, any resource used with flat/heapless (0x-0xf

[Mesa-dev] [PATCH mesa v3] i965/gen8+: bo in state base address must be in 32-bit address range

2015-08-07 Thread Michel Thierry
Gen8+ supports 48-bit virtual addresses, but some objects must always be allocated inside the 32-bit address range. In specific, any resource used with flat/heapless (0x-0xf000) General State Heap or Intruction State Heap must be in a 32-bit range (GSH / ISH), because the General State

[Mesa-dev] [PATCH libdrm v3 1/2] intel: Add EXEC_OBJECT_SUPPORTS_48B_ADDRESS flag

2015-08-07 Thread Michel Thierry
Gen8+ supports 48-bit virtual addresses, but some objects must always be allocated inside the 32-bit address range. In specific, any resource used with flat/heapless (0x-0xf000) General State Heap (GSH) or Instruction State Heap (ISH) must be in a 32-bit range, because the General Stat

Re: [Mesa-dev] [Intel-gfx] [PATCH libdrm v3 1/2] intel: Add EXEC_OBJECT_SUPPORTS_48B_ADDRESS flag

2015-08-07 Thread Michał Winiarski
On Fri, Aug 07, 2015 at 10:45:21AM +0100, Michel Thierry wrote: > Gen8+ supports 48-bit virtual addresses, but some objects must always be > allocated inside the 32-bit address range. > > In specific, any resource used with flat/heapless (0x-0xf000) > General State Heap (GSH) or Instru

[Mesa-dev] [PATCH libdrm v3 2/2] intel: add new function name to symbol-check test

2015-08-07 Thread Michel Thierry
Signed-off-by: Michel Thierry --- intel/intel-symbol-check | 1 + 1 file changed, 1 insertion(+) diff --git a/intel/intel-symbol-check b/intel/intel-symbol-check index c555e6d..6f8450b 100755 --- a/intel/intel-symbol-check +++ b/intel/intel-symbol-check @@ -18,6 +18,7 @@ drm_intel_bo_busy drm_i

[Mesa-dev] [PATCH libdrm v3 0/2] 48-bit virtual address support in i915

2015-08-07 Thread Michel Thierry
48-bit virtual address range will be enabled in i915 soon, but some objects must be referenced by 32-bit offsets. These patches use a new kernel flag to specify if this restriction applies or not. I'm sending these patches to comply with the i915 merge process. Once the kernel patch is merged, I'l

[Mesa-dev] [RFC libdrm] intel: 48b ppgtt support

2015-08-07 Thread Michał Winiarski
--- include/drm/i915_drm.h| 3 ++- intel/intel_bufmgr.c | 11 +++ intel/intel_bufmgr.h | 1 + intel/intel_bufmgr_gem.c | 43 +-- intel/intel_bufmgr_priv.h | 8 5 files changed, 55 insertions(+), 11 deletions(-) diff --git

Re: [Mesa-dev] [PATCH] util: Rename PURE to ATTRIBUTE_PURE.

2015-08-07 Thread Brian Paul
On 08/07/2015 06:10 AM, Jose Fonseca wrote: To avoid collission with windows.h's PURE macro. We could consider eventually renaming to __pure, but that would require further care, so it's left to the future. --- src/util/macros.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff

Re: [Mesa-dev] [PATCH 3/4] tnl: Maintain the _WindowMap matrix in TNLcontext v2.

2015-08-07 Thread Ilia Mirkin
On Fri, Aug 7, 2015 at 2:46 AM, Mathias Fröhlich wrote: > > > Hi, > > > > On Thursday, August 06, 2015 12:32:18 Ilia Mirkin wrote: > > > > @@ -182,6 +187,13 @@ _tnl_InvalidateState( struct gl_context *ctx, > GLuint new_state ) > > > > } > > > > } > > > > } > > > > + > > > > + if (new_state & (_NE

[Mesa-dev] New stable-branch 10.6 candidate pushed

2015-08-07 Thread Emil Velikov
Hello list, The candidate for the Mesa 10.6.4 is now available. Currently we have: - 29 queued - 22 nominated (outstanding) - and 2 rejected/obsolete patches The series covers quite a wide range of issues, but it's mostly consentrated around the GL implementation - both dri drivers and the EG

[Mesa-dev] [Bug 90264] [Regression, bisected] Tooltip corruption in Chrome

2015-08-07 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=90264 --- Comment #45 from Chris Wilson --- Alternatively, diff --git a/src/glx/dri2_glx.c b/src/glx/dri2_glx.c index 5767026..01b5c28 100644 --- a/src/glx/dri2_glx.c +++ b/src/glx/dri2_glx.c @@ -656,6 +656,8 @@ dri2_wait_x(struct glx_context *gc)

Re: [Mesa-dev] [PATCH 3/4] tnl: Maintain the _WindowMap matrix in TNLcontext v2.

2015-08-07 Thread Mathias Fröhlich
Hi, On Friday, August 07, 2015 10:28:10 Ilia Mirkin wrote: > > One alternative I can see is to call _tnl_InvalidateState without the > > _NEW_VIEWPORT and > > > > _NEW_BUFFERS flag set instead of _tnl_wakeup in the two nouveau early > > initialization > > > > code paths in nouveau_swtnl_t.c and nv

Re: [Mesa-dev] [PATCH 3/4] tnl: Maintain the _WindowMap matrix in TNLcontext v2.

2015-08-07 Thread Ilia Mirkin
On Fri, Aug 7, 2015 at 11:07 AM, Mathias Fröhlich wrote: > > > Hi, > > > > On Friday, August 07, 2015 10:28:10 Ilia Mirkin wrote: > > > > One alternative I can see is to call _tnl_InvalidateState without the > > > > _NEW_VIEWPORT and > > > > > > > > _NEW_BUFFERS flag set instead of _tnl_wakeup in

Re: [Mesa-dev] [PATCH 10/13] hash: Add _mesa_HashRemoveLocked() function.

2015-08-07 Thread Brian Paul
On 08/06/2015 06:11 PM, Matt Turner wrote: --- src/mesa/main/hash.c | 19 +++ src/mesa/main/hash.h | 2 ++ 2 files changed, 17 insertions(+), 4 deletions(-) diff --git a/src/mesa/main/hash.c b/src/mesa/main/hash.c index 315b5d6..aa1c6a1 100644 --- a/src/mesa/main/hash.c +++

Re: [Mesa-dev] [PATCH 12/13] mesa: Remove unnecessary locking from container objects.

2015-08-07 Thread Brian Paul
On 08/06/2015 06:11 PM, Matt Turner wrote: "Container objects" like vertex array objects, framebuffer objects, and pipeline objects are not shared between contexts, so they require no locking. Framebuffer/renderbuffer objects _are_ shared among contexts. Note that _mesa_lookup_framebuffer() a

Re: [Mesa-dev] [PATCH 00/13] mesa: Locking improvements and optimizations

2015-08-07 Thread Brian Paul
On 08/06/2015 06:10 PM, Matt Turner wrote: Patches 1-11 improve performance of SynMark OglBatch7 by 6.29586% +/- 0.277734% (n=337) and OglMultithread by 1.12564% +/- 0.424038% (n=209). I haven't benchmarked individual patches because I'd like to not waste all that time if I get review feedback th

Re: [Mesa-dev] [PATCH 3/4] tnl: Maintain the _WindowMap matrix in TNLcontext v2.

2015-08-07 Thread Brian Paul
On 08/07/2015 08:28 AM, Ilia Mirkin wrote: On Fri, Aug 7, 2015 at 2:46 AM, Mathias Fröhlich mailto:mathias.froehl...@gmx.net>> wrote: __ Hi, On Thursday, August 06, 2015 12:32:18 Ilia Mirkin wrote: > > @@ -182,6 +187,13 @@ _tnl_InvalidateState( struct gl_context *ctx, GLuint

[Mesa-dev] [Bug 90264] [Regression, bisected] Tooltip corruption in Chrome

2015-08-07 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=90264 --- Comment #46 from Furkan --- I've tested both patches (#40 and #45) and they both seem to work for me. -- You are receiving this mail because: You are the QA Contact for the bug. You are the assignee for the bug.

Re: [Mesa-dev] [PATCH 3/4] tnl: Maintain the _WindowMap matrix in TNLcontext v2.

2015-08-07 Thread Mathias Fröhlich
Ilia, On Friday, August 07, 2015 11:20:42 Ilia Mirkin wrote: > Yeah, I tend to agree with you -- it seems like _tnl_wakeup is meant for > "oh hey, I shut you down and haven't been sending you updates, but I want > to use you again, so please update your stuff to match reality". Does it > even need

Re: [Mesa-dev] [PATCH 3/4] tnl: Maintain the _WindowMap matrix in TNLcontext v2.

2015-08-07 Thread Ilia Mirkin
On Fri, Aug 7, 2015 at 12:03 PM, Mathias Fröhlich wrote: > > > Ilia, > > > > On Friday, August 07, 2015 11:20:42 Ilia Mirkin wrote: > > > Yeah, I tend to agree with you -- it seems like _tnl_wakeup is meant for > > > "oh hey, I shut you down and haven't been sending you updates, but I want > > >

[Mesa-dev] [PATCH 1/2] nir: Add a function to determine if a source is dynamically uniform

2015-08-07 Thread Neil Roberts
Adds nir_src_is_dynamically_uniform which returns true if the source is known to be dynamically uniform. This will be used in a later patch to add a workaround for cases that only work with dynamically uniform sources. Note that the function is not definitive, it can return false negatives (but not

[Mesa-dev] [PATCH v2 2/2] i965/fs: Handle non-const sample number in interpolateAtSample

2015-08-07 Thread Neil Roberts
If a non-const sample number is given to interpolateAtSample it will now generate an indirect send message with the sample ID similar to how non-const sampler array indexing works. Previously non-const values were ignored and instead it ended up using a constant 0 value. The generator will try to

Re: [Mesa-dev] [PATCH 05/13] mesa: Replace buffer object locks with atomic inc/dec.

2015-08-07 Thread Ian Romanick
So... the buffer object isn't locked during a call to glBufferData? Since that allocates the backing storage for the BO, it doesn't seem like anything good could happen... On 08/06/2015 05:10 PM, Matt Turner wrote: > --- > src/mesa/main/bufferobj.c | 17 +++-- > src/mesa/main/mtypes.h

Re: [Mesa-dev] [PATCH 12/13] mesa: Remove unnecessary locking from container objects.

2015-08-07 Thread Fredrik Höglund
On Friday 07 August 2015, Matt Turner wrote: > "Container objects" like vertex array objects, framebuffer objects, and > pipeline objects are not shared between contexts, so they require no > locking. Unfortunately it's not quite that simple when it comes to FBO's; EXT_framebuffer_object defines F

Re: [Mesa-dev] [PATCH 12/13] mesa: Remove unnecessary locking from container objects.

2015-08-07 Thread Ian Romanick
On 08/06/2015 05:11 PM, Matt Turner wrote: > "Container objects" like vertex array objects, framebuffer objects, and > pipeline objects are not shared between contexts, so they require no > locking. Yes and no. FBOs from EXT_framebuffer_object and VAOs from APPLE_vertex_array_object are shared be

Re: [Mesa-dev] [PATCH 12/13] mesa: Remove unnecessary locking from container objects.

2015-08-07 Thread Ian Romanick
On 08/07/2015 09:50 AM, Fredrik Höglund wrote: > On Friday 07 August 2015, Matt Turner wrote: >> "Container objects" like vertex array objects, framebuffer objects, and >> pipeline objects are not shared between contexts, so they require no >> locking. > > Unfortunately it's not quite that simple

Re: [Mesa-dev] [PATCH v4 (part2) 29/59] nir: Implement __intrinsic_store_ssbo

2015-08-07 Thread Connor Abbott
On Fri, Aug 7, 2015 at 1:15 AM, Iago Toral wrote: > On Fri, 2015-08-07 at 07:43 +0200, Iago Toral wrote: >> On Thu, 2015-08-06 at 11:06 -0700, Connor Abbott wrote: >> > On Thu, Aug 6, 2015 at 12:30 AM, Iago Toral wrote: >> > > On Wed, 2015-08-05 at 12:17 -0700, Connor Abbott wrote: >> > >> On Wed

Re: [Mesa-dev] [PATCH 06/13] mesa: Replace sampler object locks with atomic inc/dec.

2015-08-07 Thread Ian Romanick
I know we've talked about this about 100 times, but something in the back of my mind tells me that we have a pre-existing race. What happens if the p_atomic_dec_zero happens on thread A while thread B is between the _mesa_lookup_renderbuffer call and the _mesa_reference_renderbuffer call on the sa

Re: [Mesa-dev] [PATCH 10/13] hash: Add _mesa_HashRemoveLocked() function.

2015-08-07 Thread Matt Turner
On Fri, Aug 7, 2015 at 1:57 AM, Timothy Arceri wrote: > On Thu, 2015-08-06 at 17:11 -0700, Matt Turner wrote: >> --- >> src/mesa/main/hash.c | 19 +++ >> src/mesa/main/hash.h | 2 ++ >> 2 files changed, 17 insertions(+), 4 deletions(-) >> >> diff --git a/src/mesa/main/hash.c b/sr

Re: [Mesa-dev] [PATCH 10/13] hash: Add _mesa_HashRemoveLocked() function.

2015-08-07 Thread Matt Turner
On Fri, Aug 7, 2015 at 8:43 AM, Brian Paul wrote: > On 08/06/2015 06:11 PM, Matt Turner wrote: >> >> --- >> src/mesa/main/hash.c | 19 +++ >> src/mesa/main/hash.h | 2 ++ >> 2 files changed, 17 insertions(+), 4 deletions(-) >> >> diff --git a/src/mesa/main/hash.c b/src/mesa/ma

Re: [Mesa-dev] [PATCH 11/13] mesa: Replace uses of Shared->Mutex with hash-table mutexes

2015-08-07 Thread Matt Turner
On Fri, Aug 7, 2015 at 2:09 AM, Timothy Arceri wrote: > On Thu, 2015-08-06 at 17:11 -0700, Matt Turner wrote: >> We were locking the Shared->Mutex and then using calling functions like >> _mesa_HashInsert that do additional per-hash-table locking internally. >> >> Instead just lock each hash-table

Re: [Mesa-dev] [PATCH v2 1/3] egl/x11: fix use of EGL_BAD_NATIVE_WINDOW

2015-08-07 Thread Emil Velikov
On 4 August 2015 at 14:32, Frank Binns wrote: > Commit 4ed23fd590 introduced some calls to _eglError inappropriately > passing it EGL_BAD_NATIVE_WINDOW. This was actually harmless in two of the > cases as _eglError gets called later on with a more appropriate error code > but (just to be safe) swi

Re: [Mesa-dev] [PATCH v2 2/3] egl/x11: set EGL_BAD_NATIVE_(PIXMAP|WINDOW) for invalid pixmaps/windows

2015-08-07 Thread Emil Velikov
On 4 August 2015 at 14:32, Frank Binns wrote: > Both eglCreatePixmapSurface and eglCreateWindowSurface were incorrectly > setting the EGL error to be EGL_BAD_ALLOC when an invalid native drawable > handle was being passed in. The EGL spec states the following for > eglCreatePixmapSurface: > >

Re: [Mesa-dev] [Mesa-stable] [PATCH v2 3/3] egl/x11: don't abort when creating a DRI2 drawable fails

2015-08-07 Thread Emil Velikov
On 4 August 2015 at 14:32, Frank Binns wrote: > When calling either eglCreateWindowSurface or eglCreatePixmapSurface it > was possible for an application to be aborted as a result of it failing > to create a DRI2 drawable on the server. This could happen due to an > application passing in an inval

Re: [Mesa-dev] [PATCH v3 1/2] mesa: clear existing swizzle info before bitwise-OR

2015-08-07 Thread Emil Velikov
On 4 August 2015 at 19:39, Oded Gabbay wrote: > This patch fixes a bug in big-endian treatment, where the previous > swizzle info wasn't cleared before a new swizzle info was inserted into > the format field using a bitwise-OR operation. > > v2: use MESA_ARRAY_FORMAT_SWIZZLE_*_MASK instead of nume

Re: [Mesa-dev] [PATCH 2/2] mesa: _mesa_format_convert should be endian agnostic

2015-08-07 Thread Emil Velikov
On 4 August 2015 at 17:57, Oded Gabbay wrote: > > > On Mon, Aug 3, 2015 at 6:40 PM, Emil Velikov > wrote: > >> Hi Oded, >> >> On 2 August 2015 at 11:37, Oded Gabbay wrote: >> > This patch fixes a bug that is manifested in the read path of mesa when >> > running on big-endian machines. The effec

Re: [Mesa-dev] [PATCH 2/2] mesa: _mesa_format_convert should be endian agnostic

2015-08-07 Thread Emil Velikov
Hi Christian, On 4 August 2015 at 08:23, Christian Zigotzky wrote: > Hi All, > > I know the false colors problems. Some Linux programs appear to be ABGR > instead of RGBA, thus green becomes purple, red becomes light blue etc. > > I created a bug report on freedesktop.org. Bug report 72877: > htt

Re: [Mesa-dev] [PATCH 1/5] utils: automake: remove uncommon $()

2015-08-07 Thread Emil Velikov
On 21 July 2015 at 13:12, Emil Velikov wrote: > On 20/07/15 21:25, Chad Versace wrote: >> On Fri 17 Jul 2015, Emil Velikov wrote: >>> On 17 July 2015 at 19:11, Ilia Mirkin wrote: On Fri, Jul 17, 2015 at 2:11 PM, Eric Anholt wrote: > Matt Turner writes: > >> On Fri, Jul 17, 2015

Re: [Mesa-dev] [PATCH 10/13] hash: Add _mesa_HashRemoveLocked() function.

2015-08-07 Thread Brian Paul
On 08/07/2015 11:33 AM, Matt Turner wrote: On Fri, Aug 7, 2015 at 8:43 AM, Brian Paul wrote: On 08/06/2015 06:11 PM, Matt Turner wrote: --- src/mesa/main/hash.c | 19 +++ src/mesa/main/hash.h | 2 ++ 2 files changed, 17 insertions(+), 4 deletions(-) diff --git a/src/m

Re: [Mesa-dev] [PATCH v2] gles/es3.1: Implement glMemoryBarrierByRegion

2015-08-07 Thread Matt Turner
On Tue, Aug 4, 2015 at 1:22 AM, Marta Lofstedt wrote: > From: Marta Lofstedt > > Signed-off-by: Marta Lofstedt > --- > src/mapi/glapi/gen/gl_API.xml | 4 > src/mesa/main/shaderimage.c | 40 > + > src/mesa/main/shaderimage.h

Re: [Mesa-dev] [PATCH 1/5] utils: automake: remove uncommon $()

2015-08-07 Thread Matt Turner
On Fri, Aug 7, 2015 at 11:05 AM, Emil Velikov wrote: > On 21 July 2015 at 13:12, Emil Velikov wrote: >> On 20/07/15 21:25, Chad Versace wrote: >>> On Fri 17 Jul 2015, Emil Velikov wrote: On 17 July 2015 at 19:11, Ilia Mirkin wrote: > On Fri, Jul 17, 2015 at 2:11 PM, Eric Anholt wrote:

[Mesa-dev] [PATCH 1/2] egl/dri2: Fix include path of u_atomic.h introduced e7e29189

2015-08-07 Thread Alexander von Gluck IV
This was causing a failure to build on SCons due to a missing -Isrc/egl. Instead of adding in that path, lets just -Isrc/ and include "utils/u_atomic.h". --- src/egl/Makefile.am | 1 + src/egl/SConscript | 1 + src/egl/drivers/dri2/egl_dri2.c | 2 +- 3 files changed, 3 ins

[Mesa-dev] [PATCH 2/2] egl/scons: Fix every platform getting dri and haiku added e7e29189

2015-08-07 Thread Alexander von Gluck IV
--- src/egl/SConscript | 17 ++--- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/src/egl/SConscript b/src/egl/SConscript index 1b2a427..00761e8 100644 --- a/src/egl/SConscript +++ b/src/egl/SConscript @@ -15,14 +15,17 @@ env.Append(CPPPATH = [ # parse Makefile.sourc

Re: [Mesa-dev] [PATCH 1/2] egl/dri2: Fix include path of u_atomic.h introduced e7e29189

2015-08-07 Thread Matt Turner
On Fri, Aug 7, 2015 at 11:19 AM, Alexander von Gluck IV wrote: > This was causing a failure to build on SCons due to a missing > -Isrc/egl. Instead of adding in that path, lets just -Isrc/ > and include "utils/u_atomic.h". > --- Reviewed-by: Matt Turner __

Re: [Mesa-dev] [Intel-gfx] [PATCH mesa v3] i965/gen8+: bo in state base address must be in 32-bit address range

2015-08-07 Thread Matt Turner
On Fri, Aug 7, 2015 at 2:45 AM, Michel Thierry wrote: > diff --git a/src/mesa/drivers/dri/i965/intel_batchbuffer.c > b/src/mesa/drivers/dri/i965/intel_batchbuffer.c > index 54081a1..ca90784 100644 > --- a/src/mesa/drivers/dri/i965/intel_batchbuffer.c > +++ b/src/mesa/drivers/dri/i965/intel_batchb

[Mesa-dev] [PATCH] clover: Properly initialize LLVM targets when linking with component libs

2015-08-07 Thread Tom Stellard
Calls to LLVMIntialize* fail when we are linking against individual component libraries rather than one large shared object, because we only include component libraries that are required by the drivers. We need to make sure to only initialize the targets that we need. CC: 10.6 --- configure.ac

Re: [Mesa-dev] [PATCH 2/2] mesa: _mesa_format_convert should be endian agnostic

2015-08-07 Thread Oded Gabbay
On Fri, Aug 7, 2015 at 8:55 PM, Emil Velikov wrote: > On 4 August 2015 at 17:57, Oded Gabbay wrote: >> >> >> >> On Mon, Aug 3, 2015 at 6:40 PM, Emil Velikov >> wrote: >>> >>> Hi Oded, >>> >>> On 2 August 2015 at 11:37, Oded Gabbay wrote: >>> > This patch fixes a bug that is manifested in the re

[Mesa-dev] [PATCH v2 2/2] mesa: _mesa_format_convert should be endian agnostic

2015-08-07 Thread Oded Gabbay
This patch fixes a bug that is manifested in the read path of mesa when running on big-endian machines. The effects can be seen when running piglit sanity test and/or taking a screen capture. The bug is caused when _mesa_format_convert receives src_format as mesa_format, which it thens changes to

Re: [Mesa-dev] [PATCH v2 2/2] mesa: _mesa_format_convert should be endian agnostic

2015-08-07 Thread Matt Turner
On Fri, Aug 7, 2015 at 12:24 PM, Oded Gabbay wrote: > This patch fixes a bug that is manifested in the read path of mesa when > running on big-endian machines. The effects can be seen when running > piglit sanity test and/or taking a screen capture. > > The bug is caused when _mesa_format_convert

Re: [Mesa-dev] [PATCH v2 2/2] mesa: _mesa_format_convert should be endian agnostic

2015-08-07 Thread Oded Gabbay
On Fri, Aug 7, 2015 at 10:30 PM, Matt Turner wrote: > On Fri, Aug 7, 2015 at 12:24 PM, Oded Gabbay wrote: >> This patch fixes a bug that is manifested in the read path of mesa when >> running on big-endian machines. The effects can be seen when running >> piglit sanity test and/or taking a screen

Re: [Mesa-dev] [PATCH 1/2] egl/dri2: Fix include path of u_atomic.h introduced e7e29189

2015-08-07 Thread Emil Velikov
On 07/08/15 19:19, Alexander von Gluck IV wrote: > This was causing a failure to build on SCons due to a missing > -Isrc/egl. Instead of adding in that path, lets just -Isrc/ > and include "utils/u_atomic.h". Hmm nice one! Before the commit dri2 wasn't attempted on Haiku. With the patch one, I've

Re: [Mesa-dev] [PATCH 2/2] egl/scons: Fix every platform getting dri and haiku added e7e29189

2015-08-07 Thread Emil Velikov
Ouch seems like a git rebase slip, as I was nuking the final dri scons target around the same time. On 07/08/15 19:19, Alexander von Gluck IV wrote:> --- > src/egl/SConscript | 17 ++--- > 1 file changed, 10 insertions(+), 7 deletions(-) > > diff --git a/src/egl/SConscript b/src/egl/

Re: [Mesa-dev] [PATCH v2] gles/es3.1: Implement glMemoryBarrierByRegion

2015-08-07 Thread Ilia Mirkin
On Fri, Aug 7, 2015 at 2:18 PM, Matt Turner wrote: > On Tue, Aug 4, 2015 at 1:22 AM, Marta Lofstedt > wrote: >> From: Marta Lofstedt >> >> Signed-off-by: Marta Lofstedt >> --- >> src/mapi/glapi/gen/gl_API.xml | 4 >> src/mesa/main/shaderimage.c | 40 >>

Re: [Mesa-dev] [PATCH 2/2] egl/scons: Fix every platform getting dri and haiku added e7e29189

2015-08-07 Thread Alexander von Gluck IV
On 2015-08-07 14:49, Emil Velikov wrote: Ouch seems like a git rebase slip, as I was nuking the final dri scons target around the same time. On 07/08/15 19:19, Alexander von Gluck IV wrote:> --- src/egl/SConscript | 17 ++--- 1 file changed, 10 insertions(+), 7 deletions(-) diff -

Re: [Mesa-dev] [PATCH mesa v3] i965/gen8+: bo in state base address must be in 32-bit address range

2015-08-07 Thread Ilia Mirkin
On Fri, Aug 7, 2015 at 5:45 AM, Michel Thierry wrote: > Gen8+ supports 48-bit virtual addresses, but some objects must always be > allocated inside the 32-bit address range. > > In specific, any resource used with flat/heapless (0x-0xf000) > General State Heap or Intruction State Heap

Re: [Mesa-dev] [PATCH 2/2] egl/scons: Fix every platform getting dri and haiku added e7e29189

2015-08-07 Thread Emil Velikov
On 7 August 2015 at 20:56, Alexander von Gluck IV wrote: > On 2015-08-07 14:49, Emil Velikov wrote: >> >> Ouch seems like a git rebase slip, as I was nuking the final dri scons >> target around the same time. >> >> On 07/08/15 19:19, Alexander von Gluck IV wrote:> --- >>> >>> src/egl/SConscript |

[Mesa-dev] [PATCH 02/70] i965: Pack read-only booleans into a bitfield

2015-08-07 Thread Chris Wilson
GCC's read access for single bits in a bitfield is reasonable (just a move + flag comparison), so let's save some cachelines by packing the write-once/read-many booleans together. textdata bss dec hex filename 6490134 191992 26192 6708318 665c5e lib64/i965_dri.so 6491766 19

[Mesa-dev] [PATCH 01/70] util/list: Add convenience functions for moving a list element

2015-08-07 Thread Chris Wilson
Just a couple of functions for removing an element from one list and adding to another (perhaps even the same list, just at the head or tail). Used in future patches. Signed-off-by: Chris Wilson --- src/util/list.h | 27 +-- 1 file changed, 21 insertions(+), 6 deletions(

[Mesa-dev] i965: Context-local batch manager

2015-08-07 Thread Chris Wilson
A new round for brw_batch.c now with lots and lots of baby steps painstakingly individually tested. Please tear to shreds. -Chris ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev

[Mesa-dev] [PATCH 11/70] i965: Move struct intel_batchbuffer from brw_context.h to brw_batch.h

2015-08-07 Thread Chris Wilson
To ease future transitions. Signed-off-by: Chris Wilson --- src/mesa/drivers/dri/i965/brw_batch.h | 31 +++ src/mesa/drivers/dri/i965/brw_context.h | 31 --- 2 files changed, 31 insertions(+), 31 deletions(-) diff --git a/src/mesa/driver

[Mesa-dev] [PATCH 12/70] i965: Rename intel_batchbuffer to brw_batch

2015-08-07 Thread Chris Wilson
In order to reduce future churn, rename the intel_batchbuffer struct. Signed-off-by: Chris Wilson --- src/mesa/drivers/dri/i965/brw_batch.h | 4 ++-- src/mesa/drivers/dri/i965/brw_context.h | 2 +- src/mesa/drivers/dri/i965/brw_state_batch.c | 6 ++ src/mesa/drivers/dri/i965/

[Mesa-dev] [PATCH 10/70] i965: Subsitute drm_intel_bo with a local name, brw_bo

2015-08-07 Thread Chris Wilson
In preparation for a local batch manager with a new buffer object, first reduce the churn by renaming the existing buffer objects: s/drm_intel_bo/brw_bo/ We only have to be careful to leave the global screen drm_intel_bo as they are. Signed-off-by: Chris Wilson --- src/mesa/drivers/dri/i965/Mak

[Mesa-dev] [PATCH 05/70] i965: Move the pipelined test for SO register access to the screen

2015-08-07 Thread Chris Wilson
Moving the test to the screen places it alongside the other global HW feature tesst that want to be shared between contexts. Signed-off-by: Chris Wilson Cc: Kenneth Graunke --- src/mesa/drivers/dri/i965/brw_context.c | 2 + src/mesa/drivers/dri/i965/intel_extensions.c | 69 ---

[Mesa-dev] [PATCH 08/70] i965: Remove early release of DRI2 miptree

2015-08-07 Thread Chris Wilson
intel_update_winsys_renderbuffer_miptree() will release the existing miptree when wrapping a new DRI2 buffer, so we can remove the early release and so prevent a NULL mt dereference should importing the new DRI2 name fail for any reason. (Reusing the old DRI2 name will result in the rendering going

[Mesa-dev] [PATCH 07/70] i965: Combine the multiple pipelined register detection into one round-trip

2015-08-07 Thread Chris Wilson
Combining the multiple access checks into a few batches and a single serialising read can reduce detection times from around 100us to 70us on a fast Haswell system. Signed-off-by: Chris Wilson Cc: Kenneth Graunke --- src/mesa/drivers/dri/i965/intel_screen.c | 165 +++

[Mesa-dev] [PATCH 13/70] i965: Add a couple of utility functions to ref/unref a brw_bo

2015-08-07 Thread Chris Wilson
To further reduce churn when replacing the buffer object implementation, wrap the existing drm_intel_bo_reference/drm_intel_bo_unreference. Signed-off-by: Chris Wilson --- src/mesa/drivers/dri/i965/brw_batch.h | 12 +++ src/mesa/drivers/dri/i965/brw_context.c| 25

[Mesa-dev] [PATCH 06/70] i965: Move the OACONTROL pipelined access check from context to screen

2015-08-07 Thread Chris Wilson
Similarly to the pipelined SO_OFFSET check, this moves the global HW compatability check to the screen next to the other global checks. Signed-off-by: Chris Wilson --- src/mesa/drivers/dri/i965/intel_extensions.c | 68 +--- src/mesa/drivers/dri/i965/intel_screen.c | 1

[Mesa-dev] [PATCH 04/70] i965: Share the workaround bo between all contexts

2015-08-07 Thread Chris Wilson
Since the workaround bo is used strictly as a write-only buffer, we need only allocate one per screen and use the same one from all contexts. (The caveat here is during extension initialisation, where we write into and read back register values from the buffer, but that is performed only once for

[Mesa-dev] [PATCH 09/70] i965: Remove direct includes of intel_batchbuffer.h

2015-08-07 Thread Chris Wilson
Upcoming patches eliminate the intel_batchbuffer interface and one of the minor changes that causes a lot of churn is the removal of the header, along with the occassional need to now call intel_reg.h themselves. This patch moves the individual includes into brw_context.h. Signed-off-by: Chris Wil

[Mesa-dev] [PATCH 03/70] i965: Only flush the batchbuffer if we need to zero the SO offsets

2015-08-07 Thread Chris Wilson
If we don't have pipelined register access (e.g. Haswell before kernel v4.2), then we can only implement EXT_transform_feedback by reseting the SO offsets *between* batches. However, if we do have pipelined access to the SO registers on gen7, we can simply emit an inline reset of the SO registers w

[Mesa-dev] [PATCH 15/70] i965: Wrap drm_intel_bo_madvise() for brw_bo

2015-08-07 Thread Chris Wilson
To reduce later churn, extract drm_intel_bo_madvise() with a smaller wrapper. Signed-off-by: Chris Wilson --- src/mesa/drivers/dri/i965/brw_batch.h| 5 + src/mesa/drivers/dri/i965/brw_object_purgeable.c | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/

[Mesa-dev] [PATCH 14/70] i965: Add a simple utility function to wrap drm_intel_bo_flink()

2015-08-07 Thread Chris Wilson
Just to reduce some later churn, pull out the flink wrapper. Signed-off-by: Chris Wilson --- src/mesa/drivers/dri/i965/brw_batch.h| 7 +++ src/mesa/drivers/dri/i965/brw_context.c | 11 +-- src/mesa/drivers/dri/i965/intel_screen.c | 6 ++ 3 files changed, 14 insertions(+),

[Mesa-dev] [PATCH 16/70] i965: Move the render_cache dirty set from the context to the batch

2015-08-07 Thread Chris Wilson
To reduce churn later, move the brw->render_cache dirty set into the batch (i.e. brw->batch.render_cache). Signed-off-by: Chris Wilson --- src/mesa/drivers/dri/i965/brw_batch.h | 7 +++ src/mesa/drivers/dri/i965/brw_context.h | 7 --- src/mesa/drivers/dri/i965/intel_fbo.c | 12

[Mesa-dev] [PATCH 19/70] i965: Move pipelined register access to its own file

2015-08-07 Thread Chris Wilson
Move the pipelined register access out of intel_batchbuffer into its own utility file in preparation for replacing intel_batchbuffer. This also gives us the opportunity to refactor a few similar routines for writing registers, and so should prove useful in its own right. Signed-off-by: Chris Wilso

[Mesa-dev] [PATCH 20/70] i965: Replace opencoded brw_load_register_mem()

2015-08-07 Thread Chris Wilson
gen7_sol_state loads the SOL_OFFSET registers from its scratch buffer by hand, switch it over to the common routine for emitting that command. Signed-off-by: Chris Wilson --- src/mesa/drivers/dri/i965/gen7_sol_state.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --g

[Mesa-dev] [PATCH 18/70] i965: Extract brw_batch_busy()

2015-08-07 Thread Chris Wilson
A simple helper to check whether the last batch buffer submitted to the hardware is still busy. Extract it now to reduce churn later. Signed-off-by: Chris Wilson --- src/mesa/drivers/dri/i965/brw_batch.h | 5 + src/mesa/drivers/dri/i965/brw_cs.cpp | 5 ++--- src/mesa/drivers/dri/i965/brw_

[Mesa-dev] [PATCH 28/70] i965: Refactor batch buffer dumping

2015-08-07 Thread Chris Wilson
Move the computation of the state offset into a smaller helper to reduce churn later. Signed-off-by: Chris Wilson --- src/mesa/drivers/dri/i965/brw_state_dump.c | 62 -- 1 file changed, 33 insertions(+), 29 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_stat

[Mesa-dev] [PATCH 30/70] i965: Pass can-use-active flag to brw_bo_create()

2015-08-07 Thread Chris Wilson
The introduction of brw_bo_create() allows us to pass a new flag down when creating a linear buffer to allow the allocator to return a currently active buffer. (Previously all linear buffers were presumed to be allocated for CPU access and so the allocator only returned an idle buffer.) Signed-off

[Mesa-dev] [PATCH 21/70] i965: Refactor setting a register with an immediate constant

2015-08-07 Thread Chris Wilson
We have a few instances where we set a register to an immediate value (MI_LOAD_REGISTER_IMM), so let's replace them with a simple routine. Signed-off-by: Chris Wilson --- src/mesa/drivers/dri/i965/brw_draw.c| 6 +- src/mesa/drivers/dri/i965/brw_performance_monitor.c | 17 +++

[Mesa-dev] [PATCH 29/70] i965: Move brw_bo creation to brw_batch.h

2015-08-07 Thread Chris Wilson
Churn now to reduce churn later. Signed-off-by: Chris Wilson --- src/mesa/drivers/dri/i965/brw_batch.h | 34 +++ src/mesa/drivers/dri/i965/brw_binding_tables.c | 3 +- src/mesa/drivers/dri/i965/brw_context.c| 3 +- .../drivers/dri/i965/brw_performance_m

[Mesa-dev] [PATCH 25/70] i965: Move bufmgr from brw_context to brw_batch

2015-08-07 Thread Chris Wilson
Since brw_batch will become the dominate interface for brw_bo, move the pointer now to reduce later churn. Signed-off-by: Chris Wilson --- src/mesa/drivers/dri/i965/brw_batch.h | 2 ++ src/mesa/drivers/dri/i965/brw_binding_tables.c | 2 +- src/mesa/drivers/dri/i965/brw_conte

[Mesa-dev] [PATCH 27/70] i965: Move HW context into brw_batch

2015-08-07 Thread Chris Wilson
To reduce churn later, move the HW context variable from brw_context to brw_batch. Signed-off-by: Chris Wilson --- src/mesa/drivers/dri/i965/brw_batch.h | 2 ++ src/mesa/drivers/dri/i965/brw_context.c | 22 +++--- src/mesa/drivers/dri/i965/brw_context.h | 2 --

  1   2   >