src/compiler/translator/tree_ops/DeclarePerVertexBlocks.cpp


Log

Author Commit Date CI Message
Shahbaz Youssefi d9fa255a 2025-10-02T11:58:06 Translator: Add numerous missing gl_PerVertex validations Bug: angleproject:349994211 Change-Id: Ie4a602dd026a2dab95c9d77e8841e76967fa7f3d Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/7002885 Reviewed-by: Charlie Lao <cclao@google.com> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi f3405af0 2025-09-25T13:45:08 Translator: Fix gl_in redeclaration This was seemingly untested, and had multiple issues: * GLSL generation would output `gl_in gl_PerVertex { ... } gl_in;` * SPIR-V generation would redeclare `gl_in` despite one already existing. * If sized after declaration, the redeclared `gl_in` was referencing a different variable than the resized one. Bug: angleproject:42264111 Bug: angleproject:349994211 Bug: angleproject:447556589 Change-Id: Id63912b68625bafcc64197807b1c8a86e6f952b5 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/6985323 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Yuxin Hu <yuxinhu@google.com>
Shahbaz Youssefi 18f28e59 2025-09-25T13:41:45 Translator: Mark redeclared gl_Position/PointSize as built-in When redeclared according to EXT_separate_shader_objects, these variables were given a UserDefined symbol type. While this doesn't affect SPIR-V (with Vulkan being the only backend that supports EXT_separate_shader_objects), it does affect the rest of the AST, including GLSL generation which would output _ugl_Position if support for the extension is enabled. Bug: angleproject:42265086 Bug: angleproject:349994211 Change-Id: I04d088017dbe6e32bfee675f0124c4cc3ffdefc2 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/6985322 Auto-Submit: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Yuxin Hu <yuxinhu@google.com> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi f128872e 2025-09-16T23:37:08 Translator: Compare variables by unique id instead of pointer Bug: angleproject:349994211 Change-Id: I32ab2ffe9a04e196330949484e704913d0f4e41d Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/6955119 Reviewed-by: Yuxin Hu <yuxinhu@google.com> Reviewed-by: Geoff Lang <geofflang@chromium.org> Auto-Submit: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Yuxin Hu <yuxinhu@google.com>
Shahbaz Youssefi d193d51b 2024-06-17T22:46:08 Replace issue ids post migration to new issue tracker This change replaces anglebug.com/NNNN links. Bug: None Change-Id: I8ac3aec8d2a8a844b3d7b99fc0a6b2be8da31761 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5637912 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi 76b0e7f3 2023-06-01T11:25:54 Vulkan: Use reserved SPIR-V ids for internal variables With this change, the SPIR-V transformer does not need to discover these ids through name matching. Ultimately, user variables would also be identified by their SPIR-V ids (instead of name), removing the Vulkan backend's reliance on strings. Bug: angleproject:7220 Change-Id: I241c3247b89a28f9eed28f23c06b7c8b7fbbeaa0 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4583133 Reviewed-by: Yuxin Hu <yuxinhu@google.com> Reviewed-by: Amirali Abdolrashidi <abdolrashidi@google.com> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Alexey Knyazev 0103213e 2022-12-05T00:00:00 GL: Support clip and cull distance redeclarations * Fixed gl_PerVertex qualifier string. * Updated ValidateClipCullDistanceTraverser to output redeclared array sizes and maximum constant indices. * Made DeclarePerVertexBlocks available for non-Vulkan outputs. * Updated DeclarePerVertexBlocks to remove gl_ClipDistance and gl_CullDistance redeclarations. * Enabled DeclarePerVertexBlocks for ESSL output when gl_ClipDistance or gl_CullDistance are redeclared. * Updated ESSL output to use 3.10 shading language version, when the context has GL_EXT_clip_cull_distance enabled. * Updated ESSL output to enable GL_EXT_shader_io_blocks when gl_ClipDistance or gl_CullDistance are redeclared. * Updated extension exposure conditions. * Fixed typos in ParseContext. Bug: angleproject:7763 Change-Id: Ib87368a1953ad546a407d634d8b00f71cf92c40c Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4083705 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Alexey Knyazev <lexa.knyazev@gmail.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>