Commit Graph

129091 Commits

Author SHA1 Message Date
Marcin Ślusarz 4015e1876a intel: add INTEL_DEBUG expected value in declaration
Signed-off-by: Marcin Ślusarz <marcin.slusarz@intel.com>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
Reviewed-by: Eric Anholt <eric@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6732>
2020-10-06 18:43:07 +00:00
Sagar Ghuge bcfec61d1e anv: Add driconf option to disable compression for 16bpp format
On Fallout4, enabling HIZ_CCS_WT compression for D16_UNORM format
regress the performance by 2%, in order to avoid that disable
compression via driconf option.

The experiment showed that, running Fallout4 with HIZ performs better
than HIZ_CCS and HIZ_CCS_WT. Reason behind that is the benchmark uses
the depth pass with D16_UNORM surfaces format which fills the L3 cache
and next pass doesn't make use of it where we end up clearing cache.

v2:
- Don't add conditional check in isl (Nanley, Jason)
- Move disable_d16unorm_compression flag to instance (Lionel)
- Use plane_format.isl_format (Nanley)

v3:
- Add more descriptive comment (Marcin Ślusarz)

Signed-off-by: Sagar Ghuge <sagar.ghuge@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6734>
2020-10-06 18:27:25 +00:00
Sagar Ghuge 49593205b9 anv: Factor out dri option initialization code in separate function
Signed-off-by: Sagar Ghuge <sagar.ghuge@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6734>
2020-10-06 18:27:25 +00:00
Karol Herbst 7c6f1d3bf9 clover/nir: extract constant buffer into its own section
Fixes test_basic constant_source

Signed-off-by: Karol Herbst <kherbst@redhat.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Francisco Jerez <currojerez@riseup.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6569>
2020-10-06 17:30:41 +00:00
Karol Herbst adbfff6eae clover: bind constant buffer if one is provided
We will use that with NIR as it is easier to manage the constant buffer
inside clover instead of letting all drivers to deal with it.

Signed-off-by: Karol Herbst <kherbst@redhat.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Francisco Jerez <currojerez@riseup.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6569>
2020-10-06 17:30:41 +00:00
Karol Herbst af85985250 clover/util: add id_type_equals to support symbols with multiple sections
Signed-off-by: Karol Herbst <kherbst@redhat.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6569>
2020-10-06 17:30:41 +00:00
Eric Anholt 7fb4ab9ec1 driconf: Restore the ability to override driconf with the environment.
I distinctly remember testing this during development, yet clearly deleted
the code.

I pulled the parseValue code back up to the top where it used to be since
we have to use it, rather than just adding a prototype.

Fixes: 8a05d6ffc6 ("driconf: Make the driver's declarations be structs instead of XML.")
Reviewed-by: Michel Dänzer <mdaenzer@redhat.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7012>
2020-10-06 17:03:49 +00:00
Eric Anholt 455bfecdff driconf: Make sure that the range check on the defaults actually works.
Fixes: 8a05d6ffc6 ("driconf: Make the driver's declarations be structs instead of XML.")
Reviewed-by: Michel Dänzer <mdaenzer@redhat.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7012>
2020-10-06 17:03:49 +00:00
Daniel Stone 24b4a63b3d CI: Re-enable Panfrost T7xx CI
Lab maintenance is done now.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7032>
2020-10-06 16:37:27 +00:00
Marek Olšák 3dc00c33f0 gallium/u_threaded_context: fix use-after-free in transfer_unmap
discovered by valgrind

Fixes: fd6a5e112a

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6952>
2020-10-06 16:18:40 +00:00
Marek Olšák 706fef711b gallium/u_threaded_context: always flush asynchronously if requested
This can reduce overhead depending on whether st/mesa uses the ASYNC flag
and the app flushes often.

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6952>
2020-10-06 16:18:40 +00:00
Marek Olšák 28256d3d7b gallium/u_threaded_context: don't call memcpy in tc_set_constant_buffer
In sysprof, the CPU time spend in tc_set_constant_buffer drops
from 7% to 1.4% in a release build. It doesn't make sense to me.

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6952>
2020-10-06 16:18:40 +00:00
Marek Olšák ed3c5fe469 radeonsi: implement GL_INTEL_blackhole_render
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7031>
2020-10-06 15:59:08 +00:00
Marek Olšák bad7b38aa1 radeonsi: remove dead variable postponed_kill
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7031>
2020-10-06 15:59:08 +00:00
Marek Olšák d5575ca7a1 gallium/util: add set_frontend_noop into driver_noop and u_threaded_context
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7031>
2020-10-06 15:59:08 +00:00
Marek Olšák 72fa3372cc util/idalloc: resize if ID is too large for reservation
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7031>
2020-10-06 15:59:07 +00:00
Marek Olšák 155b1b1792 st/mesa: enable GL name reuse for queries based on the driconf option
Fixes: a56849ddda

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7031>
2020-10-06 15:59:07 +00:00
Marek Olšák 6f7446bda5 driconf: enable force_glsl_extensions_warn for viewperf
Discovered by Pierre-Eric Pelloux-Prayer.

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7031>
2020-10-06 15:59:07 +00:00
Marek Olšák a8b4e690cf driconf: force the vendor string to NVIDIA to fix viewperf energy tests
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7031>
2020-10-06 15:59:07 +00:00
Marek Olšák 5827fe898e gl_marshal.py: inline print_sync_dispatch
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7031>
2020-10-06 15:59:07 +00:00
Marek Olšák bcd6b0c685 mesa: factor out layout parsing for glInterleavedArrays
glthread will use it.

Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7031>
2020-10-06 15:59:07 +00:00
Jason Ekstrand 60825a542d nir/constant_folding: Fold load_deref of nir_var_mem_constant
Reviewed-by: Eric Anholt <eric@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6974>
2020-10-06 15:42:03 +00:00
Jason Ekstrand 481b7538ab nir: Validate constant initializers
Reviewed-by: Eric Anholt <eric@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6974>
2020-10-06 15:42:03 +00:00
Jason Ekstrand 1ada83504f nir/constant_folding: Use nir_shader_instruction_pass
This gets rid of so much boilerplate...

