Commit Graph

84465 Commits

Author SHA1 Message Date
Jason Ekstrand
6d2f8f8f5f i965/blorp: Add driver mocs settings to the context
Signed-off-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
2016-08-29 12:17:34 -07:00
Jason Ekstrand
9c380b639f i965/blorp/genX: Move emit_urb_config into another helper
Signed-off-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
2016-08-29 12:17:34 -07:00
Jason Ekstrand
28991c9601 i965/blorp: Use gen6_upload_urb
Signed-off-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
2016-08-29 12:17:34 -07:00
Jason Ekstrand
7ecbb9bada i965/gen6: Refactor gen6_upload_urb
This splits it into two functions very similar to gen7_upload_urb.

Signed-off-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
2016-08-29 12:17:34 -07:00
Jason Ekstrand
3e4b43d11d i965/blorp/genX: Pull emit_3dstate_multisample into a helper
Signed-off-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
2016-08-29 12:17:34 -07:00
Jason Ekstrand
becd434d14 i965/blorp/genX: Add helpers for allocating various bits of state
This pulls most of the brw-specific bits into helpers with generic names.
Later, those will become the driver hooks for generic code.

Signed-off-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
2016-08-29 12:17:34 -07:00
Jason Ekstrand
600446ccc7 i965/blorp: Expose the shader cache through function pointers
This sanitizes blorp's access to the i965 driver's shader cache by patching
it through the blorp_context.  When we start using blorp in Vulkan, we will
simply have to implement such a caching interface in the Vulkan driver.

Note: In my first attempt at this, I simplified it down to a single
upload_shader entrypoint and implemented the caching inside of blorp.  This
doesn't work, however, because the i965 driver will, on occation, dump its
entire cache and start over.  When this happens, blorp needs to be able to
recompile its shaders and re-upload them.  It's easiest to just expose the
caching interface.

Signed-off-by: Jason Ekstrand <jason@jlekstrand.net>
2016-08-29 12:17:34 -07:00
Jason Ekstrand
a14d1b63ce i965/blorp: Add a blorp_context struct and init/finish funcs
Signed-off-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
2016-08-29 12:17:34 -07:00
Mauro Rossi
cd18bbeef3 android: intel: Flatten the makefile structure
Android porting of commit bebc1a1 "intel: Flatten the makefile structure"

Automake approach was followed, by moving makefiles a level up,
naming them Android.genxml.mk and Android.isl.mk,
performing the necessary adjustments to the paths,
adding src/intel/Android.mk and fixing mesa top level makefile.

Acked-by: Jason Ekstrand <jason@jlekstrand.net>
2016-08-29 12:17:34 -07:00
Jan Vesely
083746bc48 clover: Use device cap to query pointer size instead of hardcoded 32bits
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=97513
Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu>
Reviewed-by: Francisco Jerez <currojerez@riseup.net>
2016-08-29 14:40:15 -04:00
Jan Vesely
c7af84968d gallium: add cap to export device pointer size
v2: document the new cap
v3: fix 80 char limit in screen.rst

Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Acked-by: Ilia Mirkin <imirkin@alum.mit.edu>
2016-08-29 14:40:15 -04:00
Brian Paul
f5602c27ec svga: s/unsigned/enum pipe_shader_type/
Reviewed-by: Charmaine Lee <charmainel@vmware.com>
2016-08-29 12:40:45 -06:00
Jordan Justen
5e76baa2ad i965/hsw: Enable ARB_ES3_1_compatibility extension
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Acked-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com>
2016-08-29 11:23:08 -07:00
Rhys Kidd
b1b7e921f8 r600g: Clean up defined magic numbers for TGSI opcodes
Small code clean up that removes magic numbers where a TGSI
opcode has been defined.

No functional change expected as each opcode is unsupported on
the respective hardware.

