[Mesa-dev] [v2 02/10] intel: do not create renderbuffers out of planar images

2013-04-29 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_fbo.c | 4 1 file changed, 4 insertions(+) diff --git a/src/mesa/drivers/dri/intel/intel_fbo.c b/src/mesa/drivers/dri/intel/intel_fbo.c index d22de68..296ae00 100644 --- a/src/mesa/drivers/dri/intel/intel_fbo.c +++ b/src

[Mesa-dev] [v2 03/10] intel: replace single region with a vector of regions

2013-04-29 Thread Topi Pohjolainen
No functional change in preparation for supporting multiple planes per image each having its own region. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_fbo.c | 6 +-- src/mesa/drivers/dri/intel/intel_regions.h | 7 ++- src/mesa/drivers/dri/intel/intel_screen.c

[Mesa-dev] [v2 04/10] intel: refactor planar format lookup

2013-04-29 Thread Topi Pohjolainen
v2: - refactor both occurences, not just one Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_screen.c | 31 ++- 1 file changed, 18 insertions(+), 13 deletions(-) diff --git a/src/mesa/drivers/dri/intel/intel_screen.c b/src/mesa/drivers/dri

[Mesa-dev] [v2 05/10] intel: set dri image dimensions even when creating out of primes

2013-04-29 Thread Topi Pohjolainen
Otherwise 'intel_set_texture_image_region()' won't have enough details to work with. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_screen.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/mesa/drivers/dri/intel/intel_screen.c b/src/mesa/dr

[Mesa-dev] [v2 06/10] intel: prepare for dri images having more than plane

2013-04-29 Thread Topi Pohjolainen
v2 (as advised by Eric): - use ARRAY_SIZE - re-use 'image_destroy' for cleaning up after failure - check directly the region pointer instead of the buffer object when determining if a region exists Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_scre

[Mesa-dev] [v2 07/10] dri: propagate extra dma_buf import attributes to the drivers

2013-04-29 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- include/GL/internal/dri_interface.h| 23 +++ src/egl/drivers/dri2/egl_dri2.c| 1 + src/mesa/drivers/dri/intel/intel_regions.h | 7 +++ src/mesa/drivers/dri/intel/intel_screen.c | 9 + 4 files changed, 40

[Mesa-dev] [v2 08/10] egl: definitions for EXT_image_dma_buf_import

2013-04-29 Thread Topi Pohjolainen
As specified in: http://www.khronos.org/registry/egl/extensions/EXT/EGL_EXT_image_dma_buf_import.txt Checking for the valid fourcc values is left for drivers avoiding dependency to drm header files here. v2: - enforce EGL_NO_CONTEXT Signed-off-by: Topi Pohjolainen --- include/EGL/eglext.h

[Mesa-dev] [v2 09/10] egl: dri2: support for creating images out of dma buffers

2013-04-29 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/egl/drivers/dri2/egl_dri2.c | 238 1 file changed, 238 insertions(+) diff --git a/src/egl/drivers/dri2/egl_dri2.c b/src/egl/drivers/dri2/egl_dri2.c index 10fdcef..2a8c614 100644 --- a/src/egl/drivers/dri2/egl_dri2

[Mesa-dev] [v2 10/10] intel: enable EXT_image_dma_buf_import

2013-04-29 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_extensions.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/mesa/drivers/dri/intel/intel_extensions.c b/src/mesa/drivers/dri/intel/intel_extensions.c index 1aea7e9..46b5689 100755 --- a/src/mesa/drivers/dri/intel

[Mesa-dev] [v3] egl: dri2: support for creating images out of dma buffers

2013-04-30 Thread Topi Pohjolainen
v2: - upon success close the given file descriptors Signed-off-by: Topi Pohjolainen --- src/egl/drivers/dri2/egl_dri2.c | 276 1 file changed, 276 insertions(+) diff --git a/src/egl/drivers/dri2/egl_dri2.c b/src/egl/drivers/dri2/egl_dri2.c index

[Mesa-dev] [v4] EXT_image_dma_buf_import for intel

2013-05-02 Thread Topi Pohjolainen
GL (not GLES) - import EGL definitions from khronos - no not break DRI image ABI, but introduce new entry and update the version of the interface Topi Pohjolainen (10): intel: allow packed prime buffers to be treated normally intel: do not create renderbuffers out of planar image

[Mesa-dev] [v4 01/10] intel: allow packed prime buffers to be treated normally

2013-05-02 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_screen.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/mesa/drivers/dri/intel/intel_screen.c b/src/mesa/drivers/dri/intel/intel_screen.c index ad1b351..1ba1279 100644 --- a/src/mesa/drivers/dri

[Mesa-dev] [v4 02/10] intel: do not create renderbuffers out of planar images

