anv: Enable SPV_KHR_16bit_storage and VK_KHR_16bit_storage for SSBO/UBO

Enables SPV_KHR_16bit_storage on gen 8+.

VK_KHR_16bit_storage is enabled for SSBO/UBO using the
VK_KHR_get_physical_device_properties2 functionality to expose
if the extension is supported or not.

v2: update due rebase against master (Alejandro)
v3: (Jason Ekstrand)
    - Move this patch up in VK_KHR_16bit_storage series enabling only
      storageBuffer16BitAccess and uniformAndStorageBuffer16BitAccess.
    - Only expose VK_KHR_16bit_storage on Gen8+
v4: (Jason Ekstrand)
    - Squash enable SPV_KHR_16bit_storage into VK_KHR_16bit_storage
      enablement for SSBO/UBO.

Signed-off-by: Jose Maria Casanova Crespo <jmcasanova@igalia.com>
Signed-off-by: Alejandro Piñeiro <apinheiro@igalia.com>
Signed-off-by: Eduardo Lima Mitev <elima@igalia.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
This commit is contained in:
Alejandro Piñeiro
2017-07-01 08:32:17 +02:00
committed by Jose Maria Casanova Crespo
parent 3282309f74
commit 66ce6ce78f
3 changed files with 15 additions and 0 deletions

View File

@@ -142,6 +142,7 @@ anv_shader_compile_to_nir(struct anv_pipeline *pipeline,
.image_write_without_format = true,
.multiview = true,
.variable_pointers = true,
.storage_16bit = device->instance->physicalDevice.info.gen >= 8,
},
};