Signed-off-by: Rhys Kidd <rhyskidd@gmail.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Tested-by: James Harvey <lothmordor@gmail.com>
2016-08-29 11:03:20 -07:00
Rhys Kidd
d4cb3ee95c r600g: Avoid duplicated initialization of TGSI_OPCODE_DFMA
As reported by Clang, TGSI_OPCODE_DFMA (defined magic number 118) is
currently initialized twice for Cayman and Evergreen.

When Jan Vesely added double precision FMA opcode it did make sense
to locate it immediately after TGSI_OPCODE_DMAD, although this is
out of order.

This change cleans up the prior magic number definition and ensures
any later reordering of this struct will not create problems.

Prior change was:

  commit 015e2e0fce
  Author: Jan Vesely <jan.vesely@rutgers.edu>
  Date:   Sat Jul 2 16:14:54 2016 -0400

      r600g: Add double precision FMA ops

      Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=96782
      Fixes: 54c4d525da ("r600g: Enable FMA on chips that support it")

      Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu>
      Tested-by: James Harvey <lothmordor@gmail.com>
      Signed-off-by: Marek Olšák <marek.olsak@amd.com>

Signed-off-by: Rhys Kidd <rhyskidd@gmail.com>
Reviewed-by: Jan Vesely <jan.vesely@rutgers.edu>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Tested-by: James Harvey <lothmordor@gmail.com>
2016-08-29 11:03:20 -07:00
Rhys Kidd
8ba1fd339c i915g: Fix typo in i915_translate_instruction()
Noticed this error in a debug message whilst reviewing
https://bugs.freedesktop.org/show_bug.cgi?id=97477

This patch doesn't go towards fixing that bug, but at
least may clarify future debug output.

Signed-off-by: Rhys Kidd <rhyskidd@gmail.com>
Reviewed-by: Eric Anholt <eric@anholt.net>
2016-08-29 11:03:20 -07:00
Eric Anholt
60bed14d0f vc4: Handle discards while in control flow.
I missed this while adding loop support because the discard test inside a
loop was crashing before, anyway.  Fixes piglit glsl-fs-discard-04.
2016-08-29 11:03:11 -07:00
Eric Anholt
b9a74fbec7 vc4: Mark when we add discards while lowering blend state. 2016-08-29 10:57:04 -07:00
Eric Anholt
a99d70d105 nir: Update shader info when adding discards
vc4 is about to start using the shader info field to set up discard
handling.

Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
2016-08-29 10:56:59 -07:00
Tim Rowley
fa8f87132a swr: [rasterier core] fix GetRasterizerFunc selection
Only rasterize scissor edges if one or more scissor/viewport
rects are not hottile aligned.

Signed-off-by: Tim Rowley <timothy.o.rowley@intel.com>
2016-08-29 12:42:36 -05:00
Tim Rowley
8e41a65fc5 swr: [rasterizer core] whitespace cleanup
Signed-off-by: Tim Rowley <timothy.o.rowley@intel.com>
2016-08-29 12:42:30 -05:00
Tim Rowley
cc7f655177 swr: [rasterizer jitter] reimplement SCATTERPS
Implement SCATTERPS as a dynamic loop based on mask set bits
instead of a static compile time loop.

Signed-off-by: Tim Rowley <timothy.o.rowley@intel.com>
2016-08-29 12:42:23 -05:00
Tim Rowley
c7e21183a1 swr: [rasterizer core] upper left rule for scissors
Fixes upper left rule for scissors and viewport/scissor macrotile alignment.

Signed-off-by: Tim Rowley <timothy.o.rowley@intel.com>
2016-08-29 12:42:15 -05:00
Tim Rowley
e54df2c7e4 swr: [rasterizer scripts] undef DEFINE_KNOB after usage
Signed-off-by: Tim Rowley <timothy.o.rowley@intel.com>
2016-08-29 12:42:10 -05:00
Tim Rowley
a4efbd14d3 swr: [rasterizer core] minor cleanup to thread initialization
Signed-off-by: Tim Rowley <timothy.o.rowley@intel.com>
2016-08-29 12:42:04 -05:00
Tim Rowley
7472a8ee75 swr: [rasterizer core] remove KNOB_MAX_THREADS
Use dynamic memory allocation for per-thread data

