[Mesa-dev] [Bug 104777] Attaching multiple shader objects for the same stage to a GLSL program triggers a linker error
bugzilla-daemon at freedesktop.org
bugzilla-daemon at freedesktop.org
Mon Feb 5 17:17:43 UTC 2018
https://bugs.freedesktop.org/show_bug.cgi?id=104777
Juan A. Suarez <jasuarez at igalia.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|--- |FIXED
Status|NEW |RESOLVED
--- Comment #3 from Juan A. Suarez <jasuarez at igalia.com> ---
commit 4195eed961ccfe404ae81b9112189fc93a254ded
Author: Juan A. Suarez Romero <jasuarez at igalia.com>
Date: Mon Feb 5 17:38:39 2018 +0100
glsl/linker: check same name is not used in block and outside
According with OpenGL GLSL 3.20 spec, section 4.3.9:
"It is a link-time error if any particular shader interface
contains:
- two different blocks, each having no instance name, and each
having a member of the same name, or
- a variable outside a block, and a block with no instance name,
where the variable has the same name as a member in the block."
This fixes a previous commit 9b894c8 ("glsl/linker: link-error using the
same name in unnamed block and outside") that covered this case, but
did not take in account that precision qualifiers are ignored when
comparing blocks with no instance name.
With this commit, the original tests
KHR-GL*.shaders.uniform_block.common.name_matching keep fixed, and also
dEQP-GLES31.functional.shaders.linkage.uniform.block.differing_precision
regression is fixed, which was broken by previous commit.
v2: use helper varibles (Matteo Bruni)
Fixes: 9b894c8 ("glsl/linker: link-error using the same name in unnamed
block and outside")
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=104668
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=104777
CC: Mark Janes <mark.a.janes at intel.com>
CC: "18.0" <mesa-stable at lists.freedesktop.org>
Tested-by: Matteo Bruni <matteo.mystral at gmail.com>
Reviewed-by: Tapani Pälli <tapani.palli at intel.com>
Signed-off-by: Juan A. Suarez Romero <jasuarez at igalia.com>
src/compiler/glsl/linker.cpp | 53
++++++++++++++++++++++++++++++-----------------------
1 file changed, 30 insertions(+), 23 deletions(-)
--
You are receiving this mail because:
You are the assignee for the bug.
You are the QA Contact for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20180205/bd7f5188/attachment-0001.html>
More information about the mesa-dev
mailing list