Repository navigation
Vulkan: maintenance5 for points without PointSize, no empty vkCmdCopyBuffer regions - #255
Merged
Merged
Conversation
…at write no PointSize are defined BOTW draws one POINT_LIST draw a frame from a vertex shader with no PointSize. Without maintenance5 that is undefined (VUID-VkGraphicsPipelineCreateInfo-topology-08773, VUID-vkCmdDrawIndexed-primitiveTopology-10748); with it the size is 1. Mali-G925 r49p1 draws 1 pixel in both cases, so nothing changes there. LARECOMP_NO_MAINTENANCE5=1 leaves it off. Co-Authored-By: Claude Opus 5.5 <[email protected]>
A zero-size region is invalid (VUID-VkBufferCopy-size-01988). On Mali-G925 one came up in about one validation run of six, from a call its message doesn't name: all six call sites go through copy_buffer now, which drops such regions and logs the line that had them. The check is in buffer_copy.h, with a test on the device. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
BOTW draws one
POINT_LISTdraw a frame from a vertex shader that writes noPointSize, and withoutVK_KHR_maintenance5the point size is undefined (VUID-vkCmdDrawIndexed-primitiveTopology-10748,VUID-VkGraphicsPipelineCreateInfo-topology-08773). Separately, a zero-size region can reachvkCmdCopyBuffer(VUID-VkBufferCopy-size-01988).What changes
VK_KHR_maintenance5is enabled on Android only when the driver supports it; with it the size of these points is defined as 1.LARECOMP_NO_MAINTENANCE5=1leaves it off.vkCmdCopyBuffercall sites go throughcopy_buffer, which drops empty regions and logs the line that had them.How it was tested
Samsung SM-X730, Mali-G925 r49p1, Recompiled mode, the same scripted route (walk, map, two fast travels, inventory) on a scratch save, debug builds of
v0.3.1-beta(c48606c) and this branch.Validation layer 1.4.363, one run each (counts from logcat, so lower bounds):
primitiveTopology-10748topology-08773size-01988occurred in neither run; it is rare (about one validation run in six on 0.2.13), so that fix is covered bytools/test_buffer_copy.c, not by these runs.Without validation, after one warm-up run per build, order 0.3.1 / branch / branch / 0.3.1 (mean FPS over the time past 60 s, median FPS 30 in all):
The difference between the builds' means (0.03) is smaller than the spread within a build (up to 0.09). I compared captures at six points of the route side by side and saw no difference beyond what two runs of the same build show (walk position, time of day). Mali-G925 draws these points at 1 pixel with or without the extension, so no visible change is expected there. Not tested: Native mode, other GPUs.
tools/test_android_runtime.ps1 -DeviceSerial <device>: exit 0, no SKIP.