Extends the unsupported_surfaces_ext_array to contain surfaces
supported by the layer, when the layer is built without supporting them.
Also handles the presentWait2 feature similar to presentWait.
Signed-off-by: Iason Paraskevopoulos <iason.paraskevopoulos@arm.com>
Change-Id: I2e61d56425ff657de949797be86436c9675d1b1f
* Changes the image state of ACQUIRED once the image has been presented as in shared present modes they are always in an acquired state.
* Removes thread free image semaphore signalling logic for shared present modes as there is only single image available and is always in an acquired state.
* Removes the reliance on the presentation thread for the shared present modes as it shouldn't be necessary for them as the headless mode does not share the buffer resource with any consumers.
* Adds the ability for swapchain_image class to not signal present fence for presentation request. On shared presentation modes we do not need to use the present fence and it cannot be used as the swapchain only has a single image.
* Adds support for present timing extension for shared present modes.
* When shared preset mode is used, the timings returned are always
* undefined as image is always in a state of being presented.
Change-Id: I6a5a7c744fe0fc115001de55a305d253695faf9f Signed-off-by: Normunds Rieksts normunds.rieksts@arm.com
Instead of destroying the wayland buffers from the private data
we just remove the proxies from the queue.
Signed-off-by: Iason Paraskevopoulos <iason.paraskevopoulos@arm.com>
Change-Id: I0e9dd158feaffa697ea30b3c49d41661ec3d924c
Fixes an issue where the wl_queue used for the buffer events was
destroyed before destroying the wl_buffer objects.
Signed-off-by: Iason Paraskevopoulos <iason.paraskevopoulos@arm.com>
Change-Id: Ibe25f1f1f2100dda734c5f5788209ddf89c6d47d
Fixes a case where backing image memory creator allocation was not
checked for out of memory condition which results in failing OOM CTS
tests.
Change-Id: I6c203599eca5562f334d4e5e3f21c200dc667ee5
Signed-off-by: Normunds Rieksts <normunds.rieksts@arm.com>
The Vulkan spec allows passing a NULL VkInstance to
vkGetInstanceProcAddr when querying global (pre-instance) function pointers, but these functions must be resolved only through the loader, not through layers.
This change ensures that the layer correctly handles NULL instance and
prevents such incorrect behavior comming from upper layers.
Signed-off-by: Muhamad Sammar <muhamad.sammar@arm.com>
Change-Id: Icd67fa4fb819a6f5ab4c5f40d73514ba79174c05
* Updated present timing logic and corrected macros to match Vulkan specification values.
* Added support for vkGetPhysicalDeviceCalibrateableTimeDomainsKHR to include stage-local time domains.
* Updated handling of VK_TIME_DOMAIN_DEVICE_KHR to return timestamps in nanoseconds.
* Modified vkGetPastPresentationTimingEXT to allow retrieval of records without requiring presentIds.
* Improved vkQueuePresentKHR to terminate early when the present timing queue is full.
* Fixed VkPastPresentationTimingEXT::presentStageCount to correctly report the number of stages containing definitive results.
Signed-off-by: Ginu Jacob ginu.jacob@arm.com
Decouples the swapchain images and their memory binder/allocator logic into separate classes. This allows us to reduce code duplication across different backends that use the same type of allocation logic and also allows us to make use of RAII to release the resources for swapchain images.
The swapchain_base and other swapchain classes have been refactored to handle the new swapchain images.
The patch makes the following adjustments:
* Introduces a new swapchain_image class that holds all swapchain image resources
* Introduces a swapchain image factory class that constructs swapchain images
* Introduces a Vulkan image handle class that is responsible for constructing VkImage handles
* Introduces a new interface that describes how swapchain backing memory is being allocated
* As part of this backing memory interface, introduces device and external (wsialloc) backing memory classes
* Introduces a new interface that holds swapchain image data like wl_buffers
* Refactors lots of swapchain image parts out of the base swapchain class and moves it into the respective backends to simplify the swapchain classes.
Added new debug file with function that exposes the
DRM modifier of a swapchain image buffer.
Building the layer with DEBUG=1 flag will result
building this file and tests can now get the modifier
value for assertions.
Signed-off-by: Lior Dekel <lior.dekel@arm.com>
Change-Id: I97a44dbda87b7cdb8984576aab613612f2f12a55
Adds a workaround for compositors that do not deliver
wp_presentation_feedback events when images are submitted to the
compositor in quick succession resulting in some of them being
discarded by handling it in buffer_release event instead.
Additionally fixes a double-free bug when presentation_feedback was
replaced using move semantics.
Change-Id: I97715ffbc45c3c869f84e57dca532d3a58ad3b67
Signed-off-by: Normunds Rieksts <normunds.rieksts@arm.com>
Support the promoted present_mode_fifo_latest_ready extension.
Change-Id: I92d27aa39553707cd36d7fb7067ffae82f2d95cd
Signed-off-by: Nir.Ekhauz <nir.ekhauz@arm.com>
Due to Vulkan WSI only support query surface caps by KHR,
so query result will mismatch when driver support EXT and
have different strategy with Vulkan WSI.
Mesa init min/maxImageCount = {4,0} both in EXT and KHR
Vulkan WSI init min/maxImageCount = {2,6} only in KHR
So cts obtain {4,0} by vkGetPhysicalDeviceSurface
Capabilities2EXT and obtain {2,6} by vkGetPhysicalDevi
ceSurfaceCapabilitiesKHR.
fix case:
dEQP-VK.wsi.wayland.surface.query_surface_counters
Signed-off-by: Ryan Zhang <ryan.zhang@nxp.com>
Makes use of the VK_QUERY_POOL_CREATE_RESET_BIT_KHR when creating the
query pool. It disables present timing when VK_KHR_maintenance9 is not
supported by the device.
Signed-off-by: Iason Paraskevopoulos <iason.paraskevopoulos@arm.com>
Change-Id: I9d364050f0cd4a2be74e1b1d44cf3f6a0795e6f4
Adds a per-device check for a 'best' queue family to
use for present timing, rather than always using index 0.
wsi_ext_present_timing holds resources (such as the command
buffer) per queue family, rather than supporting only one. However,
currently, only one queue family is supported at a time.
In future, we can hook vkGetDeviceQueue calls to map
VkQueues to their family index. Doing this will transparently
give present timing support for multiple queue families.
Signed-off-by: Alex Bates <alex.bates@arm.com>
Change-Id: I5becb29dfc4a082e301031e0c693acd23eb95a51
The present_timing extension depends on present_id2. The dependency
handling is incorrect and is fixed in this change.
Signed-off-by: Ginu Jacob <ginu.jacob@arm.com>
Change-Id: Id645450eeb5b22551f328a860ffec75ebdbfbc79
In this change, the sType used in VkFrameBoundaryEXT instance is fixed.
Signed-off-by: Ginu Jacob <ginu.jacob@arm.com>
Change-Id: Id1dab87b9b4144d6030c57dbe4e33a41e7045a9f
1. Update the README file.
2. Remove the guards from the code.
Signed-off-by: Nir.Ekhauz <nir.ekhauz@arm.com>
Change-Id: Idf65baee25d09a3b4bc3b563455468bac4d5bddf
In this change, the schedule present at relative time is enabled for
headless backend.
Signed-off-by: Ginu Jacob <ginu.jacob@arm.com>
Change-Id: I15ff8170dfe93539e4c9a7ff20868b0916129546
Silence warnings till we investigate
unrelated warnings to the project
Signed-off-by: Maged Elnaggar <maged.elnaggar@arm.com>
Change-Id: Id557ffcd96dcccfb8f8a2c58d84a229e53b2ab03