glsl: Create a _mesa_shader_stage_to_abbrev() function.
authorKenneth Graunke <kenneth@whitecape.org>
Thu, 19 Feb 2015 01:35:41 +0000 (17:35 -0800)
committerKenneth Graunke <kenneth@whitecape.org>
Thu, 19 Feb 2015 23:15:45 +0000 (15:15 -0800)
commit7555d1bafb089bc5130f86602a23725e184c490e
treeeca26dec6220c9589760d896d099aa644c9c2d5d
parent231267bf011e1fa6edb52ffad27fcbca8e0e28e1
glsl: Create a _mesa_shader_stage_to_abbrev() function.

This is similar to _mesa_shader_stage_to_string(), but returns "VS"
instead of "vertex".

v2: Use unreachable() and add MESA_SHADER_COMPUTE (requested by Ian).

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Jason Ekstrand <jason.ekstrand@intel.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kristian Høgsberg <krh@bitplanet.net>
Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
src/glsl/glsl_parser_extras.cpp
src/glsl/glsl_parser_extras.h