2013-05-02 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_fbo.c | 4 1 file changed, 4 insertions(+) diff --git a/src/mesa/drivers/dri/intel/intel_fbo.c b/src/mesa/drivers/dri/intel/intel_fbo.c index 6730d26..6aaf6b6 100644 --- a/src/mesa/drivers/dri/intel/intel_fbo.c +++ b/src

[Mesa-dev] [v4 03/10] intel: replace single region with a vector of regions

2013-05-02 Thread Topi Pohjolainen
No functional change in preparation for supporting multiple planes per image each having its own region. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_fbo.c | 6 +-- src/mesa/drivers/dri/intel/intel_regions.h | 7 ++- src/mesa/drivers/dri/intel/intel_screen.c

[Mesa-dev] [v4 04/10] intel: refactor planar format lookup

2013-05-02 Thread Topi Pohjolainen
v2: - refactor both occurences, not just one Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_screen.c | 31 ++- 1 file changed, 18 insertions(+), 13 deletions(-) diff --git a/src/mesa/drivers/dri/intel/intel_screen.c b/src/mesa/drivers/dri

[Mesa-dev] [v4 05/10] intel: set dri image dimensions even when creating out of primes

2013-05-02 Thread Topi Pohjolainen
Otherwise 'intel_set_texture_image_region()' won't have enough details to work with. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_screen.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/mesa/drivers/dri/intel/intel_screen.c b/src/mesa/dr

[Mesa-dev] [v4 06/10] intel: prepare for dri images having more than one plane

2013-05-02 Thread Topi Pohjolainen
v2 (as advised by Eric): - use ARRAY_SIZE - re-use 'image_destroy' for cleaning up after failure - check directly the region pointer instead of the buffer object when determining if a region exists Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_scre

[Mesa-dev] [v4 07/10] dri: propagate extra dma_buf import attributes to the drivers

2013-05-02 Thread Topi Pohjolainen
v2: - do not break ABI, but instead introduce new entry point for dma buffers and bump up the dri-interface version to eight Signed-off-by: Topi Pohjolainen --- include/GL/internal/dri_interface.h| 36 +- src/mesa/drivers/dri/intel/intel_regions.h

[Mesa-dev] [v4 08/10] egl: update eglext.h from khronos

2013-05-02 Thread Topi Pohjolainen
Provides definitions for dma buffer import extension. Signed-off-by: Topi Pohjolainen --- include/EGL/eglext.h | 45 ++--- 1 file changed, 42 insertions(+), 3 deletions(-) diff --git a/include/EGL/eglext.h b/include/EGL/eglext.h index b2b5a80..1d68178

[Mesa-dev] [v4 09/10] egl: definitions for EXT_image_dma_buf_import

2013-05-02 Thread Topi Pohjolainen
: - do not update eglext.h manually but rely on update from Khronos instead Signed-off-by: Topi Pohjolainen --- src/egl/main/eglapi.c | 7 - src/egl/main/egldisplay.h | 1 + src/egl/main/eglimage.c | 76 +++ src/egl/main/eglimage.h | 15

[Mesa-dev] [v4 10/10] egl: dri2: support for creating images out of dma buffers

2013-05-02 Thread Topi Pohjolainen
v2: - upon success close the given file descriptors v3: - use specific entry for dma buffers instead of the basic for primes, and enable the extension based on the availability of the hook Signed-off-by: Topi Pohjolainen --- src/egl/drivers/dri2/egl_dri2.c | 280

[Mesa-dev] [v5] egl: definitions for EXT_image_dma_buf_import

2013-05-16 Thread Topi Pohjolainen
eglext.h manually but rely on update from Khronos instead v5: report invalid context as EGL_BAD_PARAMETER instead of as EGL_BAD_CONTEXT (Eric) Signed-off-by: Topi Pohjolainen --- src/egl/main/eglapi.c | 6 src/egl/main/egldisplay.h | 1 + src/egl/main/eglimage.c | 76

[Mesa-dev] [v6] EXT_image_dma_buf_import for intel

2013-05-28 Thread Topi Pohjolainen
at from unsupported (Chad) - fix the rejection of all hints (Chad) - report invalid context as EGL_BAD_PARAMETER instead of as EGL_BAD_CONTEXT (Eric) Topi Pohjolainen (9): intel: allow packed prime buffers to be treated normally intel: do not create renderbuffers out of planar image

[Mesa-dev] [v6 1/9] intel: allow packed prime buffers to be treated normally

2013-05-28 Thread Topi Pohjolainen
v2: - fix earlier rebase error breaking bisect (loaderPriv -> loaderPrivate) Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_screen.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/mesa/drivers/dri/intel/intel_screen.c b/src/m

[Mesa-dev] [v6 2/9] intel: do not create renderbuffers out of planar images