Reviewed-by: Eric Anholt <eric@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6974>
2020-10-06 15:42:03 +00:00
Jason Ekstrand 9df1ff3678 nir/constant_folding: Use the builder
Reviewed-by: Eric Anholt <eric@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6974>
2020-10-06 15:42:03 +00:00
Mike Blumenkrantz 3b11b37a1b radv: remove VkPipelineCacheCreateInfo::flags assert
flags are handled, so this just crashes for no reason

Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7030>
2020-10-06 15:12:35 +00:00
Nanley Chery 3f3a5f3489 iris: Fix a fast-clear skipping optimization
When support for multi-slice fast-clears was introduced for color
surfaces, an existing optimization for skipping fast-clears was not
updated (this optimization assumed single-slice fast-clears). As a
result, the driver began to skip multi-layer fast-clears if just the
first slice was in the CLEAR state (ignoring the state of the others).

A Civilization VI trace was the only workload I found to make use of
this optimization and it did so for 2D, non-array textures. Therefore,
this fix simply checks that the depth of the clear box is 1. It also
moves the single-slice aux-state query closer to the optimization to
clarify the need for the depth check.

Enables iris to pass a case of the fcc-write-after-clear piglit test,
[fast-clear tracking across layers 0 -> 1 -> (0,1)].

Fixes: 393f659ed8 ("iris: Enable fast clears on other miplevels and layers than 0.")
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6973>
2020-10-06 15:05:30 +00:00
Mike Blumenkrantz c416adfb2d anv: remove VkPipelineCacheCreateInfo::flags assert
flags are handled, so this just crashes for no reason

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7029>
2020-10-06 10:29:33 -04:00
Lionel Landwerlin 9ad4b8b924 intel/dev: add a small non installable tool to print device info
Mostly for debug purposes.

$ ./build/src/intel/dev/intel_device_info
/dev/dri/renderD128:
   name: Intel(R) UHD Graphics 620 (WHL GT2)
   gen: 9
   PCI id: 0x3ea0
   revision: 2
   slice0.subslice0: 11111111
   slice0.subslice1: 11111111
   slice0.subslice2: 11111111
   slices: 1
   subslices: 3
   EUs: 24
   EU threads: 168
   LLC: 1
   threads per EU: 7
   L3 banks: 4
   max VS  threads: 336
   max TCS threads: 336
   max TES threads: 336
   max GS  threads: 336
   max WM  threads: 256
   max CS  threads: 56
   timestamp frequency: 12000000

v2: Missing license (Marcin)
    Fix stderr usage (Marcin)

v3: Reformat topology printing (Marcin)

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Marcin Ślusarz <marcin.slusarz@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6957>
2020-10-06 12:31:16 +00:00
Mike Blumenkrantz 61c095f09a zink: enable pipe caps for ARB_timer_query
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6923>
2020-10-06 12:17:31 +00:00
Mike Blumenkrantz bb603352b6 zink: add pipe_context::get_timestamp hook
this uses VK_EXT_calibrated_timestamps to read a timestamp immediately from
the device without using a batch, which is what the gallium api expects

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6923>
2020-10-06 12:17:31 +00:00
Mike Blumenkrantz b551ee22df zink: handle TIME_ELAPSED queries
these just need to write a timestamp at the start to diff against

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6923>
2020-10-06 12:17:31 +00:00
Mike Blumenkrantz 7a40b734ee zink: handle timestamp queries
a lot of this is just rejiggering code to allow timestamp queries to
take the same codepaths as "normal" queries instead of even more explicitly
special casing everything

key point here is that we need to convert vulkan-level timestamp "ticks" to
nanoseconds like the gallium api expects

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6923>
2020-10-06 12:17:31 +00:00
Lionel Landwerlin 79f3544412 intel/perf: fix crash when no perf queries are supported
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Fixes: ec1fa1d51f ("intel/perf: fix raw query kernel metric selection")
Reviewed-by: Marcin Ślusarz <marcin.slusarz@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7024>
2020-10-06 10:20:57 +00:00
Michel Zou 82563b6a9f util: drop non-posix header fnmatch
Seems fnmatch usage was removed but not the include