Signed-off-by: Tim Rowley <timothy.o.rowley@intel.com>
2016-08-29 12:41:58 -05:00
Tim Rowley
9e4a482d46 swr: [rasterizer core] track guardbands per viewport rect
Signed-off-by: Tim Rowley <timothy.o.rowley@intel.com>
2016-08-29 12:41:51 -05:00
Tim Rowley
b473bec878 swr: [rasterizer core] per-primitive viewports/scissors
- use per-primitive viewports throughout the pipeline.
- track whether all available scissor rects are tile aligned.
  Causes failures, so not taken into account when choosing rasterizer yet.

Signed-off-by: Tim Rowley <timothy.o.rowley@intel.com>
2016-08-29 12:41:16 -05:00
Tom Stellard
63ed11cde9 radeonsi: Don't use global variables for tess lds
We were allocating global variables for the maximum LDS size
which made the compiler think we were using all of LDS, which
isn't the case.

Reviewed-By: Edward O'Callaghan <funfunctor@folklore1984.net>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-08-29 16:36:46 +00:00
Roland Scheidegger
f48ccb8c07 softpipe: (trivial) honor render_condition_enabled for clear_rt/clear_ds 2016-08-29 18:15:08 +02:00
Roland Scheidegger
c5d7624e1d llvmpipe: (trivial) honor render_condition_enabled for clear_rt/clear_ds 2016-08-29 18:14:49 +02:00
Kai Wasserbäch
4c53267b8f gallium: Use enum pipe_shader_type in set_shader_images()
Signed-off-by: Kai Wasserbäch <kai@dev.carbon-project.org>
Reviewed-by: Brian Paul <brianp@vmware.com>
2016-08-29 09:07:37 -06:00
Kai Wasserbäch
15fe288dea gallium: Use enum pipe_shader_type in set_shader_buffers()
Signed-off-by: Kai Wasserbäch <kai@dev.carbon-project.org>
Reviewed-by: Brian Paul <brianp@vmware.com>
2016-08-29 09:07:33 -06:00
Kai Wasserbäch
532db3b788 gallium: Use enum pipe_shader_type in set_sampler_views()
Signed-off-by: Kai Wasserbäch <kai@dev.carbon-project.org>
Reviewed-by: Brian Paul <brianp@vmware.com>
2016-08-29 09:07:25 -06:00
Kai Wasserbäch
7413625ad3 gallium: Use enum pipe_shader_type in bind_sampler_states() (v2)
v1 → v2:
 - Fixed indentation (noted by Brian Paul)
 - Removed second assert from nouveau's switch statements (suggested by
   Brian Paul)

Signed-off-by: Kai Wasserbäch <kai@dev.carbon-project.org>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
2016-08-29 08:45:48 -06:00
Marek Olšák
ed24d79ed7 gallium/radeon: clear dirty_level_mask when discarding CMASK
This fixes: GL45-CTS.texture_barrier.*

Tested-by: Michel Dänzer <michel.daenzer@amd.com>
2016-08-29 14:23:58 +02:00
Marek Olšák
d301efb400 tgsi/scan: remember sampler view types
Reviewed-by: Brian Paul <brianp@vmware.com>
2016-08-29 14:16:57 +02:00
Nayan Deshmukh
5f0ea3db16 st/vdpau: use temporary buffers while applying filters
Use temporary buffers so that we don't read and write to the
same surface at the same time. We don't need to use linear
layout now.

v2: rebase the patch against reverted change

Signed-off-by: Nayan Deshmukh <nayan26deshmukh@gmail.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
2016-08-29 11:23:56 +02:00
Christian König
77e4424106 st/vdpau: Revert "change the order in which filters are applied(v3)"
This reverts commit 09dff7ae2e.

