Brian Paul [Fri, 18 Aug 2017 18:06:09 +0000 (12:06 -0600)]
llvmpipe: add some whitespace between functions in lp_texture.c
Trivial.
Brian Paul [Fri, 18 Aug 2017 15:50:40 +0000 (09:50 -0600)]
mesa: formatting clean-up in syncobj.c
Line wrap to 78 columns, etc. Trivial.
Brian Paul [Fri, 18 Aug 2017 15:50:07 +0000 (09:50 -0600)]
svga: whitespace clean-up in svga_draw_private.h
Trivial.
Timothy Arceri [Mon, 21 Aug 2017 01:29:05 +0000 (11:29 +1000)]
docs: remove link to MissingFunctionality wiki page
Outdated, features.txt is used instead.
Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Timothy Arceri [Mon, 21 Aug 2017 01:44:42 +0000 (11:44 +1000)]
docs: remove MSVC testing/building from help wanted
We are using appveyor for Windows continuous integration.
https://ci.appveyor.com/project/mesa3d/mesa
Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>
Timothy Arceri [Mon, 21 Aug 2017 01:41:19 +0000 (11:41 +1000)]
docs: remove automatic testing from help wanted
Intel has a Jenkins setup and has made the various scripts and
documentation open source.
https://github.com/janesma/mesa_jenkins
Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Timothy Arceri [Mon, 21 Aug 2017 01:39:33 +0000 (11:39 +1000)]
docs: rename TODOs to Legacy Driver TODOs
Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Timothy Arceri [Mon, 21 Aug 2017 01:35:22 +0000 (11:35 +1000)]
docs: remove link to i915g TODOs
This is an unoffical unmaintained driver, we don't really want
people wasting effort trying to improve it.
Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>
Timothy Arceri [Mon, 21 Aug 2017 01:30:33 +0000 (11:30 +1000)]
docs: remove link to radeonsi TODO wiki page
This page is deprecated.
Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Timothy Arceri [Mon, 21 Aug 2017 01:25:18 +0000 (11:25 +1000)]
gallium/docs: remove old llvmpipe TODO
Features are already covered by features.txt like all the other
drivers.
Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>
Timothy Arceri [Mon, 21 Aug 2017 00:42:21 +0000 (10:42 +1000)]
mesa: fix ES only draw if we have vertex positions
This code was separated from the validation code so it could
use used with KHR_no_error paths. The return values were inverted
to reflect the name of the helper, but here the condtion was
mistakenly inverted rather than the return value.
Fixes:
4df2931a87fe (mesa/vbo: move some Draw checks out of validation)
Reported-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Matt Turner [Sun, 9 Jul 2017 21:12:52 +0000 (14:12 -0700)]
glsl: Add prototype for udivmod64()
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Matt Turner [Sun, 9 Jul 2017 21:12:31 +0000 (14:12 -0700)]
glsl: Mark functions static
Cuts 3224 bytes of .text
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Matt Turner [Sun, 9 Jul 2017 21:11:02 +0000 (14:11 -0700)]
i965: Mark functions static
Cuts 300 bytes of .text
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Matt Turner [Fri, 7 Jul 2017 01:46:43 +0000 (18:46 -0700)]
i965/vec4: Use 'class' src_reg, rather than 'struct' src_reg
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Matt Turner [Fri, 7 Jul 2017 00:33:20 +0000 (17:33 -0700)]
i965/vec4: Return float from spill_cost_for_type()
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Matt Turner [Fri, 7 Jul 2017 04:20:15 +0000 (21:20 -0700)]
anv: Move clamp_int64() inside the IVB check
It's only used in the gen7_cmd_buffer_emit_scissor() function.
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Matt Turner [Fri, 7 Jul 2017 01:45:14 +0000 (18:45 -0700)]
glsl: Remove unused private fields
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Matt Turner [Fri, 7 Jul 2017 01:48:03 +0000 (18:48 -0700)]
mesa: Don't compare unsigned for < 0
The INTEL_performance_query spec says
"Performance counter id 0 is reserved as an invalid counter."
GLuint counterid_to_index(GLuint counterid) just returns counterid - 1,
so with unsigned overflow rules, it will generate 0xFFFFFFFF given an
input of 0. 0xFFFFFFFF will trigger the counterIndex >= queryNumCounters
check, so the code worked as is. It just contained a useless comparison.
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Matt Turner [Fri, 7 Jul 2017 01:40:53 +0000 (18:40 -0700)]
egl: Fix inclusion of egl.h+mesa_glinterop.h
Previously clang would warn about redefinition of typedef EGLDisplay. Avoid
this by adding preprocessor guards to mesa_glinterop.h and including it
after EGL.h is indirectly included.
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Marek Olšák [Thu, 17 Aug 2017 14:59:31 +0000 (16:59 +0200)]
radeonsi: don't prefetch VBO descriptors if vertex elements == NULL
Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
Marek Olšák [Sat, 19 Aug 2017 16:33:02 +0000 (18:33 +0200)]
r600g: don't set up and don't call the fetch shader if there are no VS inputs
Matt Turner [Thu, 3 Aug 2017 06:20:00 +0000 (23:20 -0700)]
i965: Optimize reading the destination type
brw_hw_type_to_reg_type() needs to know only whether the file is
BRW_IMMEDIATE_VALUE or not, which is not a valid file for the
destination. gcc and clang will evaluate __builtin_strcmp() at compile
time, so we can use it to pass a constant file for the destination.
text data bss dec hex filename
7816214 346248 420496 8582958 82f72e i965_dri.so before
7816070 346248 420496 8582814 82f69e i965_dri.so after
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Thu, 3 Aug 2017 06:20:39 +0000 (23:20 -0700)]
i965: Mark brw_hw_type_to_reg_type() as a pure function
text data bss dec hex filename
7816886 346248 420496 8583630 82f9ce i965_dri.so before
7816214 346248 420496 8582958 82f72e i965_dri.so after
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Thu, 27 Jul 2017 04:13:03 +0000 (21:13 -0700)]
i965: Hide the register type hardware encodings
So we stop mixing them with the logical enum.
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Thu, 27 Jul 2017 04:08:20 +0000 (21:08 -0700)]
i965: Stop using hardware register types directly
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Wed, 2 Aug 2017 20:41:32 +0000 (13:41 -0700)]
i965: Add brw_hw_reg_type_to_letters() and use it in brw_disasm.c
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Thu, 27 Jul 2017 00:31:36 +0000 (17:31 -0700)]
i965: Move brw_reg_type_letters() as well
And add "to_" to the name for consistency with the other functions in
this file.
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Thu, 27 Jul 2017 00:59:10 +0000 (17:59 -0700)]
i965: Switch to using the logical register types
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Wed, 26 Jul 2017 23:51:58 +0000 (16:51 -0700)]
i965: Add functions to abstract access to register types
Previously the brw_inst{,_set}_{dst,src0,src1}_reg_type() functions
provided access to the hardware encodings for the register types. We
often mixed these with the logical BRW_REGISTER_TYPE_* enums (which
themselves used to be the hardware format!) with bad results.
With that functionality now available with the hw_ versions (see
previous commit), we now add functions that take the logical
BRW_REGISTER_TYPE_* enums and convert into the hardware format and vice
versa. To do the conversion we also have to provide the file.
Note the asymmetry between the two functions: the new getter reads the
file from the instruction word, and to ensure that is always set the
setter writes both the file and the type.
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Wed, 26 Jul 2017 21:25:54 +0000 (14:25 -0700)]
i965: Rename brw_inst's functions that access the register type
Put hw_ in the name so that it's clear these are the hardware encodings.
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Wed, 26 Jul 2017 23:56:10 +0000 (16:56 -0700)]
i965: Index brw_hw_reg_type_to_size()'s table by logical type
I'll be transitioning everything to use the logical types.
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Thu, 27 Jul 2017 00:50:22 +0000 (17:50 -0700)]
i965: Add a brw_hw_type_to_reg_type() function
Will be used in later commits.
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Thu, 27 Jul 2017 00:50:05 +0000 (17:50 -0700)]
i965: Use a common table to translate logical to hardware types
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Wed, 26 Jul 2017 18:08:11 +0000 (11:08 -0700)]
i965: Extract functions dealing with register types to separate file
I'm going to encapsulate all of the logic dealing with register types in
this file.
Rename the parameters for the hardware encodings from type -> hw_type at
the same time.
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Thu, 27 Jul 2017 00:03:12 +0000 (17:03 -0700)]
i965: Reverse file/type arguments to register type functions
I think of the initial arguments as "state" and the last as the actual
subject.
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Tue, 25 Jul 2017 21:25:27 +0000 (14:25 -0700)]
i965: Add support for disassembling 64-bit integer immediates
After the last patch converted things into enums, I helpfully got a
compiler warning about these missing from the switch statement.
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Tue, 25 Jul 2017 21:05:44 +0000 (14:05 -0700)]
i965: Use separate enums for register vs immediate types
The hardware encodings often mean different things depending on whether
the source is an immediate.
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Tue, 25 Jul 2017 20:16:25 +0000 (13:16 -0700)]
i965: Reorder brw_reg_type enum values
These vaguely corresponded to the hardware encodings, but that is purely
historical at this point. Reorder them so we stop making things "almost
work" when mixing enums.
The ordering has been closen so that no enum value is the same as a
compatible hardware encoding.
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Fri, 28 Jul 2017 01:29:50 +0000 (18:29 -0700)]
i965: Validate destination restrictions with vector immediates
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Tue, 1 Aug 2017 19:21:54 +0000 (12:21 -0700)]
i965: Don't let raw-move check be tricked by immediate vector types
UB and B type encodings are the same as UV and VF. Noticed when writing
the following patch.
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Tue, 1 Aug 2017 17:12:56 +0000 (10:12 -0700)]
i965: Only change type of 0.0f to VF if destination stride == 1
The destination stride must be equivalent to a dword if VF is used.
Also, since the only compaction table entires with "i:vf" have the
destination as "r:f" specifically check that the destination is of type
float.
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Tue, 1 Aug 2017 02:13:15 +0000 (19:13 -0700)]
i965: Remove CONT/BREAK from instruction compaction test
These cannot be compacted. A similar mistake was fixed in commit
90eaf01616a8
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Tue, 1 Aug 2017 02:07:42 +0000 (19:07 -0700)]
i965: Test instruction compaction on all supported Gens
Note that there's no point in testing on G45, since its compaction is
the same as Gen5. Same logic applies to Gen7 variants and low-power
parts.
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Wed, 2 Aug 2017 23:17:05 +0000 (16:17 -0700)]
i965: Silence signed/unsigned comparison warning
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Fri, 28 Jul 2017 01:30:14 +0000 (18:30 -0700)]
i965: Move compaction "prepass" into brw_eu_compact.c
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Matt Turner [Mon, 31 Jul 2017 22:35:49 +0000 (15:35 -0700)]
i965: Mark src inst pointer const in compaction code
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
Dave Airlie [Mon, 21 Aug 2017 20:59:07 +0000 (06:59 +1000)]
vulkan: import 1.0.59 headers and xml.
Acked-by: Jason Ekstrand <jason@jlekstrand.net>
Rob Herring [Tue, 15 Aug 2017 21:37:41 +0000 (16:37 -0500)]
Android: Fix LLVM duplicated symbols linking for N and M
Both statically linking libLLVMCore and dynamically linking libLLVM causes
duplicated symbols in gallium_dri.so and it fails to dlopen. We don't
really need to link libLLVMCore, but just need generated headers to be
built first. Dynamically linking to libLLVM instead is enough to do
that. Thanks to Qiang Yu for finding the root cause.
With this change, we can align all versions and just have libLLVM as a
shared lib dependency.
This also requires changes in the M and N versions of LLVM to export the
include paths for libLLVM. AOSP master is okay.
Fixes:
26aee6f4d5a ("Android: rework LLVM build support")
Reported-by: Mauro Rossi <issor.oruam@gmail.com>
Cc: 17.2 <mesa-stable@lists.freedesktop.org>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Signed-off-by: Qiang Yu <Qiang.Yu@amd.com>
Signed-off-by: Rob Herring <robh@kernel.org>
Andres Gomez [Mon, 21 Aug 2017 15:34:42 +0000 (18:34 +0300)]
docs: update calendar, add news item and link release notes for 17.1.7
Signed-off-by: Andres Gomez <agomez@igalia.com>
Andres Gomez [Mon, 21 Aug 2017 15:22:49 +0000 (18:22 +0300)]
docs: add sha256 checksums for 17.1.7
Signed-off-by: Andres Gomez <agomez@igalia.com>
Andres Gomez [Mon, 21 Aug 2017 15:10:18 +0000 (18:10 +0300)]
docs: add release notes for 17.1.7
Signed-off-by: Andres Gomez <agomez@igalia.com>
Leo Liu [Tue, 15 Aug 2017 15:44:08 +0000 (11:44 -0400)]
st/va: add MJPEG for config
To enable MJPEG HW decode
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Leo Liu [Tue, 15 Aug 2017 16:33:21 +0000 (12:33 -0400)]
st/va: reallocate surface with YUYV stream
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Leo Liu [Tue, 15 Aug 2017 18:08:02 +0000 (14:08 -0400)]
st/va: detect MJPEG format from bitstream
To find if the format is supported YUYV by sampling factor which
is embedded from bitstream. So we could use this info for buffer
reallocation on the correct format.
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Leo Liu [Fri, 18 Aug 2017 16:12:05 +0000 (12:12 -0400)]
radeon/uvd: add YUYV format support for target buffer
Make chroma plane optional for YUYV support
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Leo Liu [Tue, 15 Aug 2017 16:58:59 +0000 (12:58 -0400)]
st/va: reallocate surface when interlaced
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Leo Liu [Tue, 15 Aug 2017 16:39:35 +0000 (12:39 -0400)]
radeon/video: MJPEG not support stacked video buffers
So we have to detect it for reallocation of de-interlaced buffers
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Leo Liu [Tue, 15 Aug 2017 13:07:06 +0000 (09:07 -0400)]
st/va: make surface allocate functions more usefully
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Leo Liu [Tue, 15 Aug 2017 17:39:37 +0000 (13:39 -0400)]
radeon/uvd: reconstruct MJPEG bitstream
The current tier 1 mjpeg firmware only supports at the bitstream
level, the later tier 2 support will be at the buffers level with
newer hardware.
Signed-off-by: Leo Liu <leo.liu@amd.com>
Acked-by: Christian König <christian.koenig@amd.com>
Leo Liu [Tue, 15 Aug 2017 15:54:22 +0000 (11:54 -0400)]
st/va: add slice parameter handling for MJPEG
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Leo Liu [Tue, 15 Aug 2017 15:52:26 +0000 (11:52 -0400)]
st/va: add huffman table handling for MJPEG
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Leo Liu [Tue, 15 Aug 2017 15:01:35 +0000 (11:01 -0400)]
st/va: add iq matrix handling for MJPEG
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Leo Liu [Tue, 15 Aug 2017 14:53:22 +0000 (10:53 -0400)]
st/va: add picture parameter handling for MJPEG
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Leo Liu [Tue, 15 Aug 2017 16:43:35 +0000 (12:43 -0400)]
st/va: add handles for MJPEG Buffers
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Leo Liu [Tue, 15 Aug 2017 16:06:24 +0000 (12:06 -0400)]
st/va: create decoder for MJPEG format
Mjpeg doesn't need reference
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Leo Liu [Tue, 15 Aug 2017 14:43:38 +0000 (10:43 -0400)]
st/va: add MJPEG picture to context
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Leo Liu [Wed, 16 Aug 2017 15:49:33 +0000 (11:49 -0400)]
radeon/video: add MJPEG support
v2: add ASIC and Kernel version check
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Leo Liu [Tue, 15 Aug 2017 15:25:08 +0000 (11:25 -0400)]
radeon/uvd: add MJPEG support
There is no need of dpb buffer for mjpeg codec
v2: check dpb_size instead of format
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Leo Liu [Tue, 15 Aug 2017 18:26:15 +0000 (14:26 -0400)]
radeon/uvd: add MJPEG stream type
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Leo Liu [Tue, 15 Aug 2017 14:31:30 +0000 (10:31 -0400)]
vl: add MJPEG picture description
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Leo Liu [Tue, 15 Aug 2017 18:21:16 +0000 (14:21 -0400)]
vl: add MJPEG profile and format
v2: move util video change to here
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Leo Liu [Fri, 18 Aug 2017 16:03:19 +0000 (12:03 -0400)]
radeon/uvd: get the target buffer pitch correct for different format
Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Samuel Pitoiset [Wed, 9 Aug 2017 13:47:22 +0000 (15:47 +0200)]
radeonsi: update non-resident bindless descriptors if needed
Only resident bindless descriptors are currently updated and
re-uploaded, this makes sure that the non-resident ones are
also updated.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Cc: "17.2" <mesa-stable@lists.freedesktop.org>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Louis-Francis Ratté-Boulianne [Fri, 7 Jul 2017 06:53:28 +0000 (02:53 -0400)]
dri3: Move up fourcc utility function
It will be needed in next patches.
Signed-off-by: Louis-Francis Ratté-Boulianne <lfrb@collabora.com>
Reviewed-by: Daniel Stone <daniels@collabora.com>
Daniel Stone [Mon, 31 Jul 2017 14:09:16 +0000 (15:09 +0100)]
egl: Add dma_buf_import_modifiers for glvnd
Make sure we advertise the new entrypoints to libglvnd's EGL dispatch.
Signed-off-by: Daniel Stone <daniels@collabora.com>
Reviewed-by: Eric Anholt <eric@anholt.net>
Reported-by: Emmanuel Gil Peyrot <emmanuel.peyrot@collabora.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=101982
Fixes:
4c412293d0e ("egl: advertise EGL_EXT_image_dma_buf_import_modifiers")
Topi Pohjolainen [Sat, 19 Aug 2017 06:22:22 +0000 (09:22 +0300)]
intel/blorp: Adjust intra-tile x when faking rgb with red-only
v2 (Jason): Adjust directly in surf_fake_rgb_with_red()
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=101910
CC: mesa-stable@lists.freedesktop.org
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Signed-off-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
Dave Airlie [Wed, 16 Aug 2017 01:39:31 +0000 (02:39 +0100)]
ac/nir: fixup layer/viewport export for GFX9.
GFX9 moved where the viewport index export goes.
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Cc: "17.2" <mesa-stable@lists.freedesktop.org>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Jason Ekstrand [Sat, 19 Aug 2017 22:03:39 +0000 (15:03 -0700)]
i965/bufmgr: s/BO_ALLOC_FOR_RENDER/BO_ALLOC_BUSY/
"Alloc for render" is a terrible name for a flag because it means
basically nothing. What the flag really does is allocate a busy BO
which someone theorized at one point in time would be more efficient if
you're planning to immediately render to it. If the flag really means
"alloc a busy BO" we should just call it that.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Jason Ekstrand [Sat, 19 Aug 2017 21:54:42 +0000 (14:54 -0700)]
i965/tex: Change the flags type on create_for_teximage
This matches the actual function declaration.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Christoph Haag [Sat, 19 Aug 2017 23:59:43 +0000 (01:59 +0200)]
mesa: only copy requested compressed teximage cubemap faces
This is analogous to commit 2259b11 which only fixed the regular case
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=102308
Signed-off-by: Christoph Haag <haagch+mesadev@frickel.club>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
Cc: mesa-stable@lists.freedesktop.org
Jason Ekstrand [Sat, 19 Aug 2017 18:03:38 +0000 (11:03 -0700)]
i965/tex: Don't pass samples to miptree_create_for_teximage
In
76e2f390f9863a35, when Topi switched num_samples from 0 to 1 for
single-sampled, he accidentally switched the last parameter in the call
to miptree_create_for_teximage from 0 to 1 thinking it was num_samples
when it was actually layout_flags. Switching from 0 to 1 added the
MIPTREE_LAYOUT_ACCELERATED_UPLOAD flag which causes us to allocate a
busy BO instead of an idle one. This caused the subsequent CPU upload
to consistently stall. The end result was a 15% performance drop in the
SynMark v7 DrvRes microbenchmark. This restores the old behavior and
fixes the performance regression.
Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
Fixes:
76e2f390f9863a356d1419982dec705260d67eff
Bugzilla: https://bugs.freedesktop.org/102260
Cc: mesa-stable@lists.freedesktop.org
Kenneth Graunke [Thu, 17 Aug 2017 07:50:08 +0000 (00:50 -0700)]
anv: Use ISL for emitting null surface states.
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Kenneth Graunke [Thu, 17 Aug 2017 07:44:41 +0000 (00:44 -0700)]
i965: Use ISL for emitting null surface states.
We handle the Sandybridge multisampled 2D surface hack here, rather
than in ISL, because it requires allocating a BO, and is kind of messy.
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Kenneth Graunke [Thu, 17 Aug 2017 07:17:05 +0000 (00:17 -0700)]
isl: Add a null surface fill function.
ISL already offers functions to fill out most kinds of SURFACE_STATE,
so why not handle null surfaces too?
Null surfaces are simple, so we can just take the dimensions, rather
than an entirte fill structure.
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Kenneth Graunke [Thu, 20 Jul 2017 23:33:15 +0000 (16:33 -0700)]
i965: Remove tabs in intel_batchbuffer.c.
Our coding style is to use spaces. Some of this was also messed up
during my bufmgr import series.
(Trivial, just whitespace changes.)
Jason Ekstrand [Thu, 17 Aug 2017 22:27:25 +0000 (15:27 -0700)]
i965/miptree: Return NONE from texture_aux_usage when fully resolved
This little optimization improves the performance of SynMark v7
TexFilterTri by almost 10% on Sky Lake GT4 among other improvements.
We've been doing it for some time but somehow it got dropped during
the miptree refactoring.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Bugzilla: https://bugs.freedesktop.org/102258
Cc: "17.2" <mesa-stable@lists.freedesktop.org>
Jason Ekstrand [Fri, 18 Aug 2017 23:10:39 +0000 (16:10 -0700)]
i965: Stop looking at NewDriverState when emitting 3DSTATE_URB
Looking at NewDriverState is not safe in general. The state atom system
is set up to ensure that new bits that get added to NewDriverState get
accumulated into the set of bits used when emitting atoms but it doesn't
go the other way. If we read NewDriverState, we may not get the full
picture because the per-pipeline state (3D or compute) does not get
added to NewDriverState before state emit is done. It's especially
dangerous to do this from BLORP (either explicitly or implicitly when
BLORP calls gen7_upload_urb) because that does not happen during one of
the normal state upload paths.
This commit solves the problem by whacking all of the per-shader-stage
URB sizes to zero whenever we change the total URB size. We still have
to flag BRW_NEW_URB_SIZE to ensure that the gen7_urb atom triggers but
the actual decision in gen7_upload_urb can now be based entirely on URB
sizes rather than on state atoms. This also makes BLORP correct because
it just asks for a new URB config whenever the vsize is too small and so
any change to the total URB size will trigger blorp to re-emit as well
because 0 < vs_entry_size.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Bugzilla: https://bugs.freedesktop.org/102289
Cc: mesa-stable@lists.freedesktop.org
Kenneth Graunke [Wed, 16 Aug 2017 18:15:24 +0000 (11:15 -0700)]
i965: Mark all EGLimages as non-coherent.
EGLimages are shared with external users, and we don't know what they're
going to do with them. They might scan them out. They might access
them in a way that doesn't work with our explicit clflushing.
It's safest to simply mark them non-coherent.
Chris Wilson caught this problem and wrote a similar (though less
aggressive) patch to solve it; the miptree code has since undergone
a lot of refactoring so I had to rewrite it.
Cc: "17.2" <mesa-stable@lists.freedesktop.org>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Eric Anholt [Fri, 3 Feb 2017 00:20:15 +0000 (16:20 -0800)]
broadcom/genxml: Add V3D 3.3 packet definitions.
This will be used by the new vc5 gallium driver, and a future Vulkan
driver.
Eric Anholt [Thu, 13 Jul 2017 20:20:29 +0000 (13:20 -0700)]
broadcom/genxml: Check the sub-id field when decoding instructions.
VC5 introduces packet variants where the same opcode has behavior that is
decided by a sub-id field in the early bits of the packet. Keep iterating
over packets until we find the one with the matching sub-id.
Eric Anholt [Mon, 19 Dec 2016 19:11:44 +0000 (11:11 -0800)]
broadcom/genxml: Emit code for default headers for structs as well.
In the vc5 NIR backend, I want to use the XML code-generation to set up
pack/unpack of structs for the texture uniforms, and setting up the
unpacked copy needs a default header.
Eric Anholt [Sat, 21 Jan 2017 05:22:15 +0000 (16:22 +1100)]
anv: Move a comment that got left behind in the u_vector refactor.
Marek Olšák [Tue, 15 Aug 2017 00:50:22 +0000 (02:50 +0200)]
gallium/radeon: remove old_fence parameter from r600_gfx_write_event_eop
just use the new scratch buffer.
Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
Marek Olšák [Tue, 15 Aug 2017 00:40:30 +0000 (02:40 +0200)]
radeonsi/gfx9: prevent a GPU hang after a timestamp event
Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
Marek Olšák [Tue, 15 Aug 2017 15:51:05 +0000 (17:51 +0200)]
radeonsi: don't use CLEAR_STATE on SI
This fixes random hangs with Unigine Valley.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=102201
Fixes:
064550238ef0 ("radeonsi: use CLEAR_STATE to initialize some registers")
Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
Jon Turney [Thu, 17 Aug 2017 21:10:52 +0000 (22:10 +0100)]
Fix build when HAVE_LIBDRM isn't defined
make[4]: Entering directory '/wip/mesa/build/src/gallium/targets/dri'
CXXLD gallium_dri.la
../../../../src/gallium/auxiliary/pipe-loader/.libs/libpipe_loader_static.a(libpipe_loader_static_la-pipe_loader.o): In function `pipe_loader_get_driinfo_xml':
/mesa/build/src/gallium/auxiliary/pipe-loader/../../../../../src/gallium/auxiliary/pipe-loader/pipe_loader.c:117: undefined reference to `pipe_loader_drm_get_driinfo_xml'
b4ff5e90 uses pipe_loader_get_driinfo_xml() unconditionally in
pipe_loader.c, but it's definition in pipe_loader_get_driinfo_xml() is only
built if HAVE_LIBDRM.
Arrange to always use the default XML if HAVE_LIBDRM isn't defined.
Signed-off-by: Jon Turney <jon.turney@dronecode.org.uk>
Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
Kenneth Graunke [Fri, 18 Aug 2017 06:41:50 +0000 (23:41 -0700)]
i965: Fix missing newlines in perf_debug messages.
perf_debug() doesn't append a newline for you.
Ilia Mirkin [Thu, 17 Aug 2017 02:18:39 +0000 (22:18 -0400)]
glsl: add a few missing int64 constant propagation cases
Fixes KHR-GL45.shader_ballot_tests.ShaderBallotAvailability, which
causes some silly swizzles to appear, triggering this optimization to
get hit.
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Dave Airlie <airlied@redhat.com>
Cc: mesa-stable@lists.freedesktop.org
Timothy Arceri [Thu, 17 Aug 2017 23:32:15 +0000 (09:32 +1000)]
glsl: set old ldexp operand to NULL when lowering
This fixes an assert during IR validation in LLVMpipe.
Fixes:
e2e2c5abd279 (glsl: calculate number of operands in an expression once)
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=102274
Reviewed-by: Brian Paul <brianp@vmware.com>
Tested-by: Brian Paul <brianp@vmware.com>