2013-05-28 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_fbo.c | 4 1 file changed, 4 insertions(+) diff --git a/src/mesa/drivers/dri/intel/intel_fbo.c b/src/mesa/drivers/dri/intel/intel_fbo.c index 69f8629..7ccbaa8 100644 --- a/src/mesa/drivers/dri/intel/intel_fbo.c +++ b/src

[Mesa-dev] [v6 3/9] intel: replace single region with a vector of regions

2013-05-28 Thread Topi Pohjolainen
is not used yet but will be later in the series. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_fbo.c | 6 +-- src/mesa/drivers/dri/intel/intel_regions.h | 19 +++- src/mesa/drivers/dri/intel/intel_screen.c| 69 ++-- src

[Mesa-dev] [v6 4/9] intel: refactor planar format lookup

2013-05-28 Thread Topi Pohjolainen
v2: - refactor both occurences, not just one Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_screen.c | 31 ++- 1 file changed, 18 insertions(+), 13 deletions(-) diff --git a/src/mesa/drivers/dri/intel/intel_screen.c b/src/mesa/drivers/dri

[Mesa-dev] [v6 5/9] intel: set dri image dimensions even when creating out of primes

2013-05-28 Thread Topi Pohjolainen
Otherwise 'intel_set_texture_image_region()' won't have enough details to work with. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_screen.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/mesa/drivers/dri/intel/intel_screen.c b/src/mesa/dr

[Mesa-dev] [v6 6/9] intel: prepare for dri images having more than one plane

2013-05-28 Thread Topi Pohjolainen
tor region setting for multiple fds - record the offsets (and strides) also when planes are in separate buffers - use the region count utility instead of always iterating through the entire array Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/intel/intel_scr

[Mesa-dev] [v6 7/9] dri: propagate extra dma_buf import attributes to the drivers

2013-05-28 Thread Topi Pohjolainen
the hints also as they are addressing only YUV sampling which is not supported at the moment but then thought against it as the spec is not saying one way or the other. Signed-off-by: Topi Pohjolainen --- include/GL/internal/dri_interface.h| 37 +++- src

[Mesa-dev] [v6 8/9] egl: definitions for EXT_image_dma_buf_import

2013-05-28 Thread Topi Pohjolainen
eglext.h manually but rely on update from Khronos instead v5: report invalid context as EGL_BAD_PARAMETER instead of as EGL_BAD_CONTEXT (Eric) v6: fix the checking for valid hints. Before all values were rejected (Chad). Signed-off-by: Topi Pohjolainen --- src/egl/main/eglapi.c

[Mesa-dev] [v6 9/9] egl/dri2: support for creating images out of dma buffers

2013-05-28 Thread Topi Pohjolainen
descriptors - in case of invalid format report EGL_BAD_ATTRIBUTE instead of EGL_BAD_MATCH - take into account specific error set by the driver. Signed-off-by: Topi Pohjolainen --- src/egl/drivers/dri2/egl_dri2.c | 275 1 file changed, 275 insertions

[Mesa-dev] [v7] EXT_image_dma_buf_import for intel

