Faith Ekstrand [Tue, 31 Jan 2023 02:12:03 +0000 (20:12 -0600)]
nvk: Add a bo size to nvk_descriptor_set
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:03 +0000 (20:12 -0600)]
nvk: Assert that descriptor buffer access stays in-bounds
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:03 +0000 (20:12 -0600)]
nvk: Advertise VK_KHR_depth_stencil_resolve
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:03 +0000 (20:12 -0600)]
nvk: Advertise MSAA via image format properties
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:03 +0000 (20:12 -0600)]
nvk: Stop advertising higher framebufferNoAttachmentsSampleCounts
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:03 +0000 (20:12 -0600)]
nvk: Replace gl_SamplePosition with fract(gl_FragCoord.xy)
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:03 +0000 (20:12 -0600)]
nvk: Use meta for MSAA resolves
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:03 +0000 (20:12 -0600)]
nvk/meta: Fix restore for descriptor set 0
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:03 +0000 (20:12 -0600)]
vulkan/meta: Add support for MSAA resolves
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:03 +0000 (20:12 -0600)]
vulkan/meta: Rename vk_meta_blit.c to vk_meta_blit_resolve.c
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:03 +0000 (20:12 -0600)]
vulkan/meta: Support writing stencil as iterative discard
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:03 +0000 (20:12 -0600)]
vulkan/meta: Break the guts of blit into a helper
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:03 +0000 (20:12 -0600)]
vulkan/meta: Add a helper for building texture ops
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:03 +0000 (20:12 -0600)]
vulkan/meta: Bind whole LODs of 3D blit destinations
Instead of only binding the layers we need, bind the whole LOD. In
particular, we now set a layer range of [0, 1] when creating the image
view but a layerCount of minify(depth, level) in VkRenderingInfo. While
still a bit out of spec, this is more in line with how 3D image views
typically work for sampled and storage images and allows us to avoid
creating 2D images views which would require 2D_ARRAY_COMPATIBLE_BIT.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:03 +0000 (20:12 -0600)]
nvk: Fill out sample locations on Maxwell B+
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:03 +0000 (20:12 -0600)]
nvk: Stop creating a new upload BO every time
We intended this optimization for the case where we're uploading more
data than we had in the previous upload BO. If there is no previous
upload BO, we always want to set it to the new one.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:02 +0000 (20:12 -0600)]
nvk: Set correct multisample regs for graphics pipelines
This adds SAMPLE_MASK_*, ANTI_ALIAS_CONTROL, and drops ANTI_ALIAS which
we set in BeginRendering().
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:02 +0000 (20:12 -0600)]
nvk: Pass through a shader key for fragment shaders and MSAA
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Thu, 3 Aug 2023 20:54:09 +0000 (15:54 -0500)]
nvk: Use the right view format for stencil texturing
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:02 +0000 (20:12 -0600)]
nvk: Support copies of MSAA images
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:02 +0000 (20:12 -0600)]
nvk: Handle multisampled render targets properly
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:02 +0000 (20:12 -0600)]
nvk: Handle zero color attachments better
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:02 +0000 (20:12 -0600)]
nvk: Stop asserting on MSAA
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:02 +0000 (20:12 -0600)]
nouveau/parser: Handle SET_ANTI_ALIAS_SAMPLE_POSITIONS
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:02 +0000 (20:12 -0600)]
nouveau/parser: Sort METHOD_ARRAY_SIZES
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:02 +0000 (20:12 -0600)]
nil: Add an offset4d struct and some helpers
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:02 +0000 (20:12 -0600)]
nil: Properly support MSAA
We had a num_samples field in nil_image but didn't do anything with it
for layout. This adds real code for MSAA which seems analygous to the
code in nvc0_miptree.c and seems to match HW based on my image layout
R/E crucible test.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:02 +0000 (20:12 -0600)]
nil: Use ONE for the anixotropic coarse spread function
No idea if it's what we want but this is what nouveau does and it's good
to be consistent for now.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:02 +0000 (20:12 -0600)]
nvk: Implement CS invocations statistics queries
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:02 +0000 (20:12 -0600)]
nouveau/mme: Add a mul64 helper
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:02 +0000 (20:12 -0600)]
nvk: Implement DispatchIndirect
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:02 +0000 (20:12 -0600)]
nvk: Break the guts of CmdDispatch into a helper
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Thomas H.P. Andersen [Fri, 7 Oct 2022 15:09:19 +0000 (17:09 +0200)]
nvk: advertize KHR_relaxed_block_layout
Test run totals:
Passed: 16/32 (50.0%)
Failed: 0/32 (0.0%)
Not supported: 16/32 (50.0%)
Warnings: 0/32 (0.0%)
Not supported is: "Physical storage buffer pointers not supported", so
waiting for VK_KHR_buffer_device_address.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:02 +0000 (20:12 -0600)]
nvk: Implement VK_EXT/KHR_buffer_device_address
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Emma Anholt [Fri, 28 Oct 2022 22:43:40 +0000 (15:43 -0700)]
nvk: Use depth_clamp_enable to select PIXEL_*_Z_CLAMP.
Fixes most of "-t depth_clamp" (just point_list fails, but other
point_list stuff fails too)
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Emma Anholt [Sat, 29 Oct 2022 15:48:19 +0000 (08:48 -0700)]
nvk: Fix missing init of the stages to sync against.
Fixes:
d8a0dcb234cd ("nvk: Events")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Emma Anholt [Fri, 28 Oct 2022 23:19:30 +0000 (16:19 -0700)]
nvk: Remove duplicate (disabled) point sprite setup.
There's another copy of this above, with just slightly different unused
state.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Dave Airlie [Mon, 31 Oct 2022 03:48:43 +0000 (13:48 +1000)]
nvk: fix copy lower address extraction
this was missing an 0xf
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Thomas H.P. Andersen [Mon, 24 Oct 2022 00:13:31 +0000 (02:13 +0200)]
nvk: sort extensions
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Thomas H.P. Andersen [Mon, 24 Oct 2022 00:13:08 +0000 (02:13 +0200)]
nvk: fix initialization override
this is already set a few lines up
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Thomas H.P. Andersen [Mon, 24 Oct 2022 00:11:01 +0000 (02:11 +0200)]
nvk: drop dead assignment
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Thomas H.P. Andersen [Mon, 24 Oct 2022 00:10:19 +0000 (02:10 +0200)]
nvk: drop dead assignment
p_format is not used again after this assignment
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:02 +0000 (20:12 -0600)]
nouveau/headers: Add generated headers to dependencies
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Thomas H.P. Andersen [Mon, 3 Oct 2022 21:54:21 +0000 (23:54 +0200)]
nvk: CmdPushDescriptorSetWithTemplateKHR
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Add a helper for pushing descriptors
This reduces the boilerplate a bit.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Thomas H.P. Andersen [Wed, 28 Sep 2022 16:15:35 +0000 (18:15 +0200)]
nvk: KHR_descriptor_update_template
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Thomas H.P. Andersen [Fri, 14 Oct 2022 16:24:54 +0000 (18:24 +0200)]
nvk: advertise KHR_sampler_mirror_clamp_to_edge
Test run totals:
Passed: 3162/13944 (22.7%)
Failed: 0/13944 (0.0%)
Not supported: 10782/13944 (77.3%)
Warnings: 0/13944 (0.0%)
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Thomas H.P. Andersen [Sun, 9 Oct 2022 20:40:46 +0000 (22:40 +0200)]
nvk: advertise EXT_private_data
Test run totals:
Passed: 69/112 (61.6%)
Failed: 0/112 (0.0%)
Not supported: 43/112 (38.4%)
Warnings: 0/112 (0.0%)
Waived: 0/112 (0.0%)
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Thomas H.P. Andersen [Sun, 9 Oct 2022 20:40:17 +0000 (22:40 +0200)]
nvk: advertise KHR_image_format_list
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Thomas H.P. Andersen [Sun, 9 Oct 2022 20:39:01 +0000 (22:39 +0200)]
nvk: advertise KHR_shader_non_semantic_info
Test run totals:
Passed: 8/8 (100.0%)
Failed: 0/8 (0.0%)
Not supported: 0/8 (0.0%)
Warnings: 0/8 (0.0%)
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Advertise VK_KHR_storage_buffer_storage_class
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Move more states to dynamic
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Advertise VK_EXT_extended_dynamic_state3
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Implement VK_EXT_border_color_swizzle
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
vulkan: Add a helper for swizzling color values
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Advertise custom border color features
We were advertising the extension string but not filling out the
features struct. Now we should be properly advertising it "for real".
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nil: Fix include guards in nil_image.h
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Use 2D array views for 3D storage images
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Advertise VK_KHR_maintenance1
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Support 2D views of 3D images
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nil: Add a helper for getting 2D views of 3D images
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Support copies between 3D and 2D images
This requires that we unify and only have one layer count for the copy
region so we arbitrarily choose extent_el.depth. We could choose layer
count but we already have a VkExtent3D so we may as well use it.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Bind 3D images as 3D for clears
Normally, Vulkan doesn't support binding 3D image views for rendering
but we support it in NVK. If we bind it as a 2D array, that requires
setting 2D_ARRAY_COMPATIBLE_BIT to get a 2D array layout.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Implement VK_EXT_pci_bus_info
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nouveau: Add PCI information to nv_device_info
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Tell WSI we don't support legacy scanout
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Advertise VK_KHR_separate_depth_stencil_layout
We entirely ignore image layouts on NVIDIA so this is trivial.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Flush the current pushbuf before allocating a new one
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Advertise VK_KHR_imageless_framebuffer
Handled entirely in common code
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Enable VK_KHR_create_renderpass2
Handled entirely in common code
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Stop leaking command pool BOs
There are a couple of bugs here. First, vk_command_pool_finish() may
destroy command buffers which may end up returning BOs to the pool so we
need to wait to call nvk_cmd_pool_destroy_bos() until after that's
happened. Second, we weren't actually adding allocated BOs to the BO
list in nvk_cmd_buffer so they weren't ever getting returned.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Don't crash if we fail to allocate a push BO
Currently, we continue just fine until nvk_EndCommandBuffer calls
nvk_cmd_buffer_flush_push() and it crashes tring to look at
cmd->push_bo.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Events
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Use poll for BO waits
The nouveau ioctl doesn't support timeouts but poll() does.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:01 +0000 (20:12 -0600)]
nvk: Use mme_load_addr64()
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nouveau/parser: Handle 6F methods
These are the methods below 0x100 which exist on all subchannels.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nvk: Use a normal DMA for CmdUpdateBuffer
Sure, inline data is neat and all, but our upload buffers are better set
up for handling large quantities of data.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nvk: Handle large command buffer uploads better
Change our assertion from a < to a <=. Also, if the size of the upload
is greater than the amount of space we have left in the old BO, don't
set cmd->upload_bo to point to the new thing. Instead, let the next
upload carry on with the old buffer since it has more room.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nvk: Implement vkCmdCopyQueryPoolResults()
One day, we may want to make this a compute shader like RADV uses but
this gets us up-and-going without more infra and it's probably what we
want for small numbers of queries anyway.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nvk: Use mme_tu104_read_fifoed()
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nouveau/mme: Add a helper for MME_DMA_READ_FIFOED
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nouveau/mme: Add a couple helpers for working 64-bit addresses
In the command stream, they always come high bits first which is
backwards from little endian. These helpers follow that same convention
so that MMEs use the same conventions as other registers.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nouveau/mme: Add support for freeing registers
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nouveau/mme: Assert on OOB registers
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nouveau/mme: Allow ZERO as the destinatio nof mme_load_to
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nvk: Implement pipeline statistics and occlusion queries
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nvk: Implement timestamp queries
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nvk: Add a query pool object
Also, while we're here, add a skeliton for vkGetQueryPoolResult(). It
doesn't do anything yet because we haven't implemented any qeury types,
but all the helpers, etc. we need are there.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nouveau/parser: Parse all fields in each method
When converting to mako, the break got moved to the wrong spot and we
were only parsing the first method. Now we parse them all.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nvk/wsi: Use the common present implementation
This enables WSI for NVK. Currently, it always gets the blit path and
renders correctly on X11 and corrupts on Wayland. The problem is that
we don't yet support linear images so wayland gets tiled and is wrong.
The thing that saves us for X11 is the lack of VK_EXT_pci_bus_info.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nvk/wsi: Style fixes
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nvk: Reset semaphore syncs on wait
Vulkan semaphores are spec'd to auto-reset on wait but we currently
assert on signal that the state is RESET. Without this, semaphores used
more than once assert which isn't what we want.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nvk: Style fixes in nvk_physical_device.c
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Karol Herbst [Fri, 10 Jun 2022 17:37:17 +0000 (19:37 +0200)]
nvk: support exporting buffers
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nvk: Rework whitespace in nvk_device_memory.c
Trying to keep things consistent...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nvk: Allocate shaders from a heap
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nvk: Add a shader heap to nvk_device
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nvk: Return a VkResult from nvk_shader_upload()
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nvk: Add a heap data structure
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>
Faith Ekstrand [Tue, 31 Jan 2023 02:12:00 +0000 (20:12 -0600)]
nvk: Rework nvk_queue_submit_simple()
This is a few changes rolled into one:
1. Add a sync flag to force a stall before returning
2. Re-order dw and push_dw_count to put the count first
3. Take an array of extra BOs instead of just one
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24326>