摘要
GLSL(OpenGL Shading Language,GLSL)是一种高级图形编程语言,它自OpenGL 2.0版本开始成为OpenGL规范的一部分,专门用来编写OpenGL可编程管线对应的着色器。论文以OpenGL 2.0规范中的OpenGL着色语言(version1.10)为研究对象,根据其语言特性,结合国产GPU的单指令多数据(SIMD)指令集架构和可用资源,提出了一种在该GPU平台上可行的GLSL编译器设计。
The OpenGL Shading Language(GLSL)is a high-level shading language. It has been made part of the OpenGL standard since OpenGL 2.0. This language is a powerful tool for application developers that can help them utilize the underlying graphics hardware to achieve a much wider range of rendering effects. In this paper,a GLSL(version 1.10)compiler designed for a certain domestic programmable GPU platform is presented.
引文
[1]Rost R J,Licea-Kane. OpenGL Shading Language[M].Addison Wesley Longman Publishing Co. Inc,2004.
[2]Aho A V,Lam M S,Sethi R,et al. Compilers:Principles,Techniques,and Tools(2nd Edition)[M]. Addison-Wesley Longman Publishing Co. Inc,2006.
[3]J Kessenich,D Baldwin,R Rost. OpenGL Shading Language 1.10[M]. Specification,2004.
[4]Muchnick S. Advanced Compiler Design Implementation[M]. Morgan Kaufmann,1997.
[5]Torczon L,Cooper K. Engineering A Compiler[M]. Morgan Kaufmann Publishers Inc,2007.
[6]Levine J. Flex And Bison[M]. O'Reilly Media Inc,2009.
[7]Kennedy K,Allen J R. Allen,R.:Optimizing Compilers for Modern Architectures:A Dependence-based Approach[M]. Morgan Kaufmann Publishers,2002.
[8]Xi H. Dead Code Elimination through Dependent Types[C]//International Workshop on Practical Aspects of Declarative Languages. Springer-Verlag,1999:228-242.
[9]Knoop J,Rüthing O. Constant Propagation on the Value Graph:Simple Constants and Beyond[C]//Compiler Construction,International Conference,Cc 2000,Held As.DBLP,2000:94-109.
[10]Rüthing O,Knoop J,Steffen B. Detecting Equalities of Variables:Combining Efficiency with Precision[M].Static Analysis. Springer Berlin Heidelberg,1999:232-247.
[11]Larsen S,Amarsinghe S. Exploiting superword level parallelism with multimedia instruction sets[J]. ACM Sigplan Notices,2000,35(5):145-156.
[12]Cooper K D,Simpson L T. Live range splitting in a graph coloring register allocator[C]//International Conference on Compiler Construction. Springer Berlin Heidelberg,1998:174-187.
[13] Gregory Chaitin. Register allocation and spilling via graph coloring[J]. ACM SIGPLAN Notices,2004,39(4):66-74.
[14]Chow,Frederick,Hennessy,John. Register allocation by priority-based coloring[J]. ACM SIGPLAN Notices,2004,39(4):91-103.
[15]Fraser C W,Hanson D R,Proebsting T A. Engineering a simple,efficient code-generator generator[J]. Acm Letters on Programming Languages&Systems,1992,1(3):213-226.