- Sep 28, 2020
-
-
Dylan Baker authored
-
- Sep 24, 2020
-
-
In 283ad859, radeonsi started using nir_find_var_copies. However, it was also calling nir_lower_var_copies in the optimization loop and the two can end up fighting. The simple solution is to wait to lower copies until the end of the optimization loop. Fixes: 283ad859 Closes: #3550 Reviewed-by:
Marek Olšák <marek.olsak@amd.com> Part-of: <!6841> (cherry picked from commit 472a20c5)
-
the previous version of this leaked a reference to the streamout buffer here thanks to deltragon on my blog for pointing this out! Fixes: 37778fcd ("zink: implement transform feedback support to finish off opengl 3.0") Reviewed-by:
Erik Faye-Lund <erik.faye-lund@collabora.com> Part-of: <mesa/mesa!6457> (cherry picked from commit 79719189)
-
Dylan Baker authored
-
Without this, we end up throwing errors on code along these lines when rendering using single-buffering: GLint att; glGetIntegerv(GL_READ_BUFFER, &att); glGetFramebufferAttachmentParameteriv(GL_READ_FRAMEBUFFER, att, ...); This is because we internally translate GL_BACK (which is what glGetIntegerv returned) to GL_FRONT, which we don't handle in the Desktop GL case. So let's start handling it. This fixes the GLTF-GL33.gtf21.GL2FixedTests.buffer_color.blend_color test for me. Fixes: e6ca6e58 ("mesa: Handle pbuffers in desktop GL framebuffer attachment queries") Reviewed-by:
Marek Olšák <marek.olsak@amd.com> Part-of: <mesa/mesa!6815> (cherry picked from commit 9e13a16c)
-
Dylan Baker authored
-
Without this, scheduled pipelines erroneously tried to create jobs using this template, which can't work, because their dependency jobs don't exist in scheduled pipelines. Unfortunately, this resulted in scheduled pipelines not running silently, without any direct feedback about what's wrong (see https://gitlab.com/gitlab-org/gitlab/-/issues/25490). Fixes: 6c8b9215 "ci: Build kernels and rootfs for x86 devices" Part-of: <mesa/mesa!6802> (cherry picked from commit a1f46d7b)
-
Section 5.11 (Out-of-Bounds Accesses) of the GLSL 4.60 spec says: "In the subsections described above for array, vector, matrix and structure accesses, any out-of-bounds access produced undefined behavior.... Out-of-bounds reads return undefined values, which include values from other variables of the active program or zero." Robustness extensions suggest to return zero on out-of-bounds accesses, however it's not applicable to the arrays of samplers, so just clamp the index. Otherwise instr->sampler_index or instr->texture_index would be out of bounds, and they are used as an index to arrays of driver state. E.g. this fixes such dereference: if (options->lower_tex_packing[tex->sampler_index] != in nir_lower_tex.c CC: <mesa-stable@lists.freedesktop.org> Signed-off-by:
Danylo Piliaiev <danylo.piliaiev@globallogic.com> Reviewed-by:
Eric Anholt <eric@anholt.net> Part-of: <mesa/mesa!6428> (cherry picked from commit f2b17dec)
-
Out-of-bounds writes could be eliminated per spec: Section 5.11 (Out-of-Bounds Accesses) of the GLSL 4.60 spec says: "In the subsections described above for array, vector, matrix and structure accesses, any out-of-bounds access produced undefined behavior.... Out-of-bounds writes may be discarded or overwrite other variables of the active program." Fixes: 12358505 Signed-off-by:
Danylo Piliaiev <danylo.piliaiev@globallogic.com> Reviewed-by:
Eric Anholt <eric@anholt.net> Part-of: <mesa/mesa!6428> (cherry picked from commit 0ba82f78)
-
Out-of-bounds writes could be eliminated per spec: Section 5.11 (Out-of-Bounds Accesses) of the GLSL 4.60 spec says: "In the subsections described above for array, vector, matrix and structure accesses, any out-of-bounds access produced undefined behavior.... Out-of-bounds writes may be discarded or overwrite other variables of the active program. Out-of-bounds reads return undefined values, which include values from other variables of the active program or zero." GL_KHR_robustness and GL_ARB_robustness encourage us to return zero for reads. Otherwise get_io_offset would return out-of-bound offset which may result in out-of-bound loading/storing of inputs/outputs, that could cause issues in drivers down the line. E.g. this fixes such dereference: int vue_slot = vue_map->varying_to_slot[intrin->const_index[0]]; in brw_nir.c CC: <mesa-stable@lists.freedesktop.org> Signed-off-by:
Danylo Piliaiev <danylo.piliaiev@globallogic.com> Reviewed-by:
Eric Anholt <eric@anholt.net> Part-of: <mesa/mesa!6428> (cherry picked from commit 66669eb5)
-
The actual texture might not have been created yet. Gitlab: #3257 CC: mesa-stable Acked-by:
Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com> Reviewed-by:
Marek Olšák <marek.olsak@amd.com> Part-of: <!6788> (cherry picked from commit ade72e67)
-
We didn't handle the case of NULL images/textures for which we should return 0. Signed-off-by:
Lionel Landwerlin <lionel.g.landwerlin@intel.com> Fixes: 397ff297 ("intel: Implement Gen12 workaround for array textures of size 1") Closes: mesa/mesa#3522 Reviewed-by:
Ivan Briano <ivan.briano@intel.com> Part-of: <mesa/mesa!6729> (cherry picked from commit cc3bf00c)
-
From the Vulkan 1.2.154 spec: "If pCounterBufferOffsets is NULL, then it is assumed the offsets are zero." Fix new CTS dEQP-VK.transform_feedback.simple.backward_dependency_no_offset_array. CC: mesa-stable Signed-off-by:
Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by:
Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl> Part-of: <mesa/mesa!6798> (cherry picked from commit 2b99e15d)
-
Signed-off-by:
Rhys Perry <pendingchaos02@gmail.com> Reviewed-by:
Samuel Pitoiset <samuel.pitoiset@gmail.com> Cc: mesa-stable Closes: #3530 Part-of: <!6760> (cherry picked from commit 2228835f)
-
Lets just do depth interop imports by convention between radv and radeonsi for now. The only thing using this should be Vulkan interop anyway. CC: mesa-stable Reviewed-by:
Marek Olšák <marek.olsak@amd.com> Part-of: <!6617> (cherry picked from commit ecc19e98)
-
Dylan Baker authored
To make patches from master better apply
-
It's not really unordered in the sense that it can still stall on ordered things and we don't need a SYNC_NOP for that because it is a SYNC_NOP. However, it also doesn't count when computing instruction distances. Fixes: 18e72ee2 "intel/fs: Add FS_OPCODE_SCHEDULING_FENCE" Reviewed-by:
Francisco Jerez <currojerez@riseup.net> Part-of: <mesa/mesa!6781> (cherry picked from commit f63ffc18)
-
User fence should have 4 QWORD memory space, I updated its CPU address but forgot to update GPU address. Closes: #3513 Fixes: 3d5bed0e "radeonsi: fix user fence space when MCBP is enabled" Acked-by:
Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com> Signed-off-by:
Qiang Yu <yuq825@gmail.com> Part-of: <!6776> (cherry picked from commit 4656e682)
-
Fixes: 659f333b "glsl: add packed for struct types" Reviewed-by:
Marek Olák <marek.olsak@amd.com> Reviewed-by:
Jason Ekstrand <jason@jlekstrand.net> Part-of: <mesa/mesa!6767> (cherry picked from commit 9aa86eb6)
-
Fixes: 0f1ead7b "radv: handle NULL vertex bindings" Reviewed-by:
Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl> Part-of: <mesa/mesa!6773> (cherry picked from commit 7b4eaac6)
-
Fixes: c1ef225d "radv: handle NULL descriptors" Reviewed-by:
Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl> Part-of: <mesa/mesa!6772> (cherry picked from commit ec13622f)
-
Small example from #3271: layout (bindless_sampler) uniform; struct SamplerSparse { sampler2D tex; vec4 size; [...] }; uniform SamplerSparse foo; 'foo' will be marked as bindless but we should only take the assign-as-GLuint64 path for 'tex'. Closes: mesa/mesa#3271 Fixes: 990c8d15 ("mesa: fix setting uniform variables for bindless samplers/images") Reviewed-by:
Marek Olšák <marek.olsak@amd.com> Part-of: <mesa/mesa!6730> (cherry picked from commit 090fc593)
-
Fix defect reported by Coverity Scan. Logically dead code (DEADCODE) dead_error_line: Execution cannot reach this statement: drmSyncobjDestroy(dev->fd, ... Fixes: 64d6f56a ("panfrost: Allocate syncobjs in panfrost_flush") Signed-off-by:
Vinson Lee <vlee@freedesktop.org> Reviewed-by:
Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com> Part-of: <mesa/mesa!6720> (cherry picked from commit ffbdbd63)
-
If radv_layout_can_fast_clear() is false, 028C70_COMPRESSION is unset when the image is rendered to and CMASK isn't updated. This appears to cause FMASK to be ignored and the 0th sample to always be used. Signed-off-by:
Rhys Perry <pendingchaos02@gmail.com> Reviewed-by:
Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl> Closes: mesa/mesa#3449 Fixes: 7b21ce40 ('radv: disable FMASK compression when drawing with GENERAL layout') Part-of: <mesa/mesa!6745> (cherry picked from commit 85cc2950)
-
To avoid using a dangling pointer. Closes: mesa/mesa#1308 Cc: mesa-stable Reviewed-by:
Boyuan Zhang <boyuan.zhang@amd.com> Part-of: <mesa/mesa!6556> (cherry picked from commit 7d853966)
-
To avoid using a dangling pointer. See mesa/mesa#1308 Cc: mesa-stable Reviewed-by:
Boyuan Zhang <boyuan.zhang@amd.com> Part-of: <mesa/mesa!6556> (cherry picked from commit eb60849e)
-
Fix defect reported by Coverity Scan. Argument cannot be negative (NEGATIVE_RETURNS) negative_returns: fd is passed to a parameter that cannot be negative. Fixes: 1ea4ef0d ("freedreno: slurp in decode tools") Signed-off-by:
Vinson Lee <vlee@freedesktop.org> Reviewed-by:
Rob Clark <robdclark@chromium.org> Part-of: <!6696> (cherry picked from commit e607477d)
-
Signed-off-by:
Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com> Fixes: ec37c712 ("bifrost: Emit "d3d" variant of comparison instructions") Part-of: <mesa/mesa!6712> (cherry picked from commit c4f518ce)
-
49d35f3d moved gl_Layer/gl_ViewportIndex/gl_ViewportMask as builtins but fields size wasn't increased. Closes: mesa/mesa#3508 Fixes: 49d35f3d ("glsl: declare gl_Layer/gl_ViewportIndex/gl_ViewportMask as vs builtins") Reviewed-by:
Marek Olšák <marek.olsak@amd.com> Part-of: <mesa/mesa!6688> (cherry picked from commit 8a2a9e9b)
-
Use the lane mask instead of s2 for the register class. Cc: mesa-stable@lists.freedesktop.org Signed-off-by:
Timur Kristóf <timur.kristof@gmail.com> Reviewed-by:
Daniel Schürmann <daniel@schuermann.dev> Part-of: <mesa/mesa!6699> (cherry picked from commit efa1c760)
-
This has been shown to help performance on TGL and DG1. This could be applied to gen9+, but we still need to show if it helps with those platforms. Rework: * Make change in src/intel/vulkan/genX_cmd_buffer.c too. (Ken) * Keep mask as 3 for gen < 12 Cc: mesa-stable@lists.freedesktop.org Signed-off-by:
Jordan Justen <jordan.l.justen@intel.com> Reviewed-by:
Kenneth Graunke <kenneth@whitecape.org> Part-of: <mesa/mesa!6684> (cherry picked from commit 20a4235c)
-
Dylan Baker authored
-
Dylan Baker authored
I didn't backport this correctly, and then accidentally pushed to the stable (not staging branch) so now we have to carry a fixup to avoid force pushing on the stable branch.
-
- Sep 11, 2020
-
-
As shown in the valid SPIR-V below, if one switch case statement directly jumps to the merge block, it has no branches at all and we have to reset the fall variable. Otherwise, it creates an unintentional fallthrough. OpSelectionMerge %97 None OpSwitch %96 %97 1 %99 2 %100 %100 = OpLabel %102 = OpAccessChain %_ptr_StorageBuffer_v4float %86 %uint_0 %uint_37 %103 = OpLoad %v4float %102 %104 = OpBitcast %v4uint %103 %105 = OpCompositeExtract %uint %104 0 %106 = OpShiftLeftLogical %uint %105 %uint_1 OpBranch %97 %99 = OpLabel OpBranch %97 %97 = OpLabel %107 = OpPhi %uint %uint_4 %75 %uint_5 %99 %106 %100 This fixes serious corruption in Horizon Zero Dawn. v2: Changed the code to skip the entire if-block instead of resetting the fallthrough variable. Closes: mesa/mesa#3460 Cc: mesa-stable Signed-off-by:
Samuel Pitoiset <samuel.pitoiset@gmail.com> Signed-off-by:
Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl> Reviewed-by:
Daniel Schürmann <daniel@schuermann.dev> Part-of: <mesa/mesa!6590> (cherry picked from commit 57fba85d)
-
v2 (Jason Ekstrand): - Construct a list of vtn_case objects Signed-off-by:
Karol Herbst <kherbst@redhat.com> Reviewed-by:
Jason Ekstrand <jason@jlekstrand.net> Part-of: <mesa/mesa!2401>
-
Fixes: af81486a "spirv: Simplify our handling of NonUniform" Reviewed-by:
Jason Ekstrand <jason@jlekstrand.net> Part-of: <mesa/mesa!6451> (cherry picked from commit 965b8441)
-
Add a vtn_get_mem_operands() helper to extract memory operand attached to load/store operations. Signed-off-by:
Boris Brezillon <boris.brezillon@collabora.com> Reviewed-by:
Jason Ekstrand <jason@jlekstrand.net> Part-of: <mesa/mesa!6090> (cherry picked from commit 857b9c50)
-
This allows GL 4.5 CTS to pass in full with no flags, other than that I'm not sure if it's a good or bad idea. Reviewed-by:
Roland Scheidegger <sroland@vmware.com> Cc: mesa-stable@lists.freedesktop.org Part-of: <mesa/mesa!6638> (cherry picked from commit b0722cb6)
-
The raw query is meant to be used with MDAPI [1]. When using this metric without this library, we usually selected the TestOa metric to provide some default sensible values (instead of undefined). Historically this TestOa metric lived in the kernel at ID=1. We removed all metrics from the kernel in kernel commit 9aba9c188da136 ("drm/i915/perf: remove generated code"). This fixes the Mesa code to use a valid metric set ID (1 could work some of the time, but not guaranteed). [1] : https://github.com/intel/metrics-discovery v2: Store fallback metric at init time v3: Drop TestOa lookout v4: Skip the existing queries (Marcin) Signed-off-by:
Lionel Landwerlin <lionel.g.landwerlin@intel.com> CC: <mesa-stable@lists.freedesktop.org> Tested-by: Marcin Ślusarz <marcin.slusarz@intel.com> (v1) Reviewed-by:
Kenneth Graunke <kenneth@whitecape.org> Part-of: <mesa/mesa!6438> (cherry picked from commit ec1fa1d5)
-
It's a lot easier to deal with them in RenderDoc when they are in some meaningful order. Signed-off-by:
Marcin Ślusarz <marcin.slusarz@intel.com> Reviewed-by:
Lionel Landwerlin <lionel.g.landwerlin@intel.com> Part-of: <mesa/mesa!5788> (cherry picked from commit a777b253)
-