Age | Commit message (Collapse) | Author |
|
emu-34-release
Change-Id: If2effa04c2e7f7ec10383d2ed746a7a31917554a
|
|
It could trigger undefined behavior on Windows.
Bug: 323071431
Test: open chrome and play videos
Change-Id: I7736053459c3f749b713699145e063bc95f74271
|
|
It queries the GL texture object of the said EGL image and crashes if
the object does not exist. Thus we will have to skip snapshot in such
situation.
Also reformat neighbouring code to change tab to spaces.
Bug: 320561043
Test: presubmit
Change-Id: I20160e2a11b563caaecf0caa5b4137cb5b216500
(cherry picked from commit d8ba7faf2a710d48f6c915d04d884b6883df83b8)
|
|
We have a crash report that some unsupported format was created with
Android hardware buffer. Let's report the format name so that we could
fix it later.
Bug: 322858149
Change-Id: If4cd10a62eed0a56df82b4af68a348d52b82288d
(cherry picked from commit 3c041cc256eb8d750e2f6eff5b50bf41593d8c62)
|
|
|
|
|
|
|
|
Bug: 320319509
Bug: 316936776
Change-Id: I2f07370817b281969c0b35110d9887b416c42609
(cherry picked from commit 9348922de0bf43fad18c547f773e2568684000e2)
|
|
It diverged between old gralloc and minigbm.
Test: dEQP-VK.api.external.memory.android_hardware_buffer.*
Bug: 299520213
Merged-In: If0c1896c6acef97db9ec3ae3abfe88eea333b42f
Change-Id: I029cfb0765b0265409c71d4a6732275b385a4901
(cherry picked from commit 79ab57ae3c380a1aef8f3c216e162a2947f027fa)
|
|
rcClientWaitSyncKHR casts raw pointers from the guest which is unsafe.
Use EmulatedEglFenceSync::getFromHandle which checks if the fenceSync
has been registered and is still alive.
Bug: 320559580
Change-Id: Iaa26cd71409802d597145b62dd0eff099a0b2541
(cherry picked from commit c2ec5a6be8103f7e3e815cee11c3c3b8478c8c94)
|
|
Bug: 320855472
Test: media_unittests from rvc_car_release
Change-Id: I7af3265fc24d0a2265fac59e0041c318f75be99d
(cherry picked from commit b01fc5ab1beea740167176268cbde3d64bb6edb4)
|
|
emu-34-release
Change-Id: I5e300ec74ed48ce35b2856cc87614d71a147cdcc
|
|
emu-34-release
Change-Id: Id326c7aaf19ef0d87177a3d623e2ce96cc110c8d
|
|
|
|
|
|
Bug: 318885144
Bug: 316936776
Change-Id: I4f4f4e153abe3cbf5b2dd9c942bfefeec2de438c
|
|
Bug: 318885144
Bug: 316936776
Change-Id: Ia15aab0f246769bdb3bc11fa87e9af9a9aec497f
|
|
Previously, for gfxstream the filename was "CMakeLists.txt",
but that was changed with the prior commit. Not having a
filename doesn't affect codegen, but does throw an error
afterwards when timing statistics are thrown out.
Luckily, args.target and options.filename are more or less
synonymous in genvk.py, so use that. This should be fairly
upstreamable too if we choose to do so.
BUG=296903491
TEST=run genvk.py
Change-Id: Ib90b64ea2e6ed5860239b0ac3e644454f94d2778
|
|
Some code may be auto-generated, some may not be.
Eventually we want to move autogenerated code into specialized
directories, so it be generated but not necessarily checked
in [for certain cases].
Also, nuke codegen for CMakeLists.txt: we have multiple other
build systems now (Blueprint, meson), and it doesn't make
sense codegen one anymore.
BUG=296903491
TEST=compile
Change-Id: I63beff1726074268188694fbfeb803429ee96478
|
|
emu-34-2-release
Change-Id: I0cf8d74f6cdf5ef78cfac234503fae80fbd44b20
|
|
|
|
Not used.
BUG=296903491
TEST-trybots
Change-Id: Ia449742391dc1de9d0b043eeb5c75b2ddfec9ce9
|
|
Not used.
BUG=296903491
TEST=trybots
Change-Id: Ibce1a36a1933f21e4c88ec6a544e8903fa5d96ce
|
|
In RendererImpl::~RendererImpl, we have the following indirect call stack:
* teardownGlobalVkEmulation
* FrameBuffer::~FrameBuffer
* FrameBuffer::finalize
* RenderWindow::~RenderWindow
Triggers FrameBuffer::finalize indirectly by sending the finalize
command
* RendererImpl::~RendererImpl
However, teardownGlobalVkEmulation shouldn't be called until
mCleanupThread has exited, because we may have queued Vulkan objects
cleanups on that thread by calling
FrameBuffer::registerProcessCleanupCallback in on_vkCreateInstance, and
the clean up may depend on the global Vulkan emulation object.
Test: build
Change-Id: I667f2685dd9dc5749244844a3259e51a3250de7b
|
|
emu-34-release
Change-Id: If47758b82adf08292e295e381fffe3814809fbac
|
|
|
|
emu-34-2-release
Change-Id: Ie43dab01a3d92dd1a20814fe45f7f95d0a631ddd
|
|
This is a mega-change to support Linux guest WSI with gfxstream.
We tried to do a branch where every commit was buildable and
runnable, but that quickly proved unworkable. So we squashed
the branch into a mega-change.
Zink provides the GL implementation for Linux guests, so we just
needed to implement the proper Vulkan Wayland/X11 WSI
entrypoints.
The overall strategy to support this is to use Mesa's WSI
functions. The Vulkan WSI layer was also considered:
https://gitlab.freedesktop.org/mesa/vulkan-wsi-layer
But it was less maintained compared to Mesa. The way Mesa common
layers communicate with drivers is the through base objects
embedded in driver and a common dispatch layer:
https://gitlab.freedesktop.org/mesa/mesa/-/blob/main/docs/vulkan/dispatch.rst
https://gitlab.freedesktop.org/mesa/mesa/-/blob/main/docs/vulkan/base-objs.rst
Our objects are defined in gfxstream_vk_private.h. Currently,
Mesa-derived Vulkan objects just serve as shim to gfxstream
Vulkan’s internal handle mapping. Long-term, we can use
Mesa-derived objects inside gfxstream guest Vulkan exclusively.
The flow is typically inside a Vulkan entrypoint is:
- VK_FROM_HANDLE(vk-object) to convert to a gfxstream_vk_obj
object
- Call ResourceTracker::func(gfxstream_vk_obj->internal) or
VkEncoder::func(gfxstream_vk_obj>internal)
- Return result
A good follow-up cleanup would be to delete older gfxstream
objects. For example, we now have struct gfxstream_vk_device
and info_VkDevice in ResourceTracker.
Most of this logic was auto-generated and included in
func_table.cpp. Some vulkan functions were too difficult to
auto-generate or required special logic, and these are included
in gfxstream_vk_device.cpp. For example, anything that needs to
setup the HostConnection requires special handling.
Android Blueprint support is added to the parts of Mesa needed
to build the Vulkan runtime. One thing to call out it's
required to build the guest/vulkan_enc and guest/vulkan files
in the same shared library now, when previously have
libvulkan_enc.so and libvulkan_ranchu.so was sufficient
[otherwise, some weak pointer logic wouldn't work].
A side effect of this is libOpenglSystem must also be a static
lib, and so should libandroid_aemu too. That conceptually makes
sense and the Meson build had been doing this all a long. We
can probably transition everything besides libGLESv1_emulation.so,
libGLESv2_emulation.so and libvulkan_ranchu.so to be static.
This requires changes in the end2end tests, because since each
HostConnection is separate and internal to it's constituent
library. Lifetimes need to be managed separately: for example
the HostConnection instance created by the end2end tests would
not be visible inside libvulkan_ranchu.so anymore. Probably the
best solution would be improve the testing facade so a
HostConnection represents one virtio-gpu context, while some
other entity represents a virtio-gpu device (client-server
would work).
vk.xml was modified, but change sent to Khronos:
https://gitlab.khronos.org/vulkan/vulkan/-/merge_requests/6325
Fuchsia builds still need to be migrated, but they already have
Fuchsia Mesa with all the build rules so that shouldn't be too
bad. Just need to copy them over the gfxstream/Mesa hybrid.
The new command for building Linux guests is:
meson amd64-build/ -Dvulkan-drivers="gfxstream" -Dgallium-drivers="" -Dvk-no-nir=true -Dopengl=false
Big shout-out to Aaron Ruby, who did most of the gnarly codegen
needed to get the function table logic to work.
BUG=313466265
BUG=298679844
TEST=
* Run Weston/vkcube on Linux and automotive platform
* launch_cvd --gpu_mode=gfxstream vkcube
* launch_cvd --gpu_mod=gfxstream_guest_angle
* vkcube + 3D Mark Slingshot extreme work with guest ANGLE and
GL-VK interop
* GfxstreamEnd2EndTests
* Some select dEQP tests
Aaron Ruby (46):
gfxstream: function table: remove entry points that are hand-written.
gfxstream: function table: more changes
gfxstream: function table: scope internal_arrays to encoder
gfxstream: function table: autogenerate compoundType params
gfxstream: add handwritten EnumeratePhysicalDeviceGroup entrypoint.
gfxstream: function table: handle nested handle arrays
gfxstream: function table: adding some handwritten implementations
gfxstream: revert some unnecessary changes
gfxstream: use vk_object_zalloc/free instead of vk_zalloc/free.
gfxstream: revert most gfxstream objects to use vk_object_base
gfxstream: function table: handwritten commmand-buffers/pools
gfxstream: codegen functionality to handle special param
gfxstream: function table: random fixes
gfxstream: add vk_command_buffer_ops handlers
gfxstream: func_table.py: Codegen support for nested compound type
gfxstream: remove handwritten/add autogen entry points
gfxstream: add gfxstream_vk_device.cpp
gfxstream: query device and instance extensions early
gfxstream: func_table: explicit allocation for nested arrays/compound
types
gfxstream: goldfish_vulkan: fix commandBuffer allocation.
gfxstream: meson: Raise api_version in ICD config to 1.1.
gfxstream: function table: add more handwritten entries
gfxstream: goldfish_vulkan: update VkDescriptorSetAllocateInfo logic
gfxstream: function table: NULL check on internal_object dereference
gfxstream: function table: Remove POSTPROCESSES handling from
functable
gfxstream: mesa: Add 'gfxstream' as a -Dvulkan-drivers
gfxstream: ResourceTracker: add some allowedExtensions
gfxstream: gfxstream_vk_device: add wsi_common_entrypoints
gfxstream: Move instance handling into gfxstream_vk_device.cpp
gfxstream: ResourceTracker: Enable Linux WSI-related extensions
gfxstream: wsi: add wsi_device initialization
gfxstream: gfxstream_vk_device: use Mesa common physical device
management
gfxstream: ResourceTracker: translate mesa objects in user buffer
gfxstream: exclude VkSampler and VkDescriptorSet objects from
translation
gfxstream: Add guest-side external memory support with colorBuffers.
gfxstream: function table: Modify semaphoreList inputs to no-op
semaphores
gfxstream: function table: Allow VK_NULL_HANDLE for free/destroy APIs.
gfxstream: cereal: Add VK_EXT_depth_clip_enable as supported feature.
gfxstream: vulkan_enc: un-namespace vk_util.h and vk_struct_id.h
gfxstream: gfxstream_vk_device.cpp: Support VK_KHR_surface and
VK_*_surface
gfxstream: vulkan_enc: Add support for Mesa-only extensions.
gfxstream: ResourceTracker: Use DEVICE_TYPE_VIRTUAL_GPU always
gfxstream: platform: add dma-buf export support with dedicatedBuffer.
gfxstream: ResourceTracker: add VK_EXT_depth_clip_enable allowed
extension
gfxstream: ResourceTracker: external memory via QNX_screen_buffer
extension
gfxstream: Add VK_QNX_external_memory_screen_buffer to VulkanDispatch
Gurchetan Singh (18):
gfxstream: mesa: write Android.bp files
gfxstream: generate gfxstream_vk_entrypoints.{c, h}
gfxstream: vulkan_enc: add gfxstream_vk_private.h (objects)
gfxstream: function table: modify function table to use gfxstream_vk_*
gfxstream: compiles
gfxstream: build system improvements
gfxstream: ResourceTracker: don't crash without
VkBindImageMemorySwapchainInfoKHR
gfxstream: vk.xml: make some vkAcquireImageANDROID params optional
gfxstream_vk_device: filter out swapchain maintenance guest side
gfxstream: end2end: fixes for End2End tests
gfxstream: func_table: custom vkEnumerateInstanceLayerProperties
gfxstream: add VK_EXT_DEBUG_UTILS_EXTENSION_NAME into Mesa list
gfxstream: clang-format guest code
gfxstream: libandroid AEMU static
gfxstream: vkEnumerateInstanceVersion
gfxstream: vkCreateComputePipeLines
gfxstream: make end2end tests happy
gfxstream: delete prior vk.xml, vk_icd_gen.py
Change-Id: Ic4cc50d5098dddd77c9265afa8f432a2fdea8845
|
|
Mesa has Linux WSI implementations that can be used for
gfxstream. We have to first import the parts of Mesa that
we find useful.
Just modified
- guest/src/mesa/meson.build
to remove extra project args.
- guest/src/mesa/src/meson.build
to not automatically call subdir in all directories.
This also requires the VK_NO_NIR and Android build patches, which
are fairly upstreamable. The strategy would be to merge all changes
required in the source code.
Generally, if you want to modify the Mesa subdir, you generally
will want to have a plan for upstreaming the change.
For example, here's the Mesa VK_NIR patches.
https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26574
[not upstreamed yet; but do have a plan ;-)]
BUG=313466265
TEST=compile
Change-Id: Ib5a7546e3f8832ddba4de8e62afc80c669692444
|
|
Not necessary for crosvm or upstream QEMU:
STREAM_RENDERER_PARAM_DEBUG_CALLBACK is already well-integrated
into respective VMMs.
BUG=317816825
TEST=meson build still works with older AEMU lib
Change-Id: I95599e6fb0c75a8856f29b78cc6963bf71b17ba1
|
|
|
|
emu-34-2-release
Change-Id: I9b858e4da9fe422152d4998689b38a4dc42f8b83
|
|
This change provides more explicit error messages and a proper abort in
situations where an unhandled VK structure is attempting to be used,
based purely on calls to the size functions. This should enable better
capture and debugging of these failures in the future (rather than
hitting a segfault and having to diagnose).
Bug: 317276564
Test: built with changes and ran locally
Change-Id: Ib00af771886823efa31e83fa0e1a557216557569
|
|
Bug: 317131873
Bug: 316936776
Change-Id: I60b48b31ada43ca7295d2ff84762817e2f640ede
|
|
|
|
Bug: 236282567
Test: boot AEMU with -guest-angle
Change-Id: I20ac7ccf9d4d3f24e9c31d4e05fda1bc18832940
|
|
Bug: 316963039
Bug: 316936776
TEST=Manual with emulator
Change-Id: I9e3b0f41e7885ac53ea5e1a11af09935841a6fd9
|
|
emu-34-release
Change-Id: If4d9f70fea6c2e89e17adce73d5dacf326ff3b8c
|
|
|
|
|
|
Not used.
BUG=296903491
TEST=presubmit
Change-Id: Ide369f6468dd41ad8efd18e11893dfcc8aa71d43
|
|
* changes:
gfxstream: nuke build-host.sh
gfxstream: nuke Android.mk
gfxstream: nuke METADATA
gfxstream: nuke profiler
|
|
Bug: b/315817323
Test: cvd start --gpu_mode=gfxstream_guest_angle
Test: cvd start --gpu_mode=gfxstream_guest_angle_host_swiftshader
Test: atest --host gfxstream_compositorvk_test
Change-Id: I5eeaef8ef421104b91434b73b6fdeab714c43fcf
|
|
|
|
|
|
... as a quick fix to avoid aborting.
Bug: b/315817323
Test: untested
Change-Id: Ia036c464fe75add459b63c5770011ad76746f783
|
|
* changes:
Sort and dedup physical device extensions
Use a nested Vulkan Loader when GFXSTREAM_VK_ env var found
Reorganize Vulkan Loader library finding
|
|
Not used.
BUG=296903491
TEST=presubmit
Change-Id: Id043315ca07f9b11532b862f1c04623732d7df5e
|
|
Not used.
BUG=296903491
TEST=presubmit
Change-Id: I3f2bc097c6d84510be9e7a632b1179eb9269d3ac
|
|
ANGLE is no longer in third-party.
BUG=296903491
TEST=presubmit
Change-Id: Id380ea003716ebe24e79f4ed7bae6660390cb490
|