- 04 Oct, 2020 3 commits
-
-
Neil Roberts authored
This extracts the part of v3d_create_sampler_view that creates and fills in the buffer for the TEXTURE_SHADER_STATE record into a helper function. This will be used in a later patch to update the record when the information changes. v2: Also put the part that creates the buffer into the helper function so that it won’t override the contents of an inflight buffer. Reviewed-by:
Eric Anholt <eric@anholt.net> Part-of: <!6914>
-
Neil Roberts authored
This moves the static function v3d_dirty_tex_state_for_shader_type from v3dx_state.c to v3d_context.c and adds a declaration for it in the header so that it can be used as a general utility function in a later patch. Reviewed-by:
Eric Anholt <eric@anholt.net> Part-of: <!6914>
-
Jonathan Marek authored
turnip doesn't implement pre-emption, this hasn't been a problem with drm backend since the kernel driver doesn't implement it either, however this causes issues with kgsl backend. Signed-off-by:
Jonathan Marek <jonathan@marek.ca> Part-of: <!6994>
-
- 03 Oct, 2020 7 commits
-
-
Vinson Lee authored
Fix defect reported by Coverity Scan. Uninitialized pointer field (UNINIT_CTOR) uninit_member: Non-static class member field location.path is not initialized in this constructor nor in any functions that it calls. Signed-off-by:
Vinson Lee <vlee@freedesktop.org> Reviewed-by:
Marek Olšák <marek.olsak@amd.com> Part-of: <!6905>
-
Vinson Lee authored
Remove code missed in commit 2a490074 ("intel/vec4: Remove all support for Gen8+ [v2]"). Fix defect reported by Coverity Scan. Logically dead code (DEADCODE) dead_error_begin: Execution cannot reach this statement: mcs.swizzle = 80U; Signed-off-by:
Vinson Lee <vlee@freedesktop.org> Reviewed-by:
Ian Romanick <ian.d.romanick@intel.com> Part-of: <!6927>
-
Vinson Lee authored
Fix defect reported by Coverity Scan. Dereference before null check (REVERSE_INULL) check_after_deref: Null-checking rsc suggests that it may be null, but it has already been dereferenced on all paths leading to the check. Fixes: 6173cc19 ("freedreno: gallium driver for adreno") Signed-off-by:
Vinson Lee <vlee@freedesktop.org> Reviewed-by:
Rob Clark <robdclark@chromium.org> Part-of: <!6903>
-
Jason Ekstrand authored
In 536727c4, we switched iris to patching the constant data address into the shader but, thanks to my lack of understanding how iris works, I got the calculation wrong. I didn't realize, we needed to call iris_bo_offset_from_base_address to get the BO offset from the start of instruction state base address. Fixes: 536727c4 "iris: Patch constant data pointers into shaders" Closes: #3596Reviewed-by:
Kenneth Graunke <kenneth@whitecape.org> Part-of: <!6992>
-
Vinson Lee authored
Fix defects reported by Coverity Scan. uninit_member: Non-static class member insns is not initialized in this constructor nor in any functions that it calls. uninit_member: Non-static class member clipVertexOutput is not initialized in this constructor nor in any functions that it calls. Signed-off-by:
Vinson Lee <vlee@freedesktop.org> Reviewed-by:
Karol Herbst <kherbst@redhat.com> Part-of: <!6769>
-
Vinson Lee authored
Fix defects reported by Coverity Scan. Assign instead of compare (PW.ASSIGN_WHERE_COMPARE_MEANT) assign_where_compare_meant: use of "=" where "==" may have been intended Fixes: d8cdcd4a ("radv: use syncobj for wsi fence") Signed-off-by:
Vinson Lee <vlee@freedesktop.org> Reviewed-by:
Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl> Reviewed-by:
Samuel Pitoiset <samuel.pitoiset@gmail.com> Part-of: <!6902>
-
Vinson Lee authored
Fix defect reported by Coverity Scan. Structurally dead code (UNREACHABLE) unreachable: Since the loop increment n++; is unreachable, the loop body will never execute more than once. Signed-off-by:
Vinson Lee <vlee@freedesktop.org> Reviewed-by:
Vasily Khoruzhick <anarsoul@gmail.com> Part-of: <mesa/mesa!6906>
-
- 02 Oct, 2020 30 commits
-
-
Eric Anholt authored
The android platform is not interested in this feature of Mesa. There are currently workarounds for apps on Android, and no support for it in the xmlconfig code. Even if there we do need workarounds eventually, we'll want to bake them in as structs rather than have this awkward external dependency for parsing user-readable data installed by Mesa for Mesa-internal details. This gets rid of the expat dependency in the turnip driver. Note that rather than have more #ifdefs in the file, I've opted to move the code to have more logical locations since the structs refactor had left less-used helpers scattered across the file. Acked-by:
Eric Engestrom <eric@engestrom.ch> Part-of: <!6916>
-
Eric Anholt authored
We don't define the use-16-bit-unicode defines (and our strings are plain utf8), so it's just char. This will let me use some of this code in the absence of expat. Reviewed-by:
Eric Engestrom <eric@engestrom.ch> Part-of: <!6916>
-
Eric Anholt authored
Now that we're not trying to evade preprocessor macro expansion in preprocessor string concatenation, we can use plain old bools in option setup. Reviewed-by:
Eric Engestrom <eric@engestrom.ch> Part-of: <!6916>
-
Eric Anholt authored
We can generate the XML if anybody actually queries it, but this reduces the amount of work in driver setup and means that we'll be able to support driconf option queries on Android without libexpat. This updates the driconf interface struct version for i965, i915, and radeon to use the new getXml entrypoint to call the on-demand xml generation. Note that our loaders (egl, glx) implement the v2 function interface and don't use .xml when that's set, and the X server doesn't use this interface at all. XML generation tested on iris and i965 using adriconf Acked-by:
Eric Engestrom <eric@engestrom.ch> Part-of: <!6916>
-
Eric Anholt authored
Now that we have a single range in the option and start==end means "no range", we can switch over these non-ranged int options. This will ease later refactors. Reviewed-by:
Eric Engestrom <eric@engestrom.ch> Part-of: <!6916>
-
Eric Anholt authored
The only user was radeon/r200, which was using it to have something that looks a lot like an enum value return a float from the config option. Just convert that option to a plain float value (for compat with existing driconfs) with the min and max of its disjoint range as the range. The driver's option handling code already correctly deals with other values in the range. The disjoint range support was a bunch of extra parsing for this dead driver, and made turning driconf into static structs difficult. Reviewed-by:
Eric Engestrom <eric@engestrom.ch> Part-of: <!6916>
-
Eric Anholt authored
I'm heavily editing this code, and having Mesa's style not apply sucks. Reviewed-by:
Eric Engestrom <eric@engestrom.ch> Part-of: <!6916>
-
Eric Anholt authored
The comment about using "malloc"? The strdup man page says 'Memory for the new string is obtained with malloc(3), and can be freed with free(3)' Reviewed-by:
Eric Engestrom <eric@engestrom.ch> Part-of: <!6916>
-
Eric Anholt authored
This gets rid of most of the remaining special case option definitions. Reviewed-by:
Eric Engestrom <eric@engestrom.ch> Part-of: <!6916>
-
Eric Anholt authored
I missed this one in the nested macros conversion. Reviewed-by:
Eric Engestrom <eric@engestrom.ch> Part-of: <!6916>
-
Eric Anholt authored
We're in a "" C string, no need to add extra '\'. Fixes an extra '\' in adriconf's interface. Reviewed-by:
Eric Engestrom <eric@engestrom.ch> Part-of: <!6916>
-
Eric Anholt authored
Since the nested-sections rework, this use in the testcase was the only remaining one. Reviewed-by:
Eric Engestrom <eric@engestrom.ch> Part-of: <!6916>
-
Jason Ekstrand authored
When I copied and pasted the code from MOV_INDIRECT for handling the dependency controls, I missed a subtle difference between MOV_INDIRECT and SHUFFLE. Specifically, MOV_INDIRECT gets lowered to a narrow instruction on Gen7 by the SIMD width lowering whereas SHUFFLE has to split it in the generator. Therefore, the check safety check for whether or not we can use dependency control has to be based on the lowered width rather than the width of the original instruction. Fixes: a8ac61b0 "intel/fs: NoMask initialize the address..." Closes: mesa/mesa#3593Reviewed-by:
Matt Turner <mattst88@gmail.com> Part-of: <mesa/mesa!6989>
-
maurossi authored
Fixes the following building errors: external/mesa/src/intel/vulkan/anv_android.c:627: error: undefined reference to 'mesa_log' ... external/mesa/src/intel/vulkan/anv_device.c:164: error: undefined reference to 'mesa_log' Fixes: 13ea7db7 ("mesa: Promote Intel's simple logging façade for Android to util/") Signed-off-by:
Mauro Rossi <issor.oruam@gmail.com> Acked-by:
Eric Anholt <eric@anholt.net> Part-of: <!6972>
-
Boris Brezillon authored
This way we can catch mismatch between the format string and the arguments. Suggested-by:
Kristian H. Kristensen <hoegsberg@google.com> Signed-off-by:
Boris Brezillon <boris.brezillon@collabora.com> Reviewed-by:
Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com> Part-of: <!6886>
-
Boris Brezillon authored
We expect a float, not an integer. Signed-off-by:
Boris Brezillon <boris.brezillon@collabora.com> Reviewed-by:
Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com> Part-of: <!6886>
-
Bas Nieuwenhuizen authored
The volatile pattern gives me flaky results for 32-bit builds on ChromeOS Android. This is because on 32-bit the volatile 64-bit loads gets split into 2 32-bit loads each. So if we read the lower dword first and then the upper dword, it can happen that the upper dword is already changed but the lower dword isn't yet. In particular for occlusion queries this gives false readings, as the upper dword commonly only constains the ready bit. With the GCC atomic intrinsics we get a call to __atomic_load_8 in libatomic.so which does the right thing. An alternative fix would be to explicitly split the 32-bit loads in the right order and do a bunch of retries if things change, though that gets messy quickly and for 32-bit builds only doesn't feel worth it that much. CC: mesa-stable Reviewed-by:
Samuel Pitoiset <samuel.pitoiset@gmail.com> Part-of: <!6933>
-
Alyssa Rosenzweig authored
Varying stores require us to generate a LEA_ATTR_IMM instruction, which is a load. Signed-off-by:
Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com> Fixes: 0aa08ae2 ("nir: Split NIR_INTRINSIC_TYPE into separate src/dest indices") Part-of: <!6985>
-
Mike Blumenkrantz authored
we do everything ubo-related padded out to the size of a vec4, so ensure that we're getting load offsets using the same alignment Reviewed-by:
Erik Faye-Lund <erik.faye-lund@collabora.com> Part-of: <!6981>
-
Mike Blumenkrantz authored
var->data.binding is only set for vulkan drivers (though it also will get incremented after nir_lower_uniforms_to_ubo), so we have to generate our own values here. to do this, we iterate backwards over the ubos to account for the "first" ubos being at the end of the list, and we must also ensure that we remap the buffer index correctly based on whether we're running our nir_lower_uniforms_to_ubo pass note that running nir_lower_uniforms_to_ubo unconditionally would require us to add a number of checks in this patch for !shader->num_uniforms in order to properly adjust to the altered instructions which become 1-indexed instead of 0-indexed when this pass is run with no uniforms present Reviewed-by:
Erik Faye-Lund <erik.faye-lund@collabora.com> Part-of: <!6981>
-
Mike Blumenkrantz authored
we want to only emit the full ubo block here to be used in the binding table, not each ubo member variable, the likes of which are denoted by having var->data.location != 0 Reviewed-by:
Erik Faye-Lund <erik.faye-lund@collabora.com> Part-of: <!6981>
-
Mike Blumenkrantz authored
if we're creating a block containing multiple variables, we want to create the whole block at once, not just each individual variable, as we have no way to reference individual variables in vulkan due to the requirement for VkDescriptorSetLayoutBinding members to have different binding values Reviewed-by:
Erik Faye-Lund <erik.faye-lund@collabora.com> Part-of: <!6981>
-
Mike Blumenkrantz authored
the nir_variable value is only set for vulkan drivers and will always be 0 here Reviewed-by:
Erik Faye-Lund <erik.faye-lund@collabora.com> Part-of: <!6981>
-
Mike Blumenkrantz authored
using max(Uniform|Storage)BufferRange yields some insane values that aren't consistent with reality affects PIPE_CAP_MAX_SHADER_BUFFER_SIZE and PIPE_SHADER_CAP_MAX_CONST_BUFFER_SIZE Reviewed-by:
Erik Faye-Lund <erik.faye-lund@collabora.com> Part-of: <!6981>
-
Mike Blumenkrantz authored
if a shader has no uniforms then this pass just messes with the instructions pointlessly and forces us to need workarounds later on in ntv Reviewed-by:
Erik Faye-Lund <erik.faye-lund@collabora.com> Part-of: <!6981>
-
Mike Blumenkrantz authored
this extension allows for array nesting with no clear limitations, so we need to ensure that we use the "unrolled" array size in a couple places in order to correctly bind and access these types of arrays in shaders fixes spec@arb_separate_shader_objects@active sampler conflict and others Reviewed-by:
Erik Faye-Lund <erik.faye-lund@collabora.com> Part-of: <!6981>
-
Samuel Pitoiset authored
Like some other v_add instructions, LLVM fails to disassemble v_add3_u32 + clamp. Signed-off-by:
Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by:
Rhys Perry <pendingchaos02@gmail.com> Part-of: <!6961>
-
Samuel Pitoiset authored
LLVM fails to disassemble v_add3 + clamp. Closes: #3563Signed-off-by:
Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by:
Rhys Perry <pendingchaos02@gmail.com> Part-of: <!6961>
-
Italo Nicola authored
Signed-off-by:
Italo Nicola <italonicola@collabora.com> Reviewed-by:
Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com> Part-of: <!6823>
-
Italo Nicola authored
Since commit eb28a366 there's no need for the sext parameter. Signed-off-by:
Italo Nicola <italonicola@collabora.com> Reviewed-by:
Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com> Part-of: <!6837>
-