Mercurial > hg > Members > amothic > TRW
comparison Paper/paper.tex @ 2:7efb3ef94295 draft
add a section of benchmark
author | Daichi TOMA <toma@cr.ie.u-ryukyu.ac.jp> |
---|---|
date | Sun, 22 Jul 2012 22:08:59 +0900 |
parents | fa9cfac50776 |
children | 4fc34730ac45 |
comparison
equal
deleted
inserted
replaced
1:fa9cfac50776 | 2:7efb3ef94295 |
---|---|
58 \end{center} | 58 \end{center} |
59 \caption{Scheduler} | 59 \caption{Scheduler} |
60 \label{fig:scheduler} | 60 \label{fig:scheduler} |
61 \end{figure} | 61 \end{figure} |
62 | 62 |
63 \section{マルチコア上での並列実行の機構}\label{section:impl} | 63 % Cell の説明いれる |
64 | |
65 PlayStation 3/Cell 上の場合, 各 SPE に Task が割り当てられ, 並列に実行される. | |
66 | |
67 今回新たに, Mac OS X, Linux 上でも並列に実行させることを可能にした. | |
68 これは, PlayStation 3/Cell の Mailbox に対応させる形で, | |
69 Synchronized Queue を用いて Mac OS X, Linux 側の Cerium Task Manager へ移植したものである. | |
70 操作しているスレッドが常に1つになるよう, バイナリセマフォで管理されている. | |
71 各スレッドは, input 用と output 用として Synchronized Queue を2つ持っており, | |
72 管理スレッドからタスクを受けて並列に実行するようになっている. | |
73 | |
74 また, PlayStation 3/Cell と違い各 CPU で同じメモリ空間が利用できるため, | |
75 DMA転送を用いていた箇所をポインタ渡しをするように修正し, 速度の向上を図った. | |
76 | 64 |
77 % \subsection{Mailbox} | 65 % \subsection{Mailbox} |
78 % Mailbox は, Cell の機能の1つである. | 66 % Mailbox は, Cell の機能の1つである. |
79 % Mailbox は, PPE と SPE の間を双方向で, 32 bit メッセージの受け渡しが可能であり, | 67 % Mailbox は, PPE と SPE の間を双方向で, 32 bit メッセージの受け渡しが可能であり, |
80 % FIFO キュー構造になっている. | 68 % FIFO キュー構造になっている. |
81 | 69 |
70 \section{mechanism of parallel execution on multi-core}\label{section:impl} | |
82 | 71 |
83 \section{ベンチマーク} | 72 If on a PlayStation 3, Task is assigned to each SPE, then to be executed in parallel. |
84 Word Count, Sort 及び Prime Counter の例題を用いて, 計測した. | 73 Cerium Task Manager possible to be executed in parallel on Mac OSX and Linux anew. |
85 それぞれ入力として, 100MB のテキストファイルの単語数カウント, 10 万入力のソート, 100 万までの範囲の素数を全て数え上げるようになっている. | |
86 比較対象として, PlayStation 3/Cell においても同様の例題を用いて計測している. | |
87 どちらも, 最適化レベルは最大にしてある. | |
88 | 74 |
89 表\ref{table:benchmark}に結果を示す. | 75 We implement a synchronized queue on Mac OS X and Linux. |
76 The synchronized queue corresponds to the Mailbox on Playstation 3. | |
77 For only one thread use the synchronized queue, that was managed by a binary semaphore. | |
78 Each threads has two synchronized queues for input and output, | |
79 be able to execute in parallel tasks was received under managment thread. | |
90 | 80 |
91 {\bf 実験環境} | 81 Furthermore, because multicore available the same memory space in comparison with Playstation 3, |
82 we modified to pass the pointer a spots that were using the transfer DMA, aimed to improve the speed. | |
83 | |
84 \section{Benchmark} | |
85 | |
86 Performance was measured using the example of Word Count, Sort and Prime Counter. | |
87 Word Count is to count number of words in the 100MBtext file. | |
88 Sort is to sort in one hundred thousand pieces of numeric. | |
89 Prime Counter is to enumerate all the prime numbers in the range of up to one million. | |
90 for comparsion performance was measured using the same example in PlayStation 3. | |
91 Both the optimization level is at the maximum. | |
92 | |
93 The results are shown in Table \ref{table:benchmark}. | |
94 | |
95 {\bf Experiment environment} | |
92 | 96 |
93 CentOS/Xeon | 97 CentOS/Xeon |
94 \begin{small} | 98 \begin{small} |
95 \begin{itemize}\small | 99 \begin{itemize}\small |
96 \item OS : CentOS 6.0 | 100 \item OS : CentOS 6.0 |
137 \end{tiny} | 141 \end{tiny} |
138 | 142 |
139 % Word Count 354 / 70 = 5.0571 | 143 % Word Count 354 / 70 = 5.0571 |
140 % Sort 846 / 163 = 5.1901 | 144 % Sort 846 / 163 = 5.1901 |
141 % Prime Counter 266 / 50 = 5.32 | 145 % Prime Counter 266 / 50 = 5.32 |
142 表\ref{table:benchmark}より, CentOS上で 6 CPU を利用した場合, 1 CPU を利用した場合と比較して | 146 |
143 Word Count の例題で約 5.1 倍, Sort の例題で約 5.2 倍, Prime Counter の例題で, 約 5.3倍の速度向上が見られる. | 147 We use 6 CPU on CentOS, as compared with the case using 1 CPU, |
144 しかしながら, 24 CPU を利用した場合, 12 CPU を利用した場合と比較して速度は上がっているものの速度向上率が落ちている. | 148 about 5.1 times the speed improvement in the example of WordCount, |
145 これは並列化率が低いために性能を活かすことができず, 速度向上が頭打ちになっているとアムダールの法則\cite{amdahl}から考えられる. | 149 about 5.2 times the speed improvement in the example of Sort, |
146 並列化率の向上は今後の課題である. | 150 about 5.3 times the speed improvement in the example of Prime Counter. |
151 If we use 24 CPU, the speed is rising as compared with the case using 12 CPU, however, the speed improvement rate is down. | |
152 This is probably concurrency is low, and that seems to be grinding to a halt speed improvement from Amdahl's law\cite{amdahl}. | |
153 Improvement of parallelization rate is a challenge for the future. | |
147 | 154 |
148 % また, 図\ref{fig:multi_result}より, 台数効果が確認できる. | 155 % また, 図\ref{fig:multi_result}より, 台数効果が確認できる. |
149 | 156 |
150 \section{まとめ} | 157 \section{まとめ} |
151 本稿では, 既存の Cerium Task Manager の実装と新しい並列実行の機構について説明した. | 158 本稿では, 既存の Cerium Task Manager の実装と新しい並列実行の機構について説明した. |