lavapipe: enable KHR_memory_model support
authorMike Blumenkrantz <michael.blumenkrantz@gmail.com>
Mon, 14 Mar 2022 13:34:39 +0000 (09:34 -0400)
committerMarge Bot <emma+marge@anholt.net>
Tue, 15 Mar 2022 22:17:43 +0000 (22:17 +0000)
lavapipe's memory is always coherent, so this is already supported

Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15377>

src/gallium/frontends/lavapipe/ci/lvp-asan-fails.txt
src/gallium/frontends/lavapipe/lvp_device.c
src/gallium/frontends/lavapipe/lvp_pipeline.c

index 716c198..3d6224e 100644 (file)
@@ -13,6 +13,8 @@ dEQP-VK.renderpass.suballocation.formats.r32g32b32a32_sint.input.load.store.self
 dEQP-VK.renderpass2.dedicated_allocation.formats.a8b8g8r8_sint_pack32.input.clear.store.draw,Fail
 dEQP-VK.renderpass2.suballocation.formats.r16g16b16a16_unorm.input.dont_care.dont_care.draw,Fail
 dEQP-VK.renderpass2.suballocation.formats.r8g8b8a8_sint.input.load.dont_care.clear_draw,Fail
+dEQP-VK.memory_model.message_passing.ext.u32.noncoherent.atomic_atomic.atomicwrite.device.payload_local.image.guard_local.image.vert,Fail
+dEQP-VK.memory_model.write_after_read.ext.u32.noncoherent.fence_fence.atomicwrite.device.payload_local.buffer.guard_local.image.vert,Fail
 
 # Direct leak of 24 byte(s) in 1 object(s) allocated from:
 #     #0 0x7f29a36d1e8f in __interceptor_malloc ../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:145
index 3f94685..7bfabc0 100644 (file)
@@ -129,6 +129,7 @@ static const struct vk_device_extension_table lvp_device_extensions_supported =
    .KHR_timeline_semaphore                = true,
    .KHR_uniform_buffer_standard_layout    = true,
    .KHR_variable_pointers                 = true,
+   .KHR_vulkan_memory_model               = true,
    .EXT_4444_formats                      = true,
    .EXT_calibrated_timestamps             = true,
    .EXT_color_write_enable                = true,
@@ -651,9 +652,9 @@ lvp_get_physical_device_features_1_2(struct lvp_physical_device *pdevice,
    f->bufferDeviceAddress = true;
    f->bufferDeviceAddressCaptureReplay = false;
    f->bufferDeviceAddressMultiDevice = false;
-   f->vulkanMemoryModel = false;
-   f->vulkanMemoryModelDeviceScope = false;
-   f->vulkanMemoryModelAvailabilityVisibilityChains = false;
+   f->vulkanMemoryModel = true;
+   f->vulkanMemoryModelDeviceScope = true;
+   f->vulkanMemoryModelAvailabilityVisibilityChains = true;
    f->shaderOutputViewportIndex = true;
    f->shaderOutputLayer = true;
    f->subgroupBroadcastDynamicId = true;
index da71793..4a67f6b 100644 (file)
@@ -638,6 +638,8 @@ lvp_shader_compile_to_ir(struct lvp_pipeline *pipeline,
          .subgroup_ballot = true,
          .subgroup_quad = true,
          .subgroup_vote = true,
+         .vk_memory_model = true,
+         .vk_memory_model_device_scope = true,
          .int8 = true,
          .float16 = true,
       },