簡易檢索 / 詳目顯示

研究生: 李東祐
Lee, Tung-Yu
論文名稱: 多核心系統上的OpenMP研究與實作
The study and implementation of OpenMP on multi-core system
指導教授: 石維寬
Shih, Wei-Kuan
口試委員:
學位類別: 碩士
Master
系所名稱: 電機資訊學院 - 資訊系統與應用研究所
Institute of Information Systems and Applications
論文出版年: 2009
畢業學年度: 97
語文別: 中文
論文頁數: 41
中文關鍵詞: 平行程式編譯器OpenMP
外文關鍵詞: parallel program, compiler
相關次數: 點閱:3下載:0
分享至:
查詢本校圖書館目錄 查詢臺灣博碩士論文知識加值系統 勘誤回報
  • 為了簡化平行程式的設計,所以不斷有幫助平行設計的各種平行程式設計模型被提出來。而其中最主要的共享記憶體模型大致有ANSI X3H5、POSIX 執行緒模型和OpenMP模型三種,其中又以OpenMP模型在目前最常被使用來設計平行程式。考慮到目前雖然不斷有OpenMP相關的系統被推出,然而主要都是給使用C/C++或則Fortran所設計的程式所使用,但對於JAVA的版本卻幾乎沒有。然而JAVA是一個被廣泛使用的系統開發所使用的程式設計語言。因此本論文將在OpenMP3.0規格的基礎上做相關研究並以JAVA去實作出對應系統。因為當前的OpenMP3.0規格是為了讓使用C/C++或則Fortran所設計的程式來使用所定義的,因此本論文將討論以JAVA實作時該做哪些調整,像是directive表示方式的修改,以符合原本定義。並且也將新增某些特性,像是foreach迴圈的平行化,以利於在使用JAVA所設計的程式中使用。同時在論文中也會提出一些利於系統運作的實作建議,最後則會討論使用本系統去做平行運算時所呈現出的一些效能數據。


    For a topic of easy design, many parallel programming design models are offered, and the main shared memory models have ANSI X3H5、POSIX thread model and OpenMP model which is more often used to design parallel programs .Although many systems base on OpenMP have been offered, but the systems are mostly for C/C++ or Fortran and lack for JAVA .However JAVA is often applying for application system development, so in the paper we will do some research related to OpenMP3.0 specification and implement a corresponding system by JAVA. Because current OpenMP3.0 specification are for C/C++ or Fortran, so in the paper we will discuss what we adjust like the modification of directive format to match the original definition. And we will add some new characters like the parallelism of foreach to add utility rate in the programs designed by JAVA.
    In the end, we will also purpose some implementation suggestions for JAVA, and discuss the performance to the system base on the experimental data.

    中文摘要 I Abstract II 致謝 III 目錄 IV 圖目錄 VI 表目錄 VII 1. Introduction 1 1.1 Background 1 1.2 Motivation 1 2. OpenMP Overview 3 2.1Introduction to OpenMP 3 2.1.1 Execution Model 3 2.1.2 Memory Model 3 2.1.2.1 Structure 3 2.1.2.2 Flush Operation 4 2.1.2.3 Memory Consistency 4 2.2 Directives 4 2.2.1 Directive Format 5 2.2.2 Intenal Control Variables 5 2.2.3 Parallel Construct 6 2.2.4 Loop Construct 7 2.2.5 Sections Construct 9 2.2.6 Single Construct 10 2.2.7 Parallel Loop Construct 10 2.2.8 Parallel Sections Construct 10 2.2.9 Task Construct 11 2.2.10 Master Construct 12 2.2.11 Critical Construct 12 2.2.12 Barrier Construct 12 2.2.13 Taskwait Construct 13 2.2.14 Atomic Construct 13 2.2.15 Flush Construct 13 2.2.16 Ordered Construct 14 2.3 Data Environment 14 2.3.1 Private 14 2.3.2 Firstprivate 14 2.3.3 Lastprivate 14 2.3.4 Shared 15 2.3.5 Reduction 15 2.3.6 Default 15 2.4 Runtime Library Routines 16 2.5 Environment Variables 17 3. Implementation And Analysis 18 3.1 Basic Structure 18 3.1.1 Parser……………...…………………………………………………19 3.1.2 Code Transformation 21 3.1.3 Runtime Library 23 3.1.3.1 OMP 24 3.1.3.2 Tasks and Threads 25 3.1.3.3 Barriers 26 3.1.3.4 Reductions 26 3.1.3.5 Scheduling 26 3.1.3.6 Ordering 26 3.1.3.7 Locks 27 3.2 Construct Transformation 27 3.2.1 Parallel Construct 27 3.2.2 Task Construct 27 3.2.3 Taskwait Construct 29 3.2.4 Single Construct 30 3.2.5 Master Construct 30 3.2.6 Atomic Construct 31 3.2.7 Flush Construct 31 3.2.8 Foreach Construct 32 3.3 Loop Schedule 32 4. Experiment 35 4.1 Introduction 35 4.2 Experiment Environment 35 4.2.1 Loop Schedule Experiment 35 4.2.2 BenchMark Test 37 5. Conclusion And Future Work 39 6. Reference 40

    [1] J.M. Bull and M.E. Kambites. JOMP—an OpenMP-like Interface for Java. In Proc. Of the ACM 2000 Conf. on Java Grande, pages 44–53, San Francisco, CA, USA, 2000.
    [2] C. Liao, O. Hernandez, B. Chapman, W. Chen, and W. Zheng. OpenUH: An Optimizing,Portable OpenMP Compiler. In Proc. of the 12th Workshop on Compiler for Parallel Computers,pages 356–370, A Coruna, Spain, January 2006.
    [3] OpenMP C and C++ Application Program Interface version 3.0, May 2008. http://www.openmp.org
    [4] OpenMP C and C++ Application Program Interface version 2.5, May 2005. http://www.openmp.org
    [4] Jon Meyer & Troy Dwning ,Java Virtual Machine,O’Reilly 2000
    [5] Scott Oaks & Henry Wong, Java Threads, 3rd Edition,O’Reilly 2005
    [6] JavaCC,The Java Parser Generator,https://javacc.dev.java.net/
    [7] Allen I. Holub , COMPILER DESIGN IN C,1990
    [8] James Gosling, Bill Joy, Guy Steele, Gilad Bracha, Java(TM) Language Specification, The (3rd Edition),2005
    [9] T. Pohl, N. Th¨urey, F. Deserno, U. R¨ude, P. Lammers, G.Wellein, and T. Zeiser. Performance Evaluation of Parallel Large-Scale Lattice Boltzmann Applications on Three Supercomputing Architectures. In Proc. of the IEEE/ACM Supercomputing Conf. SC 2004, pages 21–33,Pittsburgh, PA, USA, August 2004.
    [10] J. Manson, W. Pugh, and S.V. Adve. The Java Memory Model. In Proc. of the 32nd ACM SIGPLAN-SIGACT Symp. on Principles of Programming Languages, pages 378–391, Long Beach, CA, USA, 2005.
    [11] How OpenMP* is Compiled, chunhua Liao and Lei Huang, university of Houston
    [12] Yun Zhang, Mihai Burcea, Victor Cheng, Ron Ho and Michael Voss, An Adaptive OpenMP Loop Scheduler for Hyperthreaded SMPs. International Conference on Parallel and Distributed Systems, San Francisco, 2004
    [13] Danaher, J.S., Lee, I.A., Leiserson, C.E.: Programming with Exceptions in JCilk. The Journal of Science of Computer Programming, 2006
    [14] Hoeflinger, J.P., de Supinski, B.R.: The OpenMP Memory Model. In: Proc. of the 1st Intl.Workshop on OpenMP (IWOMP 2005), Eugene, OR, USA (May 2005)
    [15] American National Standards Institute. ANSI Technical Committee X3H5. Parallel Processing Model for High-Level Programming Languages, 1993
    [16] IEEE. POSIX P1003.4a: Threads Extension for Portable Operating Systems. Piscataway, NJ: IEEE Press, 1994
    [17] http://www.openmp.org
    [18] http://www.google.com.tw/
    [19] S. V. Adve and K. Gharachorloo, “Shared Memory Consistency Models: A Tutorial”, IEEE Computer, 29(12), pp.66-76, December 1996
    [20] http://mathworld.wolfram.com/MandelbrotSet.html

    無法下載圖示 全文公開日期 本全文未授權公開 (校內網路)
    全文公開日期 本全文未授權公開 (校外網路)
    全文公開日期 本全文未授權公開 (國家圖書館:臺灣博碩士論文系統)
    QR CODE