Responsive image
博碩士論文 etd-0826110-192652 詳細資訊
Title page for etd-0826110-192652
論文名稱
Title
支援在新式3D繪圖處理器上的OpenGL 2.0ES語言的編譯器
Compiler Development to Support OpenGL 2.0 ES on a Novel 3D Graphics Processor
系所名稱
Department
畢業學年期
Year, semester
語文別
Language
學位類別
Degree
頁數
Number of pages
39
研究生
Author
指導教授
Advisor
召集委員
Convenor
口試委員
Advisory Committee
口試日期
Date of Exam
2010-06-29
繳交日期
Date of Submission
2010-08-26
關鍵字
Keywords
繪圖處理器、後端、編譯器
OpenGLES2.0
統計
Statistics
本論文已被瀏覽 5669 次,被下載 12
The thesis/dissertation has been browsed 5669 times, has been downloaded 12 times.
中文摘要
這篇論文是一個嵌入式系統上圖形處理器的大型計劃中的一部份,為了能支援這個計劃,這篇論文設計了一個簡單的編譯器給這個計劃中的圖型處理器。這個編譯器在本質上是一個C的編譯器,但我們卻能支援到OpenGLES 2.0語言(GLSL)的的編譯。因為我們有一個OpenGL到C的轉換程式可以使用。轉換出來的組合語言並不突出,因為它在OpenGL到 C的轉換的過程會遺漏一些應該有的資訊。
而這篇論文並沒有特別強調如何編譯GLSL的程式碼如何被編譯,因為那是另一位同組計劃組員的論文。在他的論文中將配合這篇論文的後端(backend)完成前端(front end)。三個主要後端的挑戰在於,一、新GPU指令的選擇。二、暫存器的分配在只有一種暫存器類型的情況下。三、保留變數中向量和矩陣的資訊給暫存器。對於產生出來的程式碼的品質,我們只能算是初期的階段。
Abstract
This thesis work is part of a larger project to develop a Graphics Processing Unit (GPU) for embedded systems. In support of this larger project, this thesis describes the basic compiler for our new GPU. The compiler presented here is essentially a C compiler for our new GPU. Our compiler does, however, have indirect support for the OpenGLES 2.0 shading language (GLSL), because an OpenGL-to-C converter can be applied to the code. The final code produced by this approach is poor, however, because of the loss of information during the conversion to C.
The reason that this thesis does not focus on the issues of compiling GLSL code directly is that that is the work of another student’s thesis. Essentially, that thesis solves the front-end while this thesis solves the problems in the backend. The three primary challenges for the backend are: 1) instruction selection to the new GPU, 2) register allocation for the GPU’s unified register set, and 3) maintaining vector and matrix information from variables to the register they are stored in. Our preliminary results are shown, for evaluation of the quality of the compiled code.
目次 Table of Contents
1 INTRODUCTION . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1

1.1 GPU hardware features that impact our compiler development . . . . . . . . . . . . .2

1.2 Compiler development along two simultaneous tracks . . . . . . . . . . . . . . . . . . . 7

2 RELATED WORK . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11

2.1 Interacting software packages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11

2.2 Other GPU compilers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14

2.3 Compiler Technologies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15

3 IMPLEMENTATION . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ...18

3.1 Implementing our register allocator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19

3.2 Implementing our instruction selector . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .20

3.3 Other modifications of LLVM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .25

4. RESULT . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .29

5. CONCLUSION . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33

REFERENCES . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34

參考文獻 References
[1] R. J. Rost, “OpenGL Shading Language, Second Edition.” Reading, MA, USA: Addison-Wesley, 2006.
[2] The LLVM Compiler. Website: llvm.org
[3] F. W. Tsai and C. L. Lee, “An Emulator for OpenGL ES 2.0 based on C-language Compiler.” Masters Thesis: National Sun Yat-Sen University, August 2008.
[4] G. F. Tseng and M. C. Chiang, “OpenGL ES 2.0 Shading Language to LLVM Compiler” Internal document, 2008. http://cooldavid.org/cooldavid.html
[5] K. A. Huang and S. Haga. “Compiler Support for Vector Processing on OpenGL ES 2.0 Programs,” Masters Thesis: National Sun Yat-Sen University, August 2010.
[6] S. C. Tseng and S. Haga. “Compiler/Hardware Codesign and Memory Management for a Novel 3D Graphics Processor,” Masters Thesis: National Sun Yat-Sen University, August 2010.
[7] S. Ryoo, C. Rodrigues, S. Baghsorkhi, S. Stone, D. Kirk, and W. Hwu. “Optimization Principles and Application Performance Evaluation of a Multithreaded GPU Using CUDA” Proceedings of the 13th ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming, Salt Lake City, UT, USA, February 20-23, 2008.
[8] S. Ryoo, C. Rodrigues, S. Stone, J. Stratton, S. Ueng, S. Baghsorkhi, W. Hwu, “Program Optimization Carving for GPU Computing,” The Journal of Parallel and Distributed Computing, 68(10), 2008.
[9] C. Lattner. “LLVM for OpenGL and other stuff.” LLVM Designers Conference, May 2007
[10] W. Mark and K. Proudfoot. “Compiling to a VLIW Fragment Pipeline.” Proceedings of SIGGRAPH/Eurographics Workshop on Graphics Hardware, Los Angeles California. July 2001
[11] M. Peercy, M. Olano, J. Airey, and P. Ungar. “Interactive Multi-Pass Programmable Shading”. Proceedings of the 27th annual conference on Computer graphics and interactive techniques, New Orleans, Louisiana. July 2000.
[12] A. Aho, M. Lam, R. Sethi and J. Ullman, “Compilers: Principles, Techniques and Tools(2nd Ed)”, Pearson Addison Wesley, Hong Kong, 2006.
[13] N. Sreraman and R. Govindarajan. “A Vectorizing Compiler for Multimedia Extensions,” The International Journal of Parallel Programming. Vol. 28, No 4, 2000.
[14.] D. Nuzman, M. Namolaru and J.Derby. “Compiling for an Indirect Vector Register Architecture,” Conference on Computing Frontiers, Ischia, Italy. May 2008.
電子全文 Fulltext
本電子全文僅授權使用者為學術研究之目的,進行個人非營利性質之檢索、閱讀、列印。請遵守中華民國著作權法之相關規定,切勿任意重製、散佈、改作、轉貼、播送,以免觸法。
論文使用權限 Thesis access permission:校內公開,校外永不公開 restricted
開放時間 Available:
校內 Campus: 已公開 available
校外 Off-campus:永不公開 not available

您的 IP(校外) 位址是 18.117.152.251
論文開放下載的時間是 校外不公開

Your IP address is 18.117.152.251
This thesis will be available to you on Indicate off-campus access is not available.

紙本論文 Printed copies
紙本論文的公開資訊在102學年度以後相對較為完整。如果需要查詢101學年度以前的紙本論文公開資訊,請聯繫圖資處紙本論文服務櫃台。如有不便之處敬請見諒。
開放時間 available 已公開 available

QR Code