2013-07-10 Thread Topi Pohjolainen
age with no regions (Chad) - distinguish invalid drm format from unsupported (Chad) - fix the rejection of all hints (Chad) - report invalid context as EGL_BAD_PARAMETER instead of as EGL_BAD_CONTEXT (Eric) v7: - native RGB formats only and only via image external sampler Topi Pohjolainen (

[Mesa-dev] [v7 1/9] intel: allow packed prime buffers to be treated normally

2013-07-10 Thread Topi Pohjolainen
v2: - fix earlier rebase error breaking bisect (loaderPriv -> loaderPrivate) Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/intel_screen.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/mesa/drivers/dri/i965/intel_screen.c b/src/mesa/driv

[Mesa-dev] [v7 2/9] intel: do not create renderbuffers out of planar images

2013-07-10 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/intel_fbo.c | 4 1 file changed, 4 insertions(+) diff --git a/src/mesa/drivers/dri/i965/intel_fbo.c b/src/mesa/drivers/dri/i965/intel_fbo.c index e746cb4..25024fb 100644 --- a/src/mesa/drivers/dri/i965/intel_fbo.c +++ b/src

[Mesa-dev] [v7 3/9] intel: refactor planar format lookup

2013-07-10 Thread Topi Pohjolainen
v2: - refactor both occurences, not just one Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/intel_screen.c | 31 ++- 1 file changed, 18 insertions(+), 13 deletions(-) diff --git a/src/mesa/drivers/dri/i965/intel_screen.c b/src/mesa/drivers/dri

[Mesa-dev] [v7 4/9] intel: set dri image dimensions even when creating out of primes

2013-07-10 Thread Topi Pohjolainen
Otherwise 'intel_set_texture_image_region()' won't have enough details to work with. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/intel_screen.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/mesa/drivers/dri/i965/intel_screen.c b/src/mesa/d

[Mesa-dev] [v7 5/9] dri: propagate extra dma_buf import attributes to the drivers

2013-07-10 Thread Topi Pohjolainen
: Topi Pohjolainen --- include/GL/internal/dri_interface.h | 37 +++- src/mesa/drivers/dri/i965/intel_regions.h | 7 + src/mesa/drivers/dri/i965/intel_screen.c | 48 +-- 3 files changed, 89 insertions(+), 3 deletions(-) diff --git a/include

[Mesa-dev] [v7 6/9] egl: definitions for EXT_image_dma_buf_import

2013-07-10 Thread Topi Pohjolainen
eglext.h manually but rely on update from Khronos instead v5: report invalid context as EGL_BAD_PARAMETER instead of as EGL_BAD_CONTEXT (Eric) v6: fix the checking for valid hints. Before all values were rejected (Chad). Signed-off-by: Topi Pohjolainen --- src/egl/main/eglapi.c

[Mesa-dev] [v7 7/9] intel: restrict dma-buf-import images to external sampling only

2013-07-10 Thread Topi Pohjolainen
Memory originating outside mesa stack is meant to be for reading only. In addition, the restrictions imposed by the image external extension should apply. For example, users shouldn't be allowed to generare mip-trees based on these images. Signed-off-by: Topi Pohjolainen --- src/mesa/dr

[Mesa-dev] [v7 8/9] egl/dri2: support for creating images out of dma buffers

2013-07-10 Thread Topi Pohjolainen
descriptors - in case of invalid format report EGL_BAD_ATTRIBUTE instead of EGL_BAD_MATCH - take into account specific error set by the driver. v5: - fix error handling Signed-off-by: Topi Pohjolainen --- src/egl/drivers/dri2/egl_dri2.c | 278 1 file

[Mesa-dev] [v7 9/9] i965: enable image external sampling for imported dma-buffers

2013-07-10 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/intel_extensions.c | 1 + src/mesa/drivers/dri/i965/intel_tex_image.c | 6 ++ 2 files changed, 7 insertions(+) diff --git a/src/mesa/drivers/dri/i965/intel_extensions.c b/src/mesa/drivers/dri/i965/intel_extensions.c index

[Mesa-dev] [PATCH] i965/blorp: Fix hw blending coefficients

2014-02-03 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/gen6_blorp.cpp | 22 -- 1 file changed, 20 insertions(+), 2 deletions(-) diff --git a/src/mesa/drivers/dri/i965/gen6_blorp.cpp b/src/mesa/drivers/dri/i965/gen6_blorp.cpp index 90b9fbb..281ea5c 100644 --- a/src/mesa

[Mesa-dev] [PATCH 1/7] i965/blorp: refactor assertions for tile offset alignments

2014-02-10 Thread Topi Pohjolainen
There are only two callers for compute_tile_offsets() and both require the exact same constraints for the tile offsets. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_blorp.cpp | 6 ++ src/mesa/drivers/dri/i965/gen6_blorp.cpp | 5 - src/mesa/drivers/dri/i965

[Mesa-dev] [PATCH 2/7] i965/blorp: split calculations of page and tile offsets

2014-02-10 Thread Topi Pohjolainen
These will be handled separately in the coming patches. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_blorp.cpp | 21 + src/mesa/drivers/dri/i965/brw_blorp.h| 3 ++- src/mesa/drivers/dri/i965/gen6_blorp.cpp | 4 ++-- src/mesa/drivers/dri/i965

[Mesa-dev] Blorp without surface state xy-offsets

2014-02-10 Thread Topi Pohjolainen
safer. I haven't tried yet but I cannot see any reason why the hardware layer support couldn't be enabled on top of this. Topi Pohjolainen (7): i965/blorp: refactor assertions for tile offset alignments i965/blorp: split calculations of page and tile offsets i965/blorp: add in

[Mesa-dev] [PATCH 3/7] i965/blorp: add intra-tile offset support without surface config

2014-02-10 Thread Topi Pohjolainen
In gen6/7 the surface state can be adjusted with these directly but starting from gen8 there isn't that option anymore. In this patch these are still just zero and have no effect. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_blorp.cpp

[Mesa-dev] [PATCH 4/7] i965/blorp: handle destination tile offsets for w-tiled in the program

2014-02-10 Thread Topi Pohjolainen
instead of using the surface state x/y-offsets. These are not available in the gen8 anymore. No regressions on IVB and SNB. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_blorp.cpp | 7 +++ src/mesa/drivers/dri/i965/gen6_blorp.cpp | 22 -- src/mesa

[Mesa-dev] [PATCH 6/7] i965/blorp: handle tile offsets for all destinations in the program

2014-02-10 Thread Topi Pohjolainen
: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_blorp.cpp | 10 ++ src/mesa/drivers/dri/i965/brw_blorp_clear.cpp | 2 ++ src/mesa/drivers/dri/i965/gen6_blorp.cpp | 4 ++-- src/mesa/drivers/dri/i965/gen7_blorp.cpp | 2 +- 4 files changed, 11 insertions(+), 7 deletions

[Mesa-dev] [PATCH 7/7] i965/blorp: handle tile offsets for all sources in the program

2014-02-10 Thread Topi Pohjolainen
Note that hiz and clear programs need no consideration here as they do not use any source surfaces. No regressions on IVB and SNB. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_blorp.cpp | 10 ++ src/mesa/drivers/dri/i965/gen6_blorp.cpp | 18 -- src

[Mesa-dev] [PATCH 5/7] i965/blorp: handle source tile offsets for w-tiled in the program

2014-02-10 Thread Topi Pohjolainen
instead of using the surface state x/y-offsets. These are not available in the gen8 anymore. No regressions on IVB and SNB. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_blorp.cpp | 7 +++ src/mesa/drivers/dri/i965/gen6_blorp.cpp | 4 ++-- src/mesa/drivers/dri/i965

[Mesa-dev] [RFC] ARB_stencil_texturing on Gen6/7

2014-02-22 Thread Topi Pohjolainen
into emission of W-to-Y translation for W-tiled stencil targets. Patch 26 adds the control when the translation is needed in runtime and finally 27 enables the whole thing - this is premature of course as the equivalent vertex logic is still missing. Topi Pohjolainen (27): i965: Remove unused sample

[Mesa-dev] [RFC 04/27] i965: Allow w-tiled miptree offsets to be resolved as y-tiled directly

2014-02-22 Thread Topi Pohjolainen
This is not utilised yet but will be needed when W-tiled stencil is sampled as Y-tiled. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/intel_fbo.h | 2 +- src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 11 +-- src/mesa/drivers/dri/i965/intel_mipmap_tree.h | 1

[Mesa-dev] [RFC 07/27] i965/wm: Introduce support for texture surface x/y-tile offsets

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_state.h | 7 +++ src/mesa/drivers/dri/i965/brw_wm_surface_state.c | 13 - src/mesa/drivers/dri/i965/gen7_wm_surface_state.c | 4 +++- 3 files changed, 22 insertions(+), 2 deletions(-) diff --git a

[Mesa-dev] [RFC 17/27] i965: Merge fail() for ir visitors

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_fs.cpp | 23 --- src/mesa/drivers/dri/i965/brw_fs.h | 1 - src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 2 +- src/mesa/drivers/dri/i965/brw_shader.cpp | 31

[Mesa-dev] [RFC 03/27] i965/vec4: Mark invariant members as constants in vec4_visitor

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_vec4.h | 6 +++--- src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp | 8 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_vec4.h b/src/mesa/drivers/dri/i965/brw_vec4.h

[Mesa-dev] [RFC 06/27] i965/wm: Refactor resolving of texture parameters

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_state.h | 16 src/mesa/drivers/dri/i965/brw_wm_surface_state.c | 49 ++- src/mesa/drivers/dri/i965/gen7_wm_surface_state.c | 27 ++--- 3 files changed, 67 insertions(+), 25

[Mesa-dev] [RFC 01/27] i965: Remove unused sampler key fields

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_program.h | 6 -- src/mesa/drivers/dri/i965/brw_wm.c | 10 -- 2 files changed, 16 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_program.h b/src/mesa/drivers/dri/i965/brw_program.h index 59f628b

[Mesa-dev] [RFC 10/27] i965: Merge resolving of shader program source

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 8 ++-- src/mesa/drivers/dri/i965/brw_shader.cpp | 5 - src/mesa/drivers/dri/i965/brw_shader.h| 3 ++- src/mesa/drivers/dri/i965/brw_vec4.cpp

[Mesa-dev] [RFC 02/27] i965: Mark sources for offset getters as constants

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 6 +++--- src/mesa/drivers/dri/i965/intel_mipmap_tree.h | 4 ++-- src/mesa/drivers/dri/i965/intel_regions.c | 4 ++-- src/mesa/drivers/dri/i965/intel_regions.h | 4 ++-- 4 files changed, 9 insertions

[Mesa-dev] [RFC 16/27] i965: Merge common members of visitors

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_fs.h | 20 src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 19 --- src/mesa/drivers/dri/i965/brw_shader.cpp | 18 +- src/mesa/drivers/dri/i965/brw_shader.h

[Mesa-dev] [RFC 27/27] i965: Enable ARB_stencil_texturing on Gen6.

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/intel_extensions.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesa/drivers/dri/i965/intel_extensions.c b/src/mesa/drivers/dri/i965/intel_extensions.c index 5094c2b..c7eef830 100644 --- a/src/mesa/drivers

[Mesa-dev] [RFC 08/27] i965/fs: Configure w-tiled stencil surfaces as y-tiled on gen6/7

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_wm_surface_state.c | 28 ++-- 1 file changed, 26 insertions(+), 2 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_wm_surface_state.c b/src/mesa/drivers/dri/i965/brw_wm_surface_state.c index 6f23cec

[Mesa-dev] [RFC 12/27] i965: Split emitter out of backend_visitor

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_cfg.cpp| 8 src/mesa/drivers/dri/i965/brw_cfg.h | 4 ++-- src/mesa/drivers/dri/i965/brw_dead_control_flow.cpp | 6 +++--- src/mesa/drivers/dri/i965/brw_dead_control_flow.h| 2

[Mesa-dev] [RFC 23/27] i965/fs: Add helper for emitting plain texture resinfo messages

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_fs.h | 2 ++ src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 21 + 2 files changed, 23 insertions(+) diff --git a/src/mesa/drivers/dri/i965/brw_fs.h b/src/mesa/drivers/dri/i965/brw_fs.h index

[Mesa-dev] [RFC 05/27] i965/wm: Use resolved miptree consistently in surface setup

2014-02-22 Thread Topi Pohjolainen
Most of the logic refers to the local variable 'mt' directly but a few cases use 'intelObj->mt' instead. These are the same for now but will be different once stencil miptree gets used. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_wm_surface_state.c

[Mesa-dev] [RFC 13/27] i965: Merge memory context allocation for shader visitors

2014-02-22 Thread Topi Pohjolainen
Such like fs_visitor the dynamic data generated by vec4_visitor does not have lifecycle longer than the visitor itself. Hence it can be taken cared of by the common base. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 2 -- src/mesa/drivers/dri/i965

[Mesa-dev] [RFC 18/27] i965/fs: Split LIR emission ouf of ir-visitor

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/Makefile.sources | 1 + src/mesa/drivers/dri/i965/brw_fs.cpp | 44 -- src/mesa/drivers/dri/i965/brw_fs.h | 55 - src/mesa/drivers/dri/i965/brw_fs_emitter.cpp | 119

[Mesa-dev] [RFC 25/27] i965/fs: Emit coordinate translation from W to Y-tiling

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_fs.h | 2 + src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 69 2 files changed, 71 insertions(+) diff --git a/src/mesa/drivers/dri/i965/brw_fs.h b/src/mesa/drivers/dri/i965/brw_fs.h index

[Mesa-dev] [RFC 21/27] i965/blorp: Refactor w-tiling to y-tiling translation

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_blorp_blit.cpp | 23 +- src/mesa/drivers/dri/i965/brw_fs.h | 7 ++ src/mesa/drivers/dri/i965/brw_fs_emitter.cpp | 110 +++ 3 files changed, 118 insertions(+), 22 deletions(-) diff --git a

[Mesa-dev] [RFC 14/27] i965: Merge max_grf between stage compilers

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_fs.h| 2 -- src/mesa/drivers/dri/i965/brw_fs_reg_allocate.cpp | 2 +- src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 1 - src/mesa/drivers/dri/i965/brw_shader.cpp | 3 ++- src/mesa/drivers/dri/i965

[Mesa-dev] [RFC 19/27] i965/fs: Move emission of ALUs into fs_emitter

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_fs.cpp | 89 src/mesa/drivers/dri/i965/brw_fs.h | 63 ++-- src/mesa/drivers/dri/i965/brw_fs_emitter.cpp | 88 +++ 3 files changed, 120

[Mesa-dev] [RFC 24/27] i965/fs: Add helpers for de/normalizing values

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_fs.h | 6 + src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 39 2 files changed, 45 insertions(+) diff --git a/src/mesa/drivers/dri/i965/brw_fs.h b/src/mesa/drivers/dri/i965/brw_fs.h

[Mesa-dev] [RFC 15/27] i965/vec4: Use unsigned instead of signed for visitor uniform count

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_vec4.cpp | 12 ++-- src/mesa/drivers/dri/i965/brw_vec4.h | 2 +- src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp | 2 +- src/mesa/drivers/dri/i965/brw_vec4_vp.cpp | 2 +- 4 files changed, 9

[Mesa-dev] [RFC 26/27] i965/fs: Recompile when switching to/from stencil indexing

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_program.h | 7 +++ src/mesa/drivers/dri/i965/brw_wm.c | 7 +++ 2 files changed, 14 insertions(+) diff --git a/src/mesa/drivers/dri/i965/brw_program.h b/src/mesa/drivers/dri/i965/brw_program.h index 6aa0ac1..fc00517

[Mesa-dev] [RFC 20/27] i965/blorp: Use fs_emitter

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_blorp_blit.cpp| 340 src/mesa/drivers/dri/i965/brw_blorp_blit_eu.cpp | 28 +- src/mesa/drivers/dri/i965/brw_blorp_blit_eu.h | 110 +--- 3 files changed, 189 insertions(+), 289 deletions(-) diff

[Mesa-dev] [RFC 11/27] i965: Mark invariants in backend_visitor as constants

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_shader.h | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_shader.h b/src/mesa/drivers/dri/i965/brw_shader.h index 4e41c84..e718197 100644 --- a/src/mesa/drivers/dri

[Mesa-dev] [RFC 22/27] i965/fs: Add generator support for fetching texture dimensions

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_defines.h| 2 ++ src/mesa/drivers/dri/i965/brw_fs.cpp | 1 + src/mesa/drivers/dri/i965/brw_fs.h | 3 +++ src/mesa/drivers/dri/i965/brw_fs_generator.cpp | 33 ++ src/mesa

[Mesa-dev] [RFC 09/27] i965: Merge initialisation of backend_visitor

2014-02-22 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 9 ++--- src/mesa/drivers/dri/i965/brw_shader.cpp | 12 src/mesa/drivers/dri/i965/brw_shader.h | 7 +++ src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp | 9 ++--- 4 files

[Mesa-dev] [RFC] i965: Restore vbo after color resolve during brw_try_draw_prims()

2016-01-27 Thread Topi Pohjolainen
ext would make sense. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_meta_fast_clear.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/mesa/drivers/dri/i965/brw_meta_fast_clear.c b/src/mesa/drivers/dri/i965/brw_meta_fast_clear.c index d338659..affe1bc 100644 --- a/

[Mesa-dev] [v2 1/2] i965: Validate textures before altering driver state

2016-01-28 Thread Topi Pohjolainen
state is updated. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_draw.c | 18 +- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_draw.c b/src/mesa/drivers/dri/i965/brw_draw.c index 8737c64..c295d91 100644 --- a/src/mesa

[Mesa-dev] [v2 2/2] i965: Restore vbo after color resolve during brw_try_draw_prims()

2016-01-28 Thread Topi Pohjolainen
ext would make sense. v2: Force input recalculation by setting the flag explicitly Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_meta_fast_clear.c | 4 1 file changed, 4 insertions(+) diff --git a/src/mesa/drivers/dri/i965/brw_meta_fast_clear.c b/src/m

[Mesa-dev] [v3] i965: Restore vbo after color resolve during brw_try_draw_prims()

2016-02-03 Thread Topi Pohjolainen
ext would make sense. v2: Force input recalculation by setting the flag explicitly v3: Do not attempt to restore vbo for opengles1 which doesn't support vertex buffer objects. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_meta_fast_clear.c | 9 + 1 file chang

[Mesa-dev] [PATCH 07/23] i965/gen9: Allow halign == 16 also for losslessly compressed

2016-02-08 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/mesa/drivers/dri/i965/intel_mipmap_tree.c b/src/mesa/drivers/dri/i965/intel_mipmap_tree.c index fe525c3..6f46385 100644 --- a/src/mesa

[Mesa-dev] [PATCH 12/23] i965: Refactor resolving of auxiliary mode

2016-02-08 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/gen8_surface_state.c | 62 -- 1 file changed, 29 insertions(+), 33 deletions(-) diff --git a/src/mesa/drivers/dri/i965/gen8_surface_state.c b/src/mesa/drivers/dri/i965/gen8_surface_state.c index fc8f701

[Mesa-dev] [PATCH 08/23] i965: Allow fast clear to be used with lossless compression

2016-02-08 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_meta_fast_clear.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_meta_fast_clear.c b/src/mesa/drivers/dri/i965/brw_meta_fast_clear.c index 871a77e..5391794 100644 --- a

[Mesa-dev] [PATCH 09/23] i965: Add resolve option for lossless compression

2016-02-08 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_defines.h | 1 + src/mesa/drivers/dri/i965/brw_meta_fast_clear.c | 5 - 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/mesa/drivers/dri/i965/brw_defines.h b/src/mesa/drivers/dri/i965/brw_defines.h

[Mesa-dev] i965/gen9: Compression support for single-sampled

2016-02-08 Thread Topi Pohjolainen
able of reading both the color buffer and the auxiliary, and resolves can be omitted in those case. The final enabling patch is dependent on earlier two-patch series fixing state restore mechanism in i965-meta operations. There are some performance numbers available in the final commit. Topi

[Mesa-dev] [PATCH 03/23] i965: Separate miptree creation from auxiliary buffer setup

2016-02-08 Thread Topi Pohjolainen
neral allocation and setup steps. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 75 +-- 1 file changed, 49 insertions(+), 26 deletions(-) diff --git a/src/mesa/drivers/dri/i965/intel_mipmap_tree.c b/src/mesa/drivers/dri/i965/intel_mipmap_t

[Mesa-dev] [PATCH 05/23] i965: Stop considering if msrt aux buffers need aux buffer

2016-02-08 Thread Topi Pohjolainen
)possibility. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 21 +++-- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/src/mesa/drivers/dri/i965/intel_mipmap_tree.c b/src/mesa/drivers/dri/i965/intel_mipmap_tree.c index 6c447ba

