Read nonStrictWideLinesUseParallelogram from the maintenance5 properties
The profile reader took VkPhysicalDeviceMaintenance5Properties' members only through VkPhysicalDeviceVulkan14Properties, so a capture of a Vulkan 1.3 device exposing VK_KHR_maintenance5, which carries only the extension's structure, read nonStrictWideLinesUseParallelogram as false, and the runtime would announce or band wide lines its device draws as Metal's parallelogram. PROPERTY_STRUCTS now lists VkPhysicalDeviceMaintenance5Properties and its KHR name; the member is still read only where maintenance5 is exposed (the extension or 1.4). The profile generator's EXTENSION_PROPERTIES states the member at the value the reader takes when a requirements document lists the extension and omits it (false). Nothing moves: every committed capture that carries the extension structure also carries the Vulkan 1.4 one, with the same value (golden_hashes passes unblessed). The runtime-sources pin, which hashes this file, is rewritten in the next commit. Verified: nextest device::tests::description (23 pass), among them the new wide_line_parallelograms_read_the_maintenance5_structure (a 1.3 document with the extension and either structure name reads true, without the extension false, a 1.4 document's Vulkan 1.4 block true); negative control: with the two names left out of PROPERTY_STRUCTS the test fails; golden_hashes and fast_paths pass; scripts/regen-device- profiles test_device_profiles.py and check_device_profiles.py clean. (Carried to development from steelbrain/reims-graphics-kext 5651992284.)
This commit is contained in:
1 parent
eb41a55e82
commit
bbc7866fa0
3 files changed
+47
No files matched your search
@@ -1086,6 +1086,8 @@ const PROPERTY_STRUCTS: &[&str] = &[
|
||||
"VkPhysicalDeviceSubgroupSizeControlPropertiesEXT",
|
||||
"VkPhysicalDeviceMaintenance4Properties",
|
||||
"VkPhysicalDeviceMaintenance4PropertiesKHR",
|
||||
"VkPhysicalDeviceMaintenance5Properties",
|
||||
"VkPhysicalDeviceMaintenance5PropertiesKHR",
|
||||
"VkPhysicalDevicePushDescriptorProperties",
|
||||
"VkPhysicalDevicePushDescriptorPropertiesKHR",
|
||||
"VkPhysicalDeviceVertexAttributeDivisorProperties",
|
||||
|
||||
@@ -460,6 +460,50 @@ fn acceleration_structure_limits_read_their_property_structure() {
|
||||
assert_eq!(l.max_descriptor_set_acceleration_structures, 0);
|
||||
}
|
||||
|
||||
/// `nonStrictWideLinesUseParallelogram` is read where `VK_KHR_maintenance5` is exposed, from its
|
||||
/// extension's property structure as from the Vulkan 1.4 one (a capture of a Vulkan 1.3 device
|
||||
/// carries only the first), and is false without the extension or where unstated.
|
||||
#[test]
|
||||
fn wide_line_parallelograms_read_the_maintenance5_structure() {
|
||||
assert!(
|
||||
profile("amd-780m-radv")
|
||||
.limits
|
||||
.non_strict_wide_lines_use_parallelogram
|
||||
);
|
||||
assert!(
|
||||
!profile("lavapipe")
|
||||
.limits
|
||||
.non_strict_wide_lines_use_parallelogram
|
||||
);
|
||||
let read = |api: &str, blocks: &str| {
|
||||
DeviceDescription::from_khronos_json(&doc(api, r#""a""#, blocks), None)
|
||||
.unwrap()
|
||||
.limits
|
||||
.non_strict_wide_lines_use_parallelogram
|
||||
};
|
||||
let extension = r#""extensions": {"VK_KHR_maintenance5": 1}"#;
|
||||
for structure in [
|
||||
"VkPhysicalDeviceMaintenance5PropertiesKHR",
|
||||
"VkPhysicalDeviceMaintenance5Properties",
|
||||
] {
|
||||
let props = format!(
|
||||
r#""properties": {{"{structure}": {{"nonStrictWideLinesUseParallelogram": true}}}}"#
|
||||
);
|
||||
assert!(
|
||||
read("1.3.0", &format!(r#""a": {{{extension}, {props}}}"#)),
|
||||
"{structure}"
|
||||
);
|
||||
assert!(
|
||||
!read("1.3.0", &format!(r#""a": {{{props}}}"#)),
|
||||
"{structure}"
|
||||
);
|
||||
}
|
||||
let v14 = r#""properties": {"VkPhysicalDeviceVulkan14Properties":
|
||||
{"nonStrictWideLinesUseParallelogram": true}}"#;
|
||||
assert!(read("1.4.0", &format!(r#""a": {{{v14}}}"#)));
|
||||
assert!(!read("1.3.0", &format!(r#""a": {{{extension}}}"#)));
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn profile_documents_imply_version_required_features() {
|
||||
// The LunarG baseline lists 1.2 structures but not every member 1.2 requires.
|
||||
|
||||
@@ -238,6 +238,7 @@ EXTENSION_PROPERTIES = {
|
||||
"requiredSubgroupSizeStages": [],
|
||||
},
|
||||
"VkPhysicalDeviceVertexAttributeDivisorPropertiesEXT": {"maxVertexAttribDivisor": 0},
|
||||
"VkPhysicalDeviceMaintenance5Properties": {"nonStrictWideLinesUseParallelogram": False},
|
||||
"VkPhysicalDeviceSampleLocationsPropertiesEXT": {
|
||||
"sampleLocationSampleCounts": [],
|
||||
"variableSampleLocations": False,
|
||||
|
||||
Reference in new issue
Block a user