src/compiler/translator/spirv/TranslatorSPIRV.cpp


Log

Author Commit Date CI Message
Shahbaz Youssefi c6fbf93d 2024-01-19T09:57:12 Vulkan: Fix input attachments leaking into uniform list To communicate the existence of input attachments added to the shader, the translator was adding `ShaderVariable`s for each to the list of uniforms exported from the shader. This was incorrect, as this list is visible to the application through `glGetActiveUniform`. Additionally, this was unnecessarily causing these uniforms to go through program link. Reserving SPIR-V ids for these uniforms, all that is needed from the translator is the mere existence of these input attachments. This change removes the addition of uniforms, and instead exports a bitset. Elsewhere, that bitset is consulted and reserved SPIR-V ids are used. Bug: b/320563594 Bug: angleproject:5792 Change-Id: Id93846cbc3996248f391fd2d5a65af1e48d6d46e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5215089 Reviewed-by: mohan maiya <m.maiya@samsung.com> Reviewed-by: Charlie Lao <cclao@google.com> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Charlie Lao acb0ae09 2023-10-27T13:38:09 Vulkan: Swizzle YUV output from GL component order to vulkan Since OpenGL and vulkan has different YUV component ordering, we need to swizzle the component form GL to vulkan when we write YUV data to output variable. The computation in shader will still carry out in OpenGL order. This CL swizzles component for the YUV output variable. Bug: b/223456677 Change-Id: Ie34bbc723bf3723ac65f7931aeab086c92610271 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4985622 Commit-Queue: Charlie Lao <cclao@google.com> Reviewed-by: Chris Forbes <chrisforbes@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Chris Forbes 9e5f5188 2023-10-24T18:43:12 Reswizzle results of YUV sampling operations Change-Id: Id6eee9e0d9e2b80d48c80f27bc8e670a5621d263 Test: ImageTestES3.* 24 -> 15 failures Bug: b/223456677 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4970337 Commit-Queue: Charlie Lao <cclao@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Charlie Lao <cclao@google.com>
Shahbaz Youssefi 4a195ce0 2023-08-10T11:28:31 Vulkan: Fix SPIR-V id assignment to user-defined webgl_* names The code was incorrectly assuming that webgl_* names are only from ANGLE variables. An explicit check that the symbols are AngleInternal was missing. Bug: b/287166117 Change-Id: Ib8140cfabd74000492d12c11163f318a9ec3b98f Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4770236 Commit-Queue: Solti Ho <solti@google.com> Auto-Submit: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Solti Ho <solti@google.com>
Mohan Maiya 05ea1147 2023-07-14T16:49:24 Vulkan: Bugfix in gl_FragData array redeclaration Both OpenGL ES and Vulkan spec allows implementations to limit the number of output attachments when dual-source blending is enabled. Account for this limit when setting gl_FragData array length by re-declaring the gl_FragData array size to match maxFragmentDualSrcAttachments value. Bug: angleproject:5537 Test: EXTBlendFuncExtendedDrawTest.FragData/ES2_Vulkan Change-Id: I5a462344f4c4faf850f56e9c5d4c392370d3d010 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4688396 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: mohan maiya <m.maiya@samsung.com>
Shahbaz Youssefi 9b63700b 2023-07-11T10:25:40 Translator: Reorganize files This change makes the translator files more organized by: - Grouping files that are specific to a certain output under their own directory, - Moving transformations under tree_ops - Removing Direct from metal translation now that that SPIR-V Cross path is removed Bug: angleproject:6394 Change-Id: Iaf5bb8d5604b84748dece029821b1f77b2813967 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4678780 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>