src/libANGLE/renderer/vulkan/CLProgramVk.h


Log

Author Commit Date CI Message
Gowtham Tammana f9709279 2024-09-20T16:02:56 CL/Vulkan: Add support for printf builtin processing The support for printf builtin in clspv enabled through the SPIR-V non-semantic clspv reflection instructions - PrintfInfo and PrintfBufferStorageBuffer [1]. The printf buffer is setup with a separate descriptor layout and the pipeline layout is updated accordingly. Also, printf is enabled as default option now for clspv. [1]: https://github.com/KhronosGroup/SPIRV-Registry/blob/master/nonsemantic/NonSemantic.ClspvReflection.html Bug: angleproject:369724757 Change-Id: I20b245eb0fea69941bd1aeb42534f8b729ec17e8 Signed-off-by: Gowtham Tammana <g.tammana@samsung.com> Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5893958 Reviewed-by: Charlie Lao <cclao@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Gowtham Tammana 0a452697 2024-09-19T16:33:26 CL/Vulkan: Enable support for multiple descriptor set handling The clspv transcompiler can generate multiple descriptor sets depending on the kernel e.g. printf storage buffer is setup in a separate descriptor set, and kernel arguments in a separate descriptor set. This change enables setting up of multiple descriptor sets and appropriately bind them. Also, creation of descriptor set and pipeline layout are deferred to kernel enqueue time as it is quite possible that kernels are built in a batch before their use. Bug: angleproject:369724757 Change-Id: I80eb93f4a3b8afc7461c299cc283526cc4b872fa Signed-off-by: Gowtham Tammana <g.tammana@samsung.com> Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5893955 Reviewed-by: Charlie Lao <cclao@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Gowtham Tammana 371539c3 2024-09-19T16:26:44 CL/Vulkan: Move descriptor set and pipeline layout cache to context Move the descriptor set and pipeline layout caches to context so that cache is shared across programs. Bug: angleproject:369724757 Change-Id: I517d0cc712adb3f8b91d68e5bca8d3ac3ddb39ff Signed-off-by: Gowtham Tammana <g.tammana@samsung.com> Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5893954 Reviewed-by: Charlie Lao <cclao@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Austin Annestrand 1bed7fdd 2024-09-13T15:29:07 CL/VK: Fix missed PushConstantRegionGroupOffset Adding missing reflection instruction to parser: NonSemanticClspvReflectionPushConstantRegionGroupOffset And add related PC routine during NDRangeKernel. Bug: angleproject:366412385 Change-Id: I2ffa48dee46a23840390312f20e7103f68daa0c5 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5860310 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Austin Annestrand cce1497c 2024-06-07T15:03:07 CL/Vulkan: regionOffset as GWO for uniform clspv states: region_offset: the sum of the global ID offset into the NDRange for this uniform region and the global offset of the NDRange Since we currently do not support non-uniform at the moment, we just treat the PushConstantRegionOffset as the global work offset. Bug: angleproject:366412385 Change-Id: Ifd9953f21cd7826198b2cfe7d30ddec68ea2c7a0 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5860309 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Austin Annestrand 741e5355 2024-06-07T16:39:53 CL/Vulkan: Add missing PushConstantNumWorkgroups Adding support for: NonSemanticClspvReflectionPushConstantNumWorkgroups Bug: angleproject:366412385 Change-Id: Id4cfc1ee456d3a7f6d058f3f4a6a580381b2d471 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5860308 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Austin Annestrand 72d01332 2024-05-23T16:34:14 CL/Vulkan: Add missing EnqueuedLocalSize PushConst Additionally, we move down "processKernelResources" after "getOrCreateComputePipeline" since new push constant needs LWS value and we might modify ndrange's LWS after "getOrCreateComputePipeline". Bug: angleproject:366412385 Change-Id: Ia287d667e0616256d1f9c039566b79aae1337154 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5860306 Commit-Queue: Austin Annestrand <a.annestrand@samsung.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Austin Annestrand fc65058c 2024-05-03T14:47:29 CL/Vulkan: Rework spec constant handling Specialization constants can be combined into a single hash map that's later iterated on when we create the compute pipeline. Bug: angleproject:364396920 Change-Id: I161356808ff0bd6a589f01854264210011bec512 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5834664 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Austin Annestrand <a.annestrand@samsung.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Austin Annestrand 1010a275 2024-06-18T10:27:10 CL/Vulkan: Set proper build status prior to API return For cl[Compile/Link/Build]Program, we need to set the build status to CL_BUILD_IN_PROGRESS before returning to user/app (since in build callback case, user can query status as either in-progress, done, or error). CL_BUILD_NONE would not be a valid query return if the user just launched a build in this case. Bug: angleproject:357905825 Change-Id: I85f23db7f9a543ff8872557de5c1cf41d2f2645a Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5767599 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Austin Annestrand <a.annestrand@samsung.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Shahbaz Youssefi c3a1cae4 2024-04-15T14:58:55 Use angle::SimpleMutex everywhere in libGLESv2 Only cases left that use std::mutex are: - Share group and the context ErrorSet mutexes as they need try_lock() - Anywhere mutexes are used in conjunction with std::condition_variables (as they explicitly require std::mutex) Bug: angleproject:8667 Change-Id: Ib6d68938b0886f9e7c43e023162557990ecfb300 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5453294 Reviewed-by: Roman Lavrov <romanl@google.com> Reviewed-by: Charlie Lao <cclao@google.com> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Austin Annestrand d4abe622 2024-04-03T17:46:38 CL/VK: Implement enqueue NDRangeKernel & Task Adding support for: clEnqueueNDRangeKernel clEnqueueTask Bug: angleproject:8631 Change-Id: If57002be3ea00a55215e89ca47ab8fe9a422c6e7 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5406614 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Austin Annestrand <a.annestrand@samsung.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Austin Annestrand 76636ddb 2024-04-04T15:39:08 CL/VK: Update missing reflection ops & DS creation Adding CLProgramVk routine to allocate DS. Also adding reflection parsing support for WGS IDs and PushConstantGlobalSize. Additionally, we now check VK implementation if non-semantic reflection data (in SPIR-V) is supported. If not, we strip that data from binary (via vk_feature check). Bug: angleproject:8631 Change-Id: Ife02867c7c30b919abf663865adc92858e1bff8d Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5421574 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Austin Annestrand <a.annestrand@samsung.com>
Austin Annestrand 2dc9d0cd 2024-04-04T14:38:31 CL/VK: Add workgroup size/count types Replacing existing CompiledWorkgroupSize type with "WorkgroupSize" and "WorkgroupCount". (since CompiledWorkgroupSize == WorkgroupSize). Bug: angleproject:8631 Change-Id: I4094d10e6ad5db51a56ae92fe4f2fb4a6e72bdc7 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5425447 Commit-Queue: Austin Annestrand <a.annestrand@samsung.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Austin Annestrand ff03a7b1 2024-03-19T10:54:22 CL/VK: Program build_status & mCallback fixes Was missing saving the build_status in the program export/binary to disk. Also, missing dereference for mCallback. Bug: angleproject:8435 Change-Id: I77f070f5bc1c40454d625abcf13c1a4b70c465b2 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5406613 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Austin Annestrand <a.annestrand@samsung.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Gowtham Tammana a8e9aa26 2024-03-11T23:50:18 CL/VK: Setup GlobalOps for the platform Setup CLPlatformVk as a provider of vk::GlobalOps, and use the vk::GlobalOps associated thread pool for async tasks. Bug: angleproject:8515 Change-Id: I3e1ae069afabeadfdfa02f4a2f99419882f91c6a Signed-off-by: Gowtham Tammana <g.tammana@samsung.com> Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5403225 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Austin Annestrand bc633ad7 2024-01-18T12:24:40 OpenCL/Vulkan: Implement compile and link routines Enables the following OpenCL APIs for the Vulkan Backend: clCompileProgram clLinkProgram Bug: angleproject:8571 Change-Id: Ide7d2911922347055051537c9c70b83be4e24575 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5341375 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Austin Annestrand <a.annestrand@samsung.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Austin Annestrand 0ed0de4f 2024-01-18T10:47:50 OpenCL/Vulkan: Add initial program build support Introducing both clspv compiler lib integration, and clBuildProgram support. Internally we also add buildInternal() routine to abstract compile, link, and build phases. Output SPIR-V is also parsed internally via parseReflection() so that we can extract needed reflection information for CL runtime. Bug: angleproject:8549 Change-Id: If0563f4bea7ed0e04a13ea7a46c125c811d9c2a2 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5303564 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Austin Annestrand 1ceddbf6 2024-01-11T16:15:08 OpenCL/Vulkan: Add createProgram routines Introduce createProgramWithSource and createProgramWithBinary. Additionally introduce KernelArgument types, SPIR-V Reflection info types, and DeviceProgram types. Bug: angleproject:8549 Change-Id: I611627d747a5ba6718778fd27fd28477b77fbbe1 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5303563 Commit-Queue: Austin Annestrand <a.annestrand@samsung.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Austin Annestrand 80893f26 2023-11-30T16:57:15 OpenCL: Remove unneeded impl getters Some of the OpenCL backend (impl) getters are not needed. These are the size query for image creation, and CL source retrieval for program objects not created from source. Bug: angleproject:8438 Change-Id: I76b39b75f1ae76ec0c3c94d5715632cb9dd4900a Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5078243 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Austin Annestrand 66d29149 2023-10-16T12:43:43 OpenCL: Add scaffolding to renderer/vulkan code Start off ANCLE (OpenCL on ANGLE) with backend scaffolding code with placeholder API error returns until they are later implemented. Bug: angleproject:8377 Change-Id: I223d3482cce097ccb298e121fc03ec416e8958fd Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4950556 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
John Plate 1aa88398 2021-05-24T14:19:05 CL: program object creation for front end and pass-through Add program object to back end and implement creation and info query. Bug: angleproject:6001 Change-Id: If94db8ab8b491e1ac21c767347cabb6f4f3b3cba Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2912465 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Cody Northrop <cnorthrop@google.com> Commit-Queue: John Plate <jplate@google.com>