Reviewed-by: Eric Anholt <eric@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7013>
2020-10-06 08:33:09 +00:00
Daniel Stone f0707e977b CI: Disable Panfrost T7xx CI
The lab is having some more maintenance work this morning to continue
expanding capacity and improving resilience.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7023>
2020-10-06 09:09:09 +01:00
Mike Blumenkrantz 2b977adff8 xmlconfig: fix scandir_filter
this was changed from a fnmatch usage to strcmp, and the return value
was flipped, breaking matching

also fix the formatting of the changed lines

Fixes: 4f37161a8f2: ("util/xmlconfig: Indent to Mesa style.")

Reviewed-by: Eric Anholt <eric@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7018>
2020-10-06 04:43:12 +00:00
Jason Ekstrand a0c13c9de9 spirv: Make the clc_shader const
Reviewed-by: Jesse Natalie <jenatali@microsoft.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7016>
2020-10-06 04:26:22 +00:00
Eric Anholt e33f9dbc1a turnip/kgsl: Add strerror decode in BO init failure.
Just covering more of the error paths.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7014>
2020-10-05 22:42:14 +00:00
Eric Anholt 5d3aeafa77 turnip: Report device loss through _mesa_loge() instead of fprintf.
We drop the file/line, but there are only a couple of places calling this
and they have unique strings anyway.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7014>
2020-10-05 22:42:14 +00:00
Eric Anholt 50f25da2b5 turnip: Always enable TU_DEBUG=startup on debug drivers.
For Android, it's hard to inject environment variables for testing, and I
figure if you've got a debug driver then you'd love to see about driver
init failures anyway.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7014>
2020-10-05 22:42:14 +00:00
Eric Anholt a4d9a9d11c turnip: Extend the coverage of TU_DEBUG=startup.
I found while debugging KGSL that we were missing failure output for a
bunch of the error paths.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7014>
2020-10-05 22:42:14 +00:00
Eric Anholt 80869f0bc3 turnip: Mark the vk_errorf helper as bring printflike.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7014>
2020-10-05 22:42:13 +00:00
Eric Anholt 01de452b5d turnip: Use mesa's normal PRINTFLIKE macro instead of our own.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7014>
2020-10-05 22:42:13 +00:00
Eric Anholt a7bc2f8d1b turnip: Don't expose VK_ANDROID_native_buffer on non-Android.
The code is only there when compiling that platform.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7014>
2020-10-05 22:42:13 +00:00
Jason Ekstrand d82826ad44 anv: Implement VK_EXT_transform_feedback on Gen7
Things work a little different on Gen7 than they do on Gen8+.  In
particular, SOBufferEnable lives in 3DSTATE_STREAMOUT but BufferPitch
lives in 3DSTATE_SO_BUFFER.  This leaves us having to marshal data
around a bit more than we did on Gen8.  Still, it's not too bad.

Normally, I don't spend much time on Gen7 but XFB just became a hard
requirement for DXVK so it stopped working for all our Haswell users.
Let's get them happily playing their games again. 😸

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/3532
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6997>
2020-10-05 22:34:07 +00:00
Mauro Rossi 9831888b68 android: panfrost: use python3 for generated sources rules
Scripts are python3 ready

Signed-off-by: Mauro Rossi <issor.oruam@gmail.com>
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6996>
2020-10-05 21:23:56 +00:00
Mauro Rossi 27921171e3 android: pan/bi: Use new disassembler (v2)
(v2) bifrost_gen_disasm.c generated source belongs to libpanfrost_bifrost_disasm

Fixes the following build errors, which happen with Android P, but not with Android Q

FAILED: out/target/product/x86_64/obj_x86/SHARED_LIBRARIES/gallium_dri_intermediates/LINKED/gallium_dri.so
...
external/mesa/src/panfrost/bifrost/disassemble.c:678: error: undefined reference to 'bi_disasm_fma'
external/mesa/src/panfrost/bifrost/disassemble.c:679: error: undefined reference to 'bi_disasm_add'

Fixes: 792b51713 ("android: pan/bi: Use new disassembler")
Signed-off-by: Mauro Rossi <issor.oruam@gmail.com>
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6996>
2020-10-05 21:23:56 +00:00
Jonathan Marek 8163c818e3 turnip: implement timestamp fences/semaphores for kgsl backend
This gets fences and semaphores working for kgsl (minus import/export).

Signed-off-by: Jonathan Marek <jonathan@marek.ca>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7000>
2020-10-05 21:07:01 +00:00
Alejandro Piñeiro 462d62351d broadcom/simulator: update to a newer simulator
Some headers were moved, and macros renamed.

Reviewed-by: Eric Anholt <eric@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7007>
2020-10-05 22:08:43 +02:00