研究生: |
張景焜 Chang, Jing Kun |
---|---|
論文名稱: |
使用非原子指令實現非阻斷式的鎖定機制用於移植無作業系統Pthread A non-blocking locking mechanism using non-atomic instructions for bare-metal Pthread porting |
指導教授: |
劉靖家
Liou, Jing Jia |
口試委員: |
金仲達
黃稚存 |
學位類別: |
碩士 Master |
系所名稱: |
電機資訊學院 - 電機工程學系 Department of Electrical Engineering |
論文出版年: | 2014 |
畢業學年度: | 102 |
語文別: | 英文 |
論文頁數: | 44 |
中文關鍵詞: | 使用非原子指令實現非阻斷式的鎖定機制用於移植無作業系統Pthread |
相關次數: | 點閱:1 下載:0 |
分享至: |
查詢本校圖書館目錄 查詢臺灣博碩士論文知識加值系統 勘誤回報 |
具有支援晶片上網路NOC 多核心平台已經由之前的學長提出並且實作完成, 這個支援晶片上網路多核心平台用來撰寫平行程式的平行程式模型是訊息傳遞 ( massage passing )。
另一個大多數程式設計者經常使用於撰寫的平行程式的模型是共享記憶體 ( shared memory ) 架構的平行程式模型,由於我們支援晶片上網路多核心平台尚未支援共享記憶體架構的平行程式模型,並且考慮到支援晶片上網路多核心平台程式碼的大小,由作業系統提供的Pthread 並不適合我們使用,因此我們才移植無作業系統( bare-metal ) Pthread, 無作業系統Pthread需自行實作處理環境切換 ( context switch ) 以及執行緒 ( threads ) 的排程。
令人非常意外的是,我們支援晶片上網路多核心平台使用的 OR1K 中央處理單元 CPU 並沒有支援原子 ( atomic ) 指令,所以我們才提出解決此問題的鎖定機制, 這個鎖定機制做的假設是在特定的記憶體空間上執行讀取與寫入的動作,當作是鏈接加載 ( Load-linked ) / 條件存儲 ( Store-conditional ) 記憶體的操作,為了達成鏈接加載 / 條件存儲記憶體的操作, 我們主要實作了三個部分去達到原子指令的效果, 分別是特定記憶體空間映射 ( mapping ) 機制、配合上 Load-linked 互連 ( interconnect ) 的硬體元件,最後使用鎖定機制的應用程式介面 ( API ) 來達到原子指令的效果,最後我們測試 splash-2 的應用程式來驗證我們移植的無作業系統 Pthread 和鎖定機制的正確性是否正確。
[1] S. Borkar, “Thousand Core Chips—A Technology Perspective”, in Proc. IEEE/ACM Design
Automation Conf. (DAC), 2007, pp. 746–749.
[2] Wen. Sheng. Chen, “Design of Non-blocking Communication Engine for NoC-based Platforms”,
Master’s thesis, National Tsing-Hua University, Electrical Engineering Department,
2014.
[3] Ting. Shuo. Hsu, “A DVFS Many-core ESL Simulation Platform with Software Communication
API”, Master’s thesis, National Tsing-Hua University, Electrical Engineering Department,
2011.
[4] Open SystemC Initiative, “IEEE Standard SystemC Language Reference Manual”, IEEE Std
1666-2005, pp. 1–423, Mar. 2006.
[5] D. C. Black, J. Donovan, B. Bunton, and A. Keist, SystemC: From the ground up, Springer
Verlag, 2009.
[6] Open SystemC Initiative, OSCI TLM 2.0 Language Reference Manual, July 2009.
[7] Open Core Protocol International Partnership, Open Core Protocol Specification Release 2.2,
Jan. 2007.
[8] D. Lampret, C.-M. Chen, M. Mlinar, J. Rydberg, M. Ziv-Av, C. Ziomkowski, G. McGary,
B. Gardner, R. Mathur, and M. Bolado, OpenRISC 1000 Architecture Manual rev 1.3, May
2006, http://opencores.org/or1k/Main Page.
[9] North American SystemC Users Group, “Bus Locking and Snooping”, dac, 2009.
43
[10] Imperas Software Limited, OVP Guide To Using Processor Modeles, 2013,
http://www.ovpworld.org/using-ovp-fast-processor-models-with-ovpsim-and-othersimulators.
[11] Yu. Hsun. Chen, “Design and Analysis of Inter-PE Communication on Many-Core Platform”,
Master’s thesis, National Tsing-Hua University, Computer Science Department, 2012.
[12] Tilera Corporation, ILIB API REFERENCE MANUAL, May 2008.