Bug 106906

Summary: Failed to recongnize keyword “sampler2DRect” and "sampler2DRectShadow"
Product: Mesa Reporter: Zhaowei Yuan <zhaowei.yuan>
Component: glsl-compilerAssignee: mesa-dev
Status: RESOLVED FIXED QA Contact: Intel 3D Bugs Mailing List <intel-3d-bugs>
Severity: normal    
Priority: medium    
Version: 17.1   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:

Description Zhaowei Yuan 2018-06-13 08:37:12 UTC

    
Comment 1 Zhaowei Yuan 2018-06-13 08:41:20 UTC
CTS cases "dEQP-GLES2.functional.shaders.keywords.reserved_keywords.sampler2DRectShadow_vertex" and "dEQP-GLES2.functional.shaders.keywords.reserved_keywords.sampler2DRectShadow_fragment" check that if shader complier can recongnize reserved keywords "sampler2DRect" and "sampler2DRectShadow"

GLSL ES spec 1.0.17 says they are keywords reserved for future use. Using them will result in an error

I've fixed the problem with follow modification:
-sampler2DRect          DEPRECATED_ES_TYPE_WITH_ALT(yyextra->ARB_texture_rectangle_enable, glsl_type::sampler2DRect_type);
+sampler2DRect          TYPE_WITH_ALT(110, 100, 0, 0, yyextra->ARB_texture_rectangle_enable, glsl_type::sampler2DRect_type);
 sampler3DRect          KEYWORD(110, 100, 0, 0, SAMPLER3DRECT);
-sampler2DRectShadow    DEPRECATED_ES_TYPE_WITH_ALT(yyextra->ARB_texture_rectangle_enable, glsl_type::sampler2DRectShadow_type);
+sampler2DRectShadow    TYPE_WITH_ALT(110, 100, 0, 0, yyextra->ARB_texture_rectangle_enable, glsl_type::sampler2DRectShadow_type);
Comment 2 Zhaowei Yuan 2018-06-13 08:58:00 UTC
patch is posted here:
https://patchwork.freedesktop.org/patch/229229/
Comment 3 Zhaowei Yuan 2018-07-23 07:33:47 UTC
Is there nobody can give any reponse on this report?
Comment 4 Zhaowei Yuan 2018-07-23 07:50:15 UTC
Fixed by:

commit 73ec437627448466b2d3da3adc74310ccd4f41e7
Author: zhaowei yuan <zhaowei.yuan@samsung.com>
Date:   Wed Jun 13 04:45:43 2018 +0800

    glsl: Treat sampler2DRect and sampler2DRectShadow as reserved in ES2

    "sampler2DRect" and "sampler2DRectShadow" are specified as
    reserved from GLSL 1.1 and GLSL ES 1.0

    Signed-off-by: zhaowei yuan <zhaowei.yuan@samsung.com>
    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=106906
    Reviewed-by: Eric Anholt <eric@anholt.net>
    Fixes: 34f7e761bc61 ("glsl/parser: Track built-in types using the glsl_type directly")

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.