Turned out this can cause some artifacts in the output. Let's revert
it for now until we have sorted out all issues.

Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Nayan Deshmukh <nayan26deshmukh@gmail.com>
2016-08-29 11:23:51 +02:00
Iago Toral Quiroga
9c9f45b824 i965/vec4: remove the generator hack for dual instanced GS
This hack was introduced in commit 03ac2c7223:
i965/gs: Fix up gl_PointSize input swizzling for DUAL_INSTANCED gs

Specifically to fixup the code we emitted to deal with gl_PointSize inputs
in dual instance mode, where we were emitting a MOV to copy the point
size from .w (where the hardware delivers it) to .x (because code will
expect this to be a float). This meant that we were emitting a MOV
to an ATTR destination that could have a width of 4 (in dual instanced
mode) so it was necessary to fix the execution size and regioning of the
instruction.

Fortunately, Ken fixed this in 67c5d00273:
i965/vec4/gs: Stop munging the ATTR containing gl_PointSize.

by using a WWWW swizzle instead of a MOV, and as the commit log in that
patch states, we no longer emit instructions with ATTR destinations, so
that makes the fixup code in the generator unnecessary.

Reviewed-by: Francisco Jerez <currojerez@riseup.net>
2016-08-29 08:09:09 +02:00
Timothy Arceri
22cec6dc5e glsl: initialise pointer to NULL
Fixes uninitialised warning and covery defect.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2016-08-29 13:13:42 +10:00
Ilia Mirkin
6a5504de2f Update Khronos-supplied headers to r33100
As retrieved from opengl.org and khronos.org. Maintained the APPLE hack
in GL/glext.h manually. Added gl32.h.

Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Acked-by: Dave Airlie <airlied@redhat.com>
2016-08-28 21:41:47 -04:00
Ilia Mirkin
d49a231c33 mesa: add EXT_texture_cube_map_array support
This is identical to OES_texture_cube_map_array support. dEQP has tests
which use this extension. Also it is part of AEP.

Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2016-08-28 21:38:55 -04:00
Ilia Mirkin
4ec1c2bb7f mesa: remove OES_shader_io_blocks enable
This extension should just be available whenever ES 3.1 is available.
With the new extension verification infrastructure, it will only be
enable-able on a #version 310 es shader, rendering the original reason
for having a separate enable moot.

Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2016-08-28 21:38:55 -04:00
Ilia Mirkin
89e95d15f9 main: use KHR_blend_equation_advanced enable for ES 3.2 availability
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Jason Ekstrand <jason.ekstrand@intel.com>
2016-08-28 21:38:55 -04:00
Ilia Mirkin
05b37e20de main: add missing EXTRA_END in OES_sample_variables get check
Fixes: 3002296cb6 (mesa: add GL_OES_shader_multisample_interpolation support)
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Cc: <mesa-stable@lists.freedesktop.org>
2016-08-28 21:38:55 -04:00
Jose Fonseca
09dafb9630 scons: Take indirect gl_and_es_API.xml dependencies in consideration.
Same as 26a8f76ba1.

Trivial.
2016-08-27 22:59:06 +01:00
Ilia Mirkin
5b18e5fd7b docs: sort extensions in relnotes
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
2016-08-27 17:51:44 -04:00
Jason Ekstrand
fb89551047 isl: Allow multisampled array textures
This probably isn't the only thing that needs to be done to get
multisampled array textures working in Vulkan but I think this is all that
ISL really needs and it does fix 8 of the new CTS tests.

Signed-off-by: Jason Ekstrand <jason@jlekstrand.net>
Cc: "12.0" <mesa-stable@lists.freedesktop.org>
Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
Reviewed-by: Chad Versace <chadversary@chromium.org>
2016-08-26 19:00:02 -07:00
Ian Romanick
cf7be70aa7 mesa/version: OpenGL ES 3.2 depends on OES_texture_cube_map_array
This has a separate enable from ARB_texture_cube_map_array.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2016-08-26 15:03:15 -07:00