標題: PCI上雙核心指令溝通管道的建立
Instruction Socket for Two CPUs on the PCI Bus
作者: 游雅嵐
Yu, Ya-Lan
張文鐘
Chang, Wen-Thong
電信工程研究所
關鍵字: 雙核心;溝通;共享記憶體;分層;驅動程式;two different CPUs;communication;shared memory;multi-layer;driver;C runtime service
公開日期: 2010
摘要: 我們發展一套分散式的訊號處理系統,讓一個應用程式分散在兩個核心上同時進行,於是不同核心間就需要做訊息與指令的溝通,所以我們就建造了一個溝通管道讓應用程式可以使用它來做不同核心間的溝通。 我們讓影像處理與影像壓縮由一顆CPU負責執行,另一個CPU則負責做檔案系統與周邊裝置管理,因此做影像壓縮的CPU就需要利用負責檔案管理的CPU做影像讀寫,於是我們利用兩顆CPU間的共享記憶體(shared memory)做為訊息傳遞媒介,並搭配阻斷式(block)及中斷機制建立雙核心在PCI 匯流排上的CPU間指令與資料溝通。 我們的溝通管道分為兩個層面,應用層面為一個雙向的client-server架構,核心層面為中斷處理機制,並利用signaling與semaphore作為兩層面之間的非同步啟動機制,核心層面的架構讓核心間的溝通由硬體中斷最後達到實質的訊息傳輸,訊息傳輸完才啟動應用層等待中的server,開始針對接收到的訊息做服務。為了達到這些目標,我們便在作業系統中加入驅動程式來處理硬體中斷後各項資料搬移的動作,並建立一套功能函式讓應用程式使用,以便在兩顆CPU間進行指令溝通。
We develop a distributed signal processing system where an application can distribute functional operations on two different CPUs to complete a service, so we have to build communication protocols to let the CPUs exchange their messages to each other. One CPU is responsible for capturing the video and processing it, and the other CPU controls the file system and peripheral devices. In order to write to or read from the file system for the first CPU, shared memory, interrupt and blocking mechanism is used to establish the communication between the two CPUs on the PCI bus. Our communication protocol has two aspects. The first one is application layer. We can see the communication channel as a client-server structure. The second one is the kernel or OS layer. It uses interrupt mechanism to notify the arrival of messages and use signaling and semaphore for the synchronization and notify the application to start receiving messages. So the OS layer completes the communication between two CPUs from hardware interrupt to real message transferring. After that, application can wake up the waiting server to receive the messages transferred by OS layer and processing the messages. For implementation, we design a linux driver to do the OS layer message transferring and we also build a user mode library as an interface of the application and the driver to do the communication.
URI: http://140.113.39.130/cdrfb3/record/nctu/#GT079713508
http://hdl.handle.net/11536/44527
Appears in Collections:Thesis


Files in This Item:

  1. 350801.pdf

If it is a zip file, please download the file and unzip it, then open index.html in a browser to view the full text content.