[Mesa-dev] [PATCH 04/23] i965: Don't try to create aux buffer for non-msrt aux-buffer

2016-02-08 Thread Topi Pohjolainen
intel_miptree_create_layout() later on to try to associate the auxiliary buffer with an auxiliary buffer. To prevent this the actual buffer creation logic was split out into its own function. Lets invoke that instead. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 21

[Mesa-dev] [PATCH 14/23] i965: Add means for limiting color resolves

2016-02-08 Thread Topi Pohjolainen
ve is needed. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_blorp_blit.cpp | 2 +- src/mesa/drivers/dri/i965/brw_context.c| 8 src/mesa/drivers/dri/i965/intel_blit.c | 4 ++-- src/mesa/drivers/dri/i965/intel_copy_image.c | 4 ++-- src/mesa/drivers/dri

[Mesa-dev] [PATCH 20/23] i965: Expose logic telling if non-msrt mcs is supported

2016-02-08 Thread Topi Pohjolainen
Alos use the opportunity to mark inputs constant. (Context has to be given as read-write to intel_miptree_supports_non_msrt_fast_clear() to support debug output). Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 9 + src/mesa/drivers/dri/i965

[Mesa-dev] [PATCH 16/23] i965: Add a few assertions on lossless compression

2016-02-08 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_blorp_blit.cpp | 4 src/mesa/drivers/dri/i965/brw_context.c | 4 2 files changed, 8 insertions(+) diff --git a/src/mesa/drivers/dri/i965/brw_blorp_blit.cpp b/src/mesa/drivers/dri/i965/brw_blorp_blit.cpp index

