annotate Slide/prosym.pdf.html @ 5:07b7aba92874

fix
author tobaru
date Sun, 20 May 2018 18:41:38 +0900
parents c456e4d68e1a
children dfa8973bfe10
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
tobaru
parents:
diff changeset
1 <!DOCTYPE html>
tobaru
parents:
diff changeset
2 <html>
tobaru
parents:
diff changeset
3 <head>
tobaru
parents:
diff changeset
4 <meta http-equiv="content-type" content="text/html;charset=utf-8">
tobaru
parents:
diff changeset
5 <title>Gears OS のモジュール化と並列 API</title>
tobaru
parents:
diff changeset
6
tobaru
parents:
diff changeset
7 <meta name="generator" content="Slide Show (S9) v2.5.0 on Ruby 2.4.1 (2017-03-22) [x86_64-darwin15]">
tobaru
parents:
diff changeset
8 <meta name="author" content="Mitsuki Miyagi, Yu Tobaru, Shinji Kono" >
tobaru
parents:
diff changeset
9
tobaru
parents:
diff changeset
10 <!-- style sheet links -->
tobaru
parents:
diff changeset
11 <link rel="stylesheet" href="s6/themes/screen.css" media="screen">
tobaru
parents:
diff changeset
12 <link rel="stylesheet" href="s6/themes/print.css" media="print">
tobaru
parents:
diff changeset
13 <link rel="stylesheet" href="s6/themes/blank.css" media="screen,projection">
tobaru
parents:
diff changeset
14
tobaru
parents:
diff changeset
15 <!-- JS -->
tobaru
parents:
diff changeset
16 <script src="s6/js/jquery-1.11.3.min.js"></script>
tobaru
parents:
diff changeset
17 <script src="s6/js/jquery.slideshow.js"></script>
tobaru
parents:
diff changeset
18 <script src="s6/js/jquery.slideshow.counter.js"></script>
tobaru
parents:
diff changeset
19 <script src="s6/js/jquery.slideshow.controls.js"></script>
tobaru
parents:
diff changeset
20 <script src="s6/js/jquery.slideshow.footer.js"></script>
tobaru
parents:
diff changeset
21 <script src="s6/js/jquery.slideshow.autoplay.js"></script>
tobaru
parents:
diff changeset
22
tobaru
parents:
diff changeset
23 <!-- prettify -->
tobaru
parents:
diff changeset
24 <link rel="stylesheet" href="scripts/prettify.css">
tobaru
parents:
diff changeset
25 <script src="scripts/prettify.js"></script>
tobaru
parents:
diff changeset
26
tobaru
parents:
diff changeset
27 <style>
tobaru
parents:
diff changeset
28 .slide {page-break-after: always;}
tobaru
parents:
diff changeset
29 </style>
tobaru
parents:
diff changeset
30
tobaru
parents:
diff changeset
31
tobaru
parents:
diff changeset
32
tobaru
parents:
diff changeset
33
tobaru
parents:
diff changeset
34 </head>
tobaru
parents:
diff changeset
35 <body>
tobaru
parents:
diff changeset
36
tobaru
parents:
diff changeset
37 <div class="layout">
tobaru
parents:
diff changeset
38 <div id="header"></div>
tobaru
parents:
diff changeset
39 <div id="footer">
tobaru
parents:
diff changeset
40 <div align="right">
tobaru
parents:
diff changeset
41 <img src="s6/images/logo.svg" width="200px">
tobaru
parents:
diff changeset
42 </div>
tobaru
parents:
diff changeset
43 </div>
tobaru
parents:
diff changeset
44 </div>
tobaru
parents:
diff changeset
45
tobaru
parents:
diff changeset
46 <div class="presentation">
tobaru
parents:
diff changeset
47
tobaru
parents:
diff changeset
48 <div class='slide cover'>
tobaru
parents:
diff changeset
49 <table width="90%" height="90%" border="0" align="center">
tobaru
parents:
diff changeset
50 <tr>
tobaru
parents:
diff changeset
51 <td>
tobaru
parents:
diff changeset
52 <div align="center">
tobaru
parents:
diff changeset
53 <h1><font color="#808db5">Gears OS のモジュール化と並列 API</font></h1>
tobaru
parents:
diff changeset
54 </div>
tobaru
parents:
diff changeset
55 </td>
tobaru
parents:
diff changeset
56 </tr>
tobaru
parents:
diff changeset
57 <tr>
tobaru
parents:
diff changeset
58 <td>
tobaru
parents:
diff changeset
59 <div align="left">
tobaru
parents:
diff changeset
60 Mitsuki Miyagi, Yu Tobaru, Shinji Kono
tobaru
parents:
diff changeset
61 琉球大学
tobaru
parents:
diff changeset
62 <hr style="color:#ffcc00;background-color:#ffcc00;text-align:left;border:none;width:100%;height:0.2em;">
tobaru
parents:
diff changeset
63 </div>
tobaru
parents:
diff changeset
64 </td>
tobaru
parents:
diff changeset
65 </tr>
tobaru
parents:
diff changeset
66 </table>
tobaru
parents:
diff changeset
67 </div>
tobaru
parents:
diff changeset
68
tobaru
parents:
diff changeset
69 <div class='slide '>
tobaru
parents:
diff changeset
70 <!-- === begin markdown block ===
tobaru
parents:
diff changeset
71
tobaru
parents:
diff changeset
72 generated by markdown/1.2.0 on Ruby 2.4.1 (2017-03-22) [x86_64-darwin15]
5
tobaru
parents: 4
diff changeset
73 on 2018-05-20 17:18:27 +0900 with Markdown engine kramdown (1.13.2)
0
tobaru
parents:
diff changeset
74 using options {}
tobaru
parents:
diff changeset
75 -->
tobaru
parents:
diff changeset
76
tobaru
parents:
diff changeset
77 <!-- _S9SLIDE_ -->
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
78 <h1 id="gears-os">Gears OS</h1>
0
tobaru
parents:
diff changeset
79 <ul>
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
80 <li>現代のOS では拡張性と信頼性を両立させることが要求されている。
0
tobaru
parents:
diff changeset
81 <ul>
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
82 <li>時代と共にハードウェア、サービスが進歩していき、その度に OS を検証できる必要があるため、拡張性が必要。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
83 <li>OS は非決定的な実行を持ち、従来の OS ではテストしきれない部分が残ってしまうため、信頼性が欠けてしまう。</li>
0
tobaru
parents:
diff changeset
84 </ul>
tobaru
parents:
diff changeset
85 </li>
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
86 <li>本研究室では、それらを実現することを目標に Gears OS の開発を行なっている。</li>
0
tobaru
parents:
diff changeset
87 </ul>
tobaru
parents:
diff changeset
88
tobaru
parents:
diff changeset
89
tobaru
parents:
diff changeset
90 </div>
tobaru
parents:
diff changeset
91 <div class='slide '>
tobaru
parents:
diff changeset
92 <!-- _S9SLIDE_ -->
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
93 <h1 id="api-">API と実装の分離</h1>
0
tobaru
parents:
diff changeset
94 <ul>
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
95 <li>Gears OS は Continuation based C(以下、CbC)によって記述されている。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
96 <li>CbC は Code Gear と Data Gear の単位でプログラムを記述していて、システムやアプリケーションを作る際に、この2つは柔軟に再利用する必要がある。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
97 <li>この時に、機能を接続する API と実装の分離が可能であることが望ましい。</li>
0
tobaru
parents:
diff changeset
98 </ul>
tobaru
parents:
diff changeset
99
tobaru
parents:
diff changeset
100
tobaru
parents:
diff changeset
101 </div>
tobaru
parents:
diff changeset
102 <div class='slide '>
tobaru
parents:
diff changeset
103 <!-- _S9SLIDE_ -->
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
104 <h1 id="api">並列API</h1>
0
tobaru
parents:
diff changeset
105 <ul>
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
106 <li>Geas OS 信頼性を保証するために、形式化されたモジュールシステムが必要である。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
107 <li>本研究では、モジュールシステムとその応用である並列APIについて考察する。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
108 <li>並列APIは継続を基本とした関数型プログラミングと両立する必要があり、ここでは CbC の goto 文を拡張した par goto を導入する。</li>
0
tobaru
parents:
diff changeset
109 </ul>
tobaru
parents:
diff changeset
110
tobaru
parents:
diff changeset
111
tobaru
parents:
diff changeset
112 </div>
tobaru
parents:
diff changeset
113 <div class='slide '>
tobaru
parents:
diff changeset
114 <!-- _S9SLIDE_ -->
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
115 <h1 id="section">スライドの流れ</h1>
2
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
116 <ul>
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
117 <li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
118 <font color="red">CbC</font>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
119 </li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
120 <li>Gears OS における並列実行</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
121 <li>比較</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
122 <li>今後の課題</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
123 </ul>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
124
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
125
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
126 </div>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
127 <div class='slide '>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
128 <!-- _S9SLIDE_ -->
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
129 <h1 id="cbc">CbC</h1>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
130 <ul>
5
tobaru
parents: 4
diff changeset
131 <li>ノーマルレベルとメタレベルの計算を1つの言語で表現できる言語として、本研究室で設計した CbC を用いる。</li>
2
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
132 <li>ノーマルレベルの計算
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
133 <ul>
5
tobaru
parents: 4
diff changeset
134 <li>コンピュータの計算はプログラミング言語で行われる。</li>
2
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
135 <li>その部分をノーマルレベルの計算と呼ぶ。</li>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
136 </ul>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
137 </li>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
138 <li>メタレベルの計算
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
139 <ul>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
140 <li>コードが実行される際の以下の部分が、メタレベルの計算という。
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
141 <ul>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
142 <li>処理系の詳細や使用する資源</li>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
143 <li>コードの仕様や型などの言語以外の部分</li>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
144 </ul>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
145 </li>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
146 </ul>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
147 </li>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
148 </ul>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
149
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
150
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
151 </div>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
152 <div class='slide '>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
153 <!-- _S9SLIDE_ -->
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
154 <h1 id="cbc-1">CbC</h1>
2
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
155 <ul>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
156 <li>CbC を用いることで、ノーマルレベルの計算の信頼性をメタレベルから保証できるようになる。</li>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
157 <li>CbC を用いてCode Gear と Data Gear、メタ構造を導入する。</li>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
158 </ul>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
159
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
160
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
161 </div>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
162 <div class='slide '>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
163 <!-- _S9SLIDE_ -->
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
164 <h1 id="cbc-">CbC の構文</h1>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
165 <ul lang="c">
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
166 <li>CbC の Code Gear は __code という型を持つ関数として記述する。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
167 <li>継続で次の Code Gear に遷移するので、戻り値は持たない。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
168 <li>遷移は goto 文による継続で処理を行い、引数として入出力を行う。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
169 </ul>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
170 <pre><code>__code cg0(int a, int b) {
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
171 goto cg1(a+b);
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
172 }
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
173 __code cg1(int c) {
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
174 goto cg2(c);
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
175 }
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
176 </code></pre>
5
tobaru
parents: 4
diff changeset
177
tobaru
parents: 4
diff changeset
178
tobaru
parents: 4
diff changeset
179 </div>
tobaru
parents: 4
diff changeset
180 <div class='slide '>
tobaru
parents: 4
diff changeset
181 <!-- _S9SLIDE_ -->
tobaru
parents: 4
diff changeset
182 <h1 id="section-1">スライドの流れ</h1>
tobaru
parents: 4
diff changeset
183 <ul>
tobaru
parents: 4
diff changeset
184 <li>CbC</li>
tobaru
parents: 4
diff changeset
185 <li>
tobaru
parents: 4
diff changeset
186 <font color="red">Gears OS における並列実行</font>
tobaru
parents: 4
diff changeset
187 </li>
tobaru
parents: 4
diff changeset
188 <li>比較</li>
tobaru
parents: 4
diff changeset
189 <li>今後の課題</li>
tobaru
parents: 4
diff changeset
190 </ul>
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
191
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
192
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
193 </div>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
194 <div class='slide '>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
195 <!-- _S9SLIDE_ -->
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
196 <h1 id="gears-">Gears における並列実行</h1>
2
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
197 <ul>
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
198 <li>Gears OS ではメタ計算を柔軟に記述するためのプログラミングの単位として Code Gear と Data Gear を用いる。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
199 <li>それぞれにメタレベルの単位が存在し、Meta Data Gear と Meta Code Gear と呼ぶ。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
200 <li>メタレベルの計算は Perl スクリプトによって生成され、Code Gear で記述される。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
201 </ul>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
202
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
203
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
204 </div>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
205 <div class='slide '>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
206 <!-- _S9SLIDE_ -->
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
207 <h1 id="interface">Interface</h1>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
208 <ul>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
209 <li>この時、Code Gear と Deta Gear は Interface と呼ばれるまとまり(モジュール)で記述される。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
210 <li>Interface 作成時に Code Gear の集合を指定することにより複数の実装を持つことができる。</li>
2
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
211 </ul>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
212
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
213
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
214 </div>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
215 <div class='slide '>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
216 <!-- _S9SLIDE_ -->
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
217 <h1 id="context">Context</h1>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
218 <ul>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
219 <li>1つのスレッド内で使われる Interface の Code Gear と Data Gear は Meta Data Gear に格納される。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
220 <li>この Meta Data Gear を Context と呼ぶ。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
221 <li>Context を複製して複数の CPU に割り当てることにより並列実行が可能になる。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
222 </ul>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
223
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
224
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
225 </div>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
226 <div class='slide '>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
227 <!-- _S9SLIDE_ -->
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
228 <h1 id="par-goto">par goto</h1>
2
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
229 <ul>
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
230 <li>Context の複製には par goto を用いる。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
231 <li>他に、入力の同期、タスクスケジューラへの Context の登録が行われる。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
232 </ul>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
233
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
234
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
235 </div>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
236 <div class='slide '>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
237 <!-- _S9SLIDE_ -->
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
238 <h1 id="task">Task</h1>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
239 <ul>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
240 <li>Context は Task でもある。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
241 <li>実行する Code Gear と Data Gear を全て持っている。</li>
2
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
242 </ul>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
243
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
244
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
245 </div>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
246 <div class='slide '>
60405cc47b3a chapter1
tobaru
parents: 0
diff changeset
247 <!-- _S9SLIDE_ -->
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
248 <h1 id="exit">__exit</h1>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
249 <ul lang="c">
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
250 <li>par goto で生成された Task は __exit に継続することで終了する。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
251 <li>GearsOS の Task は Output Data Gear を生成した時点で終了する。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
252 <li>そのため、par goto では直接 __exit に継続せず、Output Data Gear への書き出し処理に継続される。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
253 <li>Code Gear と Data Gear の依存関係をノーマルレベルで記述できるようになる。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
254 </ul>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
255 <pre><code>__code code1(Integer *integer1, Integer * integer2, Integer *output) {
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
256 par goto add(integer1, integer2, output, __exit);
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
257 goto code2();
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
258 }
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
259 </code></pre>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
260
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
261
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
262 </div>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
263 <div class='slide '>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
264 <!-- _S9SLIDE_ -->
5
tobaru
parents: 4
diff changeset
265 <h1 id="section-2">スライドの流れ</h1>
0
tobaru
parents:
diff changeset
266 <ul>
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
267 <li>CbC</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
268 <li>Gears OS における並列実行</li>
0
tobaru
parents:
diff changeset
269 <li>
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
270 <font color="red">比較</font>
0
tobaru
parents:
diff changeset
271 </li>
tobaru
parents:
diff changeset
272 <li>今後の課題</li>
tobaru
parents:
diff changeset
273 </ul>
tobaru
parents:
diff changeset
274
tobaru
parents:
diff changeset
275
tobaru
parents:
diff changeset
276 </div>
tobaru
parents:
diff changeset
277 <div class='slide '>
tobaru
parents:
diff changeset
278 <!-- _S9SLIDE_ -->
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
279 <h1 id="gears-os-">Gears OS の評価</h1>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
280 <ul>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
281 <li>CPU、GPU環境で Gears OS の測定を行う。</li>
4
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
282 <li>使用した環境は次のようになる。
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
283 <ul>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
284 <li>CPU 環境
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
285 <ul>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
286 <li>Model : Dell PowerEdgeR630</li>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
287 <li>Memory : 768GB</li>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
288 <li>CPU : 2 × 18-Core Intel Xeon 2.30GHz</li>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
289 </ul>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
290 </li>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
291 <li>CPU 環境
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
292 <ul>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
293 <li>GPU : GeForce GTX 1070</li>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
294 <li>Cores : 1920</li>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
295 <li>ClockSpeed : 1683MHZ</li>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
296 <li>Memory Size : 8GB GDDR5</li>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
297 </ul>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
298 </li>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
299 </ul>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
300 </li>
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
301 </ul>
0
tobaru
parents:
diff changeset
302
tobaru
parents:
diff changeset
303
tobaru
parents:
diff changeset
304 </div>
tobaru
parents:
diff changeset
305 <div class='slide '>
tobaru
parents:
diff changeset
306 <!-- _S9SLIDE_ -->
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
307 <h1 id="twice">Twice</h1>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
308 <ul>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
309 <li>評価には与えられた整数配列の全ての要素を2倍にする例題である Twice を使う。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
310 <li>Twice では 通信時間を考慮しなければ、CPU より コア数の多い GPU が有利となる。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
311 <li>要素数2^27のデータに対する Twice の実行結果を示す。
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
312 <ul>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
313 <li>CPU では2^27のデータを64個のデータに分割した。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
314 <li>kernel only は 通信速度を除いた速度である。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
315 </ul>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
316 </li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
317 </ul>
0
tobaru
parents:
diff changeset
318
4
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
319 <table border="1" align="center" width="50%">
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
320 <tbody>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
321 <tr>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
322 <td style="text-align: center;">Processor</td>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
323 <td style="text-align: center;">Time(ms)</td>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
324 </tr>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
325 <tr>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
326 <td style="text-align: center;">1 CPU</td>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
327 <td style="text-align: right;">1181.215</td>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
328 </tr>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
329 <tr>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
330 <td style="text-align: center;">2 CPUs</td>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
331 <td style="text-align: right;">627.914</td>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
332 </tr>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
333 <tr>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
334 <td style="text-align: center;">4 CPUs</td>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
335 <td style="text-align: right;">324.059</td>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
336 </tr>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
337 <tr>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
338 <td style="text-align: center;">8 CPUs</td>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
339 <td style="text-align: right;">159.932</td>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
340 </tr>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
341 <tr>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
342 <td style="text-align: center;">16 CPUs</td>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
343 <td style="text-align: right;">85.518</td>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
344 </tr>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
345 <tr>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
346 <td style="text-align: center;">32 CPUs</td>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
347 <td style="text-align: right;">43.496</td>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
348 </tr>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
349 <tr>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
350 <td style="text-align: center;">GPU</td>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
351 <td style="text-align: right;">127.018</td>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
352 </tr>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
353 <tr>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
354 <td style="text-align: center;">GPU(kernel only)</td>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
355 <td style="text-align: right;">6.018</td>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
356 </tr>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
357 </tbody>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
358 </table>
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
359
0
tobaru
parents:
diff changeset
360
tobaru
parents:
diff changeset
361 </div>
tobaru
parents:
diff changeset
362 <div class='slide '>
tobaru
parents:
diff changeset
363 <!-- _S9SLIDE_ -->
5
tobaru
parents: 4
diff changeset
364 <h1 id="section-3">評価の考察</h1>
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
365 <ul>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
366 <li>コア数が上がるごとに、処理速度が上がっている。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
367 <li>GPUでの実行は 32CPU に比べて約7.2倍の速度向上が見られた。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
368 <li>通信速度を含めると 16CPU より遅い。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
369 </ul>
0
tobaru
parents:
diff changeset
370
tobaru
parents:
diff changeset
371
tobaru
parents:
diff changeset
372 </div>
tobaru
parents:
diff changeset
373 <div class='slide '>
tobaru
parents:
diff changeset
374 <!-- _S9SLIDE_ -->
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
375 <h1 id="go-">Go 言語との比較</h1>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
376 <ul>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
377 <li>Go 言語でも Twice を用いた検証を行い、Gears OS との速度比較を行なった。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
378 <li>1CPU と 32CPU では約4.33倍の速度向上が見られた。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
379 <li>CPU数による速度向上は、Gears OS の方が上だが、処理速度では Go言語の方が速い結果となった。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
380 </ul>
4
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
381 <div style="text-align: center;">
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
382 <img src="./image/vsgo.svg" alt="message" width="500" />
c456e4d68e1a add image file
tobaru
parents: 3
diff changeset
383 </div>
0
tobaru
parents:
diff changeset
384
tobaru
parents:
diff changeset
385
tobaru
parents:
diff changeset
386 </div>
tobaru
parents:
diff changeset
387 <div class='slide '>
tobaru
parents:
diff changeset
388 <!-- _S9SLIDE_ -->
5
tobaru
parents: 4
diff changeset
389 <h1 id="section-4">スライドの流れ</h1>
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
390 <ul>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
391 <li>CbC</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
392 <li>Gears OS における並列実行</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
393 <li>比較</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
394 <li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
395 <font color="red">今後の課題</font>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
396 </li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
397 </ul>
0
tobaru
parents:
diff changeset
398
tobaru
parents:
diff changeset
399
tobaru
parents:
diff changeset
400 </div>
tobaru
parents:
diff changeset
401 <div class='slide '>
tobaru
parents:
diff changeset
402 <!-- _S9SLIDE_ -->
5
tobaru
parents: 4
diff changeset
403 <h1 id="section-5">今後の課題</h1>
3
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
404 <ul>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
405 <li>Go 言語との比較から 1CPU での動作が遅いことがわかった。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
406 <li>par goto 文を使用することで、Contextを生成し、並列処理を行う。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
407 <li>しかし、Context はメモリ空間の確保や使用する全ての Code Gear Data Gear の設定をする必要があり、生成に時間がかかってしまう事が原因。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
408 <li>処理が軽い場合は Context を生成しないようなチューニングが必要である。</li>
7f5c0330e711 add module API
tobaru
parents: 2
diff changeset
409 </ul>
0
tobaru
parents:
diff changeset
410 <!-- === end markdown block === -->
tobaru
parents:
diff changeset
411 </div>
tobaru
parents:
diff changeset
412
tobaru
parents:
diff changeset
413
tobaru
parents:
diff changeset
414 </div><!-- presentation -->
tobaru
parents:
diff changeset
415 </body>
tobaru
parents:
diff changeset
416 </html>