[Mesa-dev] [PATCH 06/23] i965/gen9: Add buffer layout representing lossless compression

2016-02-08 Thread Topi Pohjolainen
Skylake introduces compression support also for the single-sampled color buffers. Similarly to the multi-sampled case the color buffer will be associated with an auxiliary surface tracking the compression state. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_blorp_blit.cpp

[Mesa-dev] [PATCH 15/23] i965: Add a flag telling color resolve pass to ignore CCS_E

2016-02-08 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_context.c | 12 +++- src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 10 +- src/mesa/drivers/dri/i965/intel_mipmap_tree.h | 9 + 3 files changed, 29 insertions(+), 2 deletions(-) diff --git a/src

[Mesa-dev] [PATCH 17/23] i965: Set buffer cleared after actually clearing it

2016-02-08 Thread Topi Pohjolainen
: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_meta_fast_clear.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/mesa/drivers/dri/i965/brw_meta_fast_clear.c b/src/mesa/drivers/dri/i965/brw_meta_fast_clear.c index 07696cf..8117727 100644 --- a/src/mesa/drivers/dri

[Mesa-dev] [PATCH 18/23] i965/gen9: Prepare surface state setup for lossless compression

2016-02-08 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/brw_defines.h| 1 + src/mesa/drivers/dri/i965/gen8_surface_state.c | 6 ++ 2 files changed, 7 insertions(+) diff --git a/src/mesa/drivers/dri/i965/brw_defines.h b/src/mesa/drivers/dri/i965/brw_defines.h index fa71865

[Mesa-dev] [PATCH 13/23] i965: Resolve color buffer also in lossless compression case

2016-02-08 Thread Topi Pohjolainen
Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/mesa/drivers/dri/i965/intel_mipmap_tree.c b/src/mesa/drivers/dri/i965/intel_mipmap_tree.c index 6f46385..6ec02d8 100644 --- a/src/mesa

[Mesa-dev] [PATCH 19/23] i965/gen9: Refactor msrt mcs initialization

2016-02-08 Thread Topi Pohjolainen
This will be re-used to initialize auxiliary buffers in lossless compression case. Signed-off-by: Topi Pohjolainen --- src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 36 --- 1 file changed, 22 insertions(+), 14 deletions(-) diff --git a/src/mesa/drivers/dri/i965

<    1   2   3   4   5   6   7   8   9   10   >