annotate slide/thesis.pdf.html @ 23:9a6609a2f987

twaek
author ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
date Thu, 10 Feb 2022 01:08:27 +0900
parents bd9284f9151d
children 90e6ac8805e2
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
14
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
1
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
2
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
3
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
4
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
5
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
6 <!DOCTYPE html>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
7 <html>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
8 <head>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
9 <meta http-equiv="content-type" content="text/html;charset=utf-8">
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
10 <title>GearsOSの分散ファイルシステムの設計</title>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
11
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
12 <meta name="generator" content="Slide Show (S9) v4.1.0 on Ruby 2.6.8 (2021-07-07) [universal.x86_64-darwin21]">
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
13 <meta name="author" content="Takahiro Ikki, Shinji Kono" >
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
14
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
15 <!-- style sheet links -->
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
16 <link rel="stylesheet" href="s6/themes/screen.css" media="screen">
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
17 <link rel="stylesheet" href="s6/themes/print.css" media="print">
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
18 <link rel="stylesheet" href="s6/themes/blank.css" media="screen,projection">
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
19
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
20 <!-- JS -->
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
21 <script src="s6/js/jquery-1.11.3.min.js"></script>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
22 <script src="s6/js/jquery.slideshow.js"></script>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
23 <script src="s6/js/jquery.slideshow.counter.js"></script>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
24 <script src="s6/js/jquery.slideshow.controls.js"></script>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
25 <script src="s6/js/jquery.slideshow.footer.js"></script>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
26 <script src="s6/js/jquery.slideshow.autoplay.js"></script>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
27
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
28 <!-- prettify -->
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
29 <link rel="stylesheet" href="scripts/prettify.css">
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
30 <script src="scripts/prettify.js"></script>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
31
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
32 <style>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
33 .slide {page-break-after: always;}
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
34 </style>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
35
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
36
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
37
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
38
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
39 </head>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
40 <body>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
41
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
42 <div class="layout">
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
43 <div id="header"></div>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
44 <div id="footer">
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
45 <div align="right">
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
46 <img src="s6/images/logo.svg" width="200px">
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
47 </div>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
48 </div>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
49 </div>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
50
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
51 <div class="presentation">
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
52
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
53 <div class='slide cover'>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
54 <table width="90%" height="90%" border="0" align="center">
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
55 <tr>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
56 <td>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
57 <div align="center">
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
58 <h1><font color="#808db5">GearsOSの分散ファイルシステムの設計</font></h1>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
59 </div>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
60 </td>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
61 </tr>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
62 <tr>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
63 <td>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
64 <div align="left">
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
65 Takahiro Ikki, Shinji Kono
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
66 琉球大学
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
67 <hr style="color:#ffcc00;background-color:#ffcc00;text-align:left;border:none;width:100%;height:0.2em;">
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
68 </div>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
69 </td>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
70 </tr>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
71 </table>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
72 </div>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
73
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
74
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
75 <div class='slide'>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
76
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
77 <!-- _S9SLIDE_ -->
22
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
78 <h2 id="gearsosのファイルシステムの設計方針">GearsOSのファイルシステムの設計方針</h2>
14
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
79 <ul>
22
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
80 <li>GearsOSはGearという単位で記述が行われているOSプロジェクトである</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
81 <li>GearsOSのファイルシステムも同様にDataGearの単位で構成したい</li>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
82 <li>GearsOSのファイルシステムの設計と実装を行った</li>
22
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
83 <li>ファイルに取り扱うデータに対応した複数のストリームを持たせたい
14
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
84 <ul>
22
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
85 <li>従来では異なるデータでも単一のストリームから入力される</li>
14
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
86 </ul>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
87 </li>
22
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
88 <li>GearsOSには将来的にアプリケーションが担う重要な機能をOSに取り込みたい
14
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
89 <ul>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
90 <li>バックアップ</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
91 <li>ファイルの型認識</li>
14
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
92 </ul>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
93 </li>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
94 </ul>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
95
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
96
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
97
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
98 </div>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
99
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
100 <div class='slide'>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
101 <!-- _S9SLIDE_ -->
22
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
102 <h2 id="gearsosのgear概念12">GearsOSのGear概念(1/2)</h2>
14
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
103 <ul>
22
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
104 <li>関数でなくGearという単位を用いて記述する</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
105 <li>Gearは関数と異なり、スタックを持たないため軽量継続と呼ぶ</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
106 <li>CodeGear
14
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
107 <ul>
22
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
108 <li>従来のThreadにあたる</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
109 <li>goto文(jump命令)を使って遷移する</li>
14
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
110 </ul>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
111 </li>
22
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
112 <li>DataGear
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
113 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
114 <li>従来の変数データにあたる</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
115 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
116 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
117 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
118
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
119
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
120
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
121 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
122
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
123 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
124 <!-- _S9SLIDE_ -->
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
125 <h2 id="gearsosのgear概念22">GearsOSのGear概念(2/2)</h2>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
126 <ul>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
127 <li>CodeGearは処理を行う際、DataGearを参照し処理を行う(InputDataGear)</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
128 <li>CodeGearは処理の終了後、以降に必要なデータをDataGearとして出力する(OutputDataGear)</li>
14
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
129 </ul>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
130 <div style="text-align: center;">
22
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
131  <img src="images/cg-dg.pdf" alt="cgdgの関係図" width="600" />
14
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
132 </div>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
133
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
134
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
135
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
136 </div>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
137
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
138 <div class='slide'>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
139 <!-- _S9SLIDE_ -->
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
140 <h2 id="gearsosのinterface">GearsOSのInterface</h2>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
141 <ul>
22
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
142 <li>Object型指向の仕組み</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
143 <li>APIとなるCodeGearとその参照するDataGearを宣言する</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
144 <li>DataGear/CodeGearの一時的な置き場としての役割を持つ
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
145 <pre><code>typedef struct Tree&lt;&gt;{
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
146 union Data* tree;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
147 struct Node* node;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
148 __code put(Impl* tree,Type* node, __code next(...));
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
149 __code get(Impl* tree, Type* node, __code next(...));
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
150 __code remove(Impl* tree,Type* node, __code next(...));
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
151 __code next(...);
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
152 } Tree;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
153 </code></pre>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
154 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
155 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
156
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
157
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
158
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
159 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
160
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
161 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
162 <!-- _S9SLIDE_ -->
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
163 <h2 id="メタレベルのgear13">メタレベルのGear(1/3)</h2>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
164 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
165 <li>CodeGearとDataGearにはユーザーが記述しない、メタレベルのものが存在する
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
166 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
167 <li>メタレベルな記述はトランスコンパイラにより自動生成される</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
168 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
169 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
170 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
171 <div style="text-align: center;">
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
172  <img src="images/meta-cg-dg.pdf" alt="ノーマルレベルとメタレベルの視点からのGearの関係" width="800" />
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
173 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
174
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
175
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
176
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
177 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
178
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
179 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
180 <!-- _S9SLIDE_ -->
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
181 <h2 id="メタレベルのgear23">メタレベルのGear(2/3)</h2>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
182 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
183 <li>MetaCodeGear
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
184 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
185 <li>CodeGearの処理前と処理後に参照される</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
186 <li>Input/OutputDataGearを引き渡す</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
187 <li>CodeGear処理前に呼ばれるものを特にstubCodeGearと呼ぶ</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
188 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
189 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
190 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
191 <div style="text-align: center;">
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
192  <img src="images/meta-cg-dg.pdf" alt="ノーマルレベルとメタレベルの視点からのGearの関係" width="800" />
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
193 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
194
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
195
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
196
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
197 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
198
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
199 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
200 <!-- _S9SLIDE_ -->
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
201 <h2 id="メタレベルのgear33">メタレベルのGear(3/3)</h2>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
202 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
203 <li>MetaDataGear
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
204 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
205 <li>MetaCodeGearにて参照されるDataGear</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
206 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
207 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
208 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
209 <div style="text-align: center;">
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
210  <img src="images/meta-cg-dg.pdf" alt="ノーマルレベルとメタレベルの視点からのGearの関係" width="800" />
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
211 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
212
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
213
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
214
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
215 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
216
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
217 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
218 <!-- _S9SLIDE_ -->
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
219 <h2 id="gearsosのファイルシステムの設計">GearsOSのファイルシステムの設計</h2>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
220 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
221 <li>DataGearの単位でデータを操作したい</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
222 <li>通信データに対応した複数のストリームを持ちたい</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
223 <li>Transaction(マクロレベル)で操作したい
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
224 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
225 <li>従来のファイルシステムは一部の操作のみTransactionである</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
226 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
227 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
228 <li>ファイルそのものが通信を担当する
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
229 <ul>
22
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
230 <li>ChristieのDataGearManagerを参考にする</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
231 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
232 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
233 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
234
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
235
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
236
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
237 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
238
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
239 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
240 <!-- _S9SLIDE_ -->
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
241 <h2 id="gearsosのファイルデータ操作13">GearsOSのファイルデータ操作(1/3)</h2>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
242 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
243 <li>GearsOSはDataGearのやりとりでプログラムが構成される
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
244 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
245 <li>ファイルシステムも同様の実装にしたい = DataGear単位で操作したい</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
246 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
247 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
248 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
249 <div style="text-align: center;">
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
250  <img src="images/QueueElement.pdf" alt="Queueの構造" width="800" />
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
251 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
252
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
253
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
254
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
255 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
256
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
257 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
258 <!-- _S9SLIDE_ -->
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
259 <h2 id="gearsosのファイルデータ操作23">GearsOSのファイルデータ操作(2/3)</h2>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
260 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
261 <li>GearsOSのファイルデータは任意の型を持った構造体で実装される(ファイルレコード)</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
262 <li>レコードは決められた順番で連続しており、Queueに保存される</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
263 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
264 <div style="text-align: center;">
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
265  <img src="images/QueueElement.pdf" alt="Queueの構造" width="800" />
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
266 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
267
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
268
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
269
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
270 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
271
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
272 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
273 <!-- _S9SLIDE_ -->
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
274 <h2 id="gearsosのファイルデータ操作33">GearsOSのファイルデータ操作(3/3)</h2>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
275 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
276 <li>構造体の型を判別することで処理の切り替えが行える</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
277 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
278 <div style="text-align: center;">
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
279  <img src="images/QueueElement.pdf" alt="Queueの構造" width="800" />
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
280 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
281
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
282
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
283
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
284 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
285
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
286 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
287 <!-- _S9SLIDE_ -->
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
288 <h2 id="gearsfsのトランザクション">GearsFSのトランザクション</h2>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
289 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
290 <li>GearsOSのDataGear操作はマクロな操作である
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
291 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
292 <li>よってCodeGearはTransactionである</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
293 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
294 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
295 <li>ファイルシステム操作もCodeGearで記述されるためTransactionとなる</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
296 <li>トランザクションな操作によってファイルシステムの整合性の保守が行いやすい</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
297 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
298
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
299
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
300
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
301 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
302
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
303 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
304 <!-- _S9SLIDE_ -->
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
305 <h2 id="queueによるgearsosのファイル">QueueによるGearsOSのファイル</h2>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
306 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
307 <li>GearsOSのファイルはファイルレコードを保持するQueueとなる</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
308 <li>デバイスへの保存はQueueを保存すればよい</li>
23
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
309 <li>ファイルはQueueなのでファイルのAPIは大きく二つとなる
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
310 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
311 <li>Put</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
312 <li>Take</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
313 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
314 </li>
22
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
315 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
316
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
317
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
318
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
319 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
320
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
321 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
322 <!-- _S9SLIDE_ -->
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
323 <h2 id="queueapi--put-">QueueAPI -Put-</h2>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
324 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
325 <li>Put
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
326 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
327 <li>Queueに対してファイルレコードを入力する</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
328 <li>ファイルの変更をレコードとして書き込む
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
329 <pre><code>__code putSingleLinkedQueue(struct SingleLinkedQueue* queue, union Data* data, __code next(...)) {
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
330 Element* element = new Element();
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
331 element-&gt;data = data;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
332 element-&gt;next = NULL;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
333 queue-&gt;last-&gt;next = element;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
334 queue-&gt;last = element;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
335 goto next(...);
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
336 }
14
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
337 </code></pre>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
338 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
339 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
340 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
341 </ul>
14
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
342
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
343
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
344
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
345 </div>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
346
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
347 <div class='slide'>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
348 <!-- _S9SLIDE_ -->
22
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
349 <h2 id="queueapi--take-">QueueAPI -Take-</h2>
16
ed9bace4039e add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 14
diff changeset
350 <ul>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
351 <li>Take
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
352 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
353 <li>Queueからファイルレコードを取り出す</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
354 <li>Queue内のレコードをループで全て取り出せば良い
22
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
355 <pre><code>__code takeSingleLinkedQueue(struct SingleLinkedQueue* queue, __code next(union Data* data, ...)) {
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
356 printf("take\n");
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
357 struct Element* top = queue-&gt;top;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
358 struct Element* nextElement = top-&gt;next;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
359 if (queue-&gt;top == queue-&gt;last) {
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
360 data = NULL;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
361 } else {
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
362 queue-&gt;top = nextElement;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
363 data = nextElement-&gt;data;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
364 }
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
365 goto next(data, ...);
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
366 }
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
367 </code></pre>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
368 </li>
19
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
369 </ul>
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
370 </li>
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
371 </ul>
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
372
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
373
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
374
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
375 </div>
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
376
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
377 <div class='slide'>
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
378 <!-- _S9SLIDE_ -->
23
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
379 <h2 id="複数のストリームから構成されるファイル">複数のストリームから構成されるファイル</h2>
17
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
380 <ul>
23
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
381 <li>入力されるデータに応じた個別のstreamを備えたい
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
382 <ul>
23
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
383 <li>streamと入力されたデータの処理を直接結びつけたい</li>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
384 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
385 </li>
23
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
386 <li>最低でもInput/OutputStreamの二つが必要となる</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
387 <li>ファイルは複数のStreamを持ったリストとして実装する</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
388 <li>Streamはkey nameを持ち、keyでアクセスを行う</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
389 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
390
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
391
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
392
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
393 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
394
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
395 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
396 <!-- _S9SLIDE_ -->
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
397 <h2 id="ファイル通信の構成">ファイル通信の構成</h2>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
398 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
399 <li>GearsOSのファイルは大域的に解放された資源としたい
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
400 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
401 <li>ファイル自信を通信そのものとして実装する</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
402 <li>Streamに対しsocket接続により遠隔にアクセスする</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
403 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
404 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
405 <li>分散フレームワークChristieのDataGearManagerの仕組みを利用する</li>
17
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
406 </ul>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
407
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
408
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
409
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
410 </div>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
411
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
412 <div class='slide'>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
413 <!-- _S9SLIDE_ -->
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
414 <h2 id="datagearmanager">DataGearManager</h2>
17
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
415 <ul>
23
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
416 <li>分散フレームワークChristieの仕組みの一つ</li>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
417 <li>keyとvalueの組み合わせとなるDataGearを保持するデータプール</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
418 <li>ChristieではCodeGearManagerと呼ばれるノードがCodeGearとDataGearを管理する</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
419 <li>LocalDGMはノード本体に対応するデータプールである
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
420 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
421 <li>CodeGearはLocalDGMに対してDataGearを参照する</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
422 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
423 </li>
22
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
424 <li>RemoteDGMは接続する相手ノードに対応するデータプールproxyである
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
425 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
426 <li>RemoteDGMに対してDataGearを書き込むことで、対応するノードのLocalDGMにデータが書き込まれる</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
427 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
428 </li>
17
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
429 </ul>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
430
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
431
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
432
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
433 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
434
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
435 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
436 <!-- _S9SLIDE_ -->
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
437 <h2 id="datagearmanager-1">DataGearManager</h2>
23
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
438 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
439 <li>任意の相手のRemoteDGMを作成することでTopologyが形成される</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
440 </ul>
19
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
441 <div style="text-align: center;">
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
442  <img src="images/Remote_DataGearManager.pdf" alt="RemoteDGMの関係図" width="800" />
19
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
443 </div>
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
444
17
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
445
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
446
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
447 </div>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
448
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
449 <div class='slide'>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
450 <!-- _S9SLIDE_ -->
23
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
451 <h2 id="gearsos上のsocket通信">GearsOS上のsocket通信</h2>
19
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
452 <ul>
23
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
453 <li>GearsOS上のsocket通信を検証したい</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
454 <li>Queueをsocketに接続し、簡易的なAPIの記述をした
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
455 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
456 <li>Localなqueueに対してRemoteのqueueがソケット接続を行う</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
457 <li>socketはQueueの生成時に接続される
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
458 <pre><code>typedef struct CQueue&lt;&gt;{
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
459 union Data* cQueue;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
460 union Data* data;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
461
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
462 __code whenEmpty(...);
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
463 __code whenEOF(...);
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
464 __code clear(Impl* cQueue, __code next(...));
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
465 __code put(Impl* cQueue, union Data* data, __code next(...));
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
466 __code take(Impl* cQueue, __code next(union Data* data, ...));
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
467 __code isEmpty(Impl* cQueue, __code next(...), __code whenEmpty(...));
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
468 __code getData(Impl* cQueue, __code next(...), __code whenEOF(...));
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
469 __code next(...);
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
470 } CQueue;
19
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
471 </code></pre>
23
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
472 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
473 </ul>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
474 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
475 </ul>
19
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
476
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
477
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
478
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
479 </div>
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
480
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
481 <div class='slide'>
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
482 <!-- _S9SLIDE_ -->
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
483 <h2 id="remotequeue側からの送信">RemoteQueue側からの送信</h2>
19
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
484 <ul>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
485 <li>QueueのPutAPIの後に遷移される</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
486 <li>putしたデータをsocketを通じて送信する</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
487 <li>将来的にsendではなくwriteを用いる
19
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
488 <pre><code>__code sendDataRemoteDGMQueue(struct RemoteDGMQueue* cQueue, union Data* data, __code next(...), __code whenError(...)){
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
489 char recv_buf;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
490 int send_size, recv_size;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
491
19
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
492 send_size = send(cQueue-&gt;socket, data, sizeof(union Data), 0);
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
493 recv_size = recv(cQueue-&gt;socket, &amp;recv_buf, 1, 0);
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
494 //error処理は省略
19
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
495 goto next(...);
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
496 }
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
497 </code></pre>
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
498 </li>
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
499 </ul>
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
500
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
501
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
502
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
503 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
504
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
505 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
506 <!-- _S9SLIDE_ -->
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
507 <h2 id="localqueue側の受信">LocalQueue側の受信</h2>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
508 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
509 <li>APIとしてsocketのデータを取り出す</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
510 <li>取り出されたデータはQueueにputされる</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
511 <li>union Data型でデータを受け取りmain側で処理を行う</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
512 <li>取り出されたデータはmain側で処理される</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
513 <li>将来的にrecvでなくreadを用いる
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
514 <pre><code>__code getDataLocalDGMQueue(struct LocalDGMQueue* cQueue, __code next(...), __code whenError(...)){
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
515 int recv_size, send_size;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
516 char send_buf;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
517
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
518 union Data* recv_data;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
519 recv_size = recv(cQueue-&gt;socket, recv_data, sizeof(union Data), 0);
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
520
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
521 //error処理は省略
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
522 Gearef(context, cQueue)-&gt;data = recv_data;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
523 goto putLocalDGMQueue(recv_data, next);
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
524 }
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
525 </code></pre>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
526 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
527 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
528
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
529
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
530
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
531 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
532
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
533 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
534 <!-- _S9SLIDE_ -->
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
535 <h2 id="ファイル単位のsocket通信">ファイル単位のsocket通信</h2>
17
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
536 <ul>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
537 <li>実際のファイルは複数のQueueを持つ一つのリストである</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
538 <li>Queue単体でなく、リスト(ファイル)単位でsocketを持つ必要がある</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
539 <li>リストは赤黒木となる</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
540 <li>DataGearをputするkeyを指定して書き込みを行う
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
541 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
542 <li>Localなファイルの同一のQueueに対して書き込みが行われる</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
543 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
544 </li>
17
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
545 </ul>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
546 <div style="text-align: center;">
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
547  <img src="images/socketCom.pdf" alt="socketを通じたレコード送信" width="800" />
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
548 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
549
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
550
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
551
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
552 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
553
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
554 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
555 <!-- _S9SLIDE_ -->
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
556 <h2 id="main部分によるapi">main部分によるAPI</h2>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
557 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
558 <li>readの場合(リモート側に読み込みたいファイルが存在する)
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
559 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
560 <li>(手順1)ローカル側は空のファイルを作成し、socketを持たせる</li>
22
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
561 <li>(手順2)リモート側は, ローカル側の持つ空ファイルのproxyを作成する</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
562 <li>(手順3)リモート側はproxyに対して、目的のファイルのデータをputする</li>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
563 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
564 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
565 <li>writeの場合(リモート側に書き込みたいファイルが存在する)
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
566 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
567 <li>(手順1)リモート側は対象ファイルにsocketを持たせる</li>
22
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
568 <li>(手順2)ローカル側は対象のファイルに対応するproxyを作成する</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
569 <li>(手順3)ローカル側はproxyのkeyに対してデータをputする</li>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
570 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
571 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
572 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
573
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
574
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
575
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
576 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
577
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
578 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
579 <!-- _S9SLIDE_ -->
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
580 <h2 id="wordcountの例題">wordCountの例題</h2>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
581 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
582 <li>DataGearManagerによるファイル通信APIはWordCount例題を目指して設計した
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
583 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
584 <li>ファイル内の文字列を1行づつ受け取り、文字列,行数をカウントする例題</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
585 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
586 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
587 <li>文字列送信側とCount側を別ノード上で行うことで、ファイルの呼び出しと通信処理が構成できる</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
588 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
589 <div style="text-align: center;">
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
590  <img src="images/wordCountDGM.pdf" alt="リモートDGMによるWordCount" width="800" />
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
591 </div>
17
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
592
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
593
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
594
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
595 </div>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
596
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
597 <div class='slide'>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
598 <!-- _S9SLIDE_ -->
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
599 <h2 id="christieapiによるwordcount">ChristieAPIによるWordCount</h2>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
600 <ul>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
601 <li>FileOpen側とWordCount側でノードが別れる</li>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
602 <li>(手順1)FileOpen側はRDGMに文字列をputする</li>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
603 <li>(手順2)WordCount側は処理の後、ackを返信する</li>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
604 <li>(手順3)1,2をループし、FileOpen側はEoFならフラグを送信する</li>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
605 <li>(手順4)EoFを受信したWordCountは結果を返信し、双方の処理を終了させる</li>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
606 </ul>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
607 <div style="text-align: center;">
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
608  <img src="images/wordCountDGM.pdf" alt="ChristieAPIによるWordCount" width="800" />
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
609 </div>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
610
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
611
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
612
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
613 </div>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
614
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
615 <div class='slide'>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
616 <!-- _S9SLIDE_ -->
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
617 <h2 id="これから実装が必要となる機能">これから実装が必要となる機能</h2>
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
618 <ul>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
619 <li>keyアクセスに対応したファイル通信
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
620 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
621 <li>単一のQueueによる通信は確認が行えた</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
622 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
623 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
624 <li>ファイル保存</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
625 <li>バックアップ機能</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
626 <li>並列処理</li>
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
627 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
628
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
629
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
630
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
631 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
632
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
633 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
634 <!-- _S9SLIDE_ -->
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
635 <h2 id="gearsosのディレクトリとバックアップ">GearsOSのディレクトリとバックアップ</h2>
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
636 <ul>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
637 <li>又吉雄斗による並行研究にて、inodeによるファイルシステムが開発されている</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
638 <li>赤黒木の非破壊な編集により、ディレクトリの履歴を残すことができる</li>
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
639 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
640 <div style="text-align: center;">
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
641  <img src="images/nonDestroyTreeEdit.pdf" alt="非破壊的なツリー編集" width="800" />
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
642 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
643
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
644
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
645
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
646 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
647
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
648 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
649 <!-- _S9SLIDE_ -->
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
650 <h2 id="生成形の問題点">生成形の問題点</h2>
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
651 <ul>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
652 <li>GearsOSのメタレベルの処理の記述はトランスコンパイラにより行われる</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
653 <li>場合によりメタレベルの記述を行わなくてはならない
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
654 <ul>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
655 <li>他のInterfaceを継承したオブジェクトからのDataGear継承
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
656 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
657 <li>例)Queueからのデータ取り出し</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
658 <li>トランスコンパイラはどのInterfaceが持つDataGearを参照するべきか判断が難しい</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
659 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
660 </li>
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
661 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
662 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
663 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
664
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
665 <pre><code>__code Task2(TQueue* localDGMQueue){
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
666 goto localDGMQueue-&gt;take(Task3);
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
667 }
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
668
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
669 __code Task3(TQueue* localDGMQueue, FileString* string){
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
670 printf("take[%s] [num:%d]\n", string-&gt;str, string-&gt;size);
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
671 goto getData();
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
672 }
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
673
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
674 //プログラマが実装したいstub
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
675 __code Task3_stub(struct Context* context){
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
676 TQueue* localDGMQueue = (struct TQueue*)Gearef(context, TQueue)-&gt;tQueue;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
677 FileString* string = Gearef(context, TQueue)-&gt;data;
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
678 goto Task3(context, localDGMQueue, string);
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
679 }
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
680
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
681 //自動生成されたErrorなstub
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
682 __code Task3_stub(struct Context* context) {
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
683 TQueue* localDGMQueue = Gearef(context, TQueue);
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
684 FileString* string = Gearef(context, FileString);
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
685 goto Task3(context, localDGMQueue, string);
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
686 }
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
687 </code></pre>
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
688
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
689
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
690
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
691 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
692
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
693 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
694 <!-- _S9SLIDE_ -->
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
695 <h2 id="並列処理構文par-gotoが持つ問題">並列処理構文par gotoが持つ問題</h2>
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
696 <ul>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
697 <li>par gotoとはGearsOSに実装された並列処理構文である</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
698 <li>par gotoはトランスコンパイラへの依存性が高い
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
699 <ul>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
700 <li>stubCodeGearのように任意な書き換えが行えない</li>
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
701 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
702 </li>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
703 <li>StreamQueueに対するput/takeの並列処理の実装をpar goto構文で試みた</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
704 <li>特定のCodeGearの宣言のみでしか正常な処理が生成されない
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
705 <ul>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
706 <li>Interfaceに記述されたAPICodeGearではバグが生じる</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
707 <li>par gotoでの使用を前提としたCodeGearを書かなくてはならない</li>
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
708 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
709 </li>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
710 <li>処理が重いという問題点も存在する</li>
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
711 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
712
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
713
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
714
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
715 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
716
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
717 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
718 <!-- _S9SLIDE_ -->
19
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
719 <h2 id="結論">結論</h2>
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
720 <ul>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
721 <li>GearsOSのファイルの設計を行った
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
722 <ul>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
723 <li>ファイルの構造の設計</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
724 <li>socketによる通信部分の実装</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
725 <li>単純化した通信APIの記述</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
726 <li>GearsOSの調査</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
727 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
728 </li>
22
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 20
diff changeset
729 <li>ファイルproxyによる通信実現を行いたい</li>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
730 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
731
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
732
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
733
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
734 </div>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
735
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
736 <div class='slide'>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
737 <!-- _S9SLIDE_ -->
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
738 <h2 id="これからの課題">これからの課題</h2>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
739 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
740 <li>TopoplogyManagerの設計
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
741 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
742 <li>参加したノードを任意の形のTopologyに接続する機能</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
743 <li>ファイルシステム向けの機能を追加したい
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
744 <ul>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
745 <li>DNS</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
746 <li>中枢としてのTopologyのノード監視</li>
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
747 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
748 </li>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
749 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
750 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
751 <li>Securityシステムの追加
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
752 <ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
753 <li>証明書などによるファイル操作制限</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
754 <li>不正な分散ファイルシステムへのアクセス</li>
18
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
755 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
756 </li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
757 </ul>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
758
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 17
diff changeset
759
17
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
760
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
761 </div>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
762
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
763 <div class='slide'>
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
764 <!-- _S9SLIDE_ -->
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
765 <h2 id="この先保留">この先保留</h2>
14
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
766
19
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
767
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
768
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
769 </div>
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
770
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
771 <div class='slide'>
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
772 <!-- _S9SLIDE_ -->
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
773 <h2 id="ファイルqueueに対するapi--peek-">ファイルQueueに対するAPI -Peek-</h2>
17
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
774 <ul>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
775 <li>Peek
19
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
776 <ul>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
777 <li>QueueのElementを参照するが、削除は行わない</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
778 <li>現時点での実装は行っていない</li>
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
779 <li>QueueのTopのレコードを変更せずに出力すれば良い
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
780 &lt;!–</li>
19
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
781 </ul>
9e6fd2255ee1 tweak slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 18
diff changeset
782 </li>
20
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
783 <li>RocalDGMを立ち上げるにはDataSegmentクラスが提供する、connectメソッドを用い、接続したいポートのipアドレスとport番号、そして任意のManager名を指定することで立ち上げる。
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 19
diff changeset
784 –&gt;</li>
17
f4a719e93ded Too long
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents: 16
diff changeset
785 </ul>
14
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
786
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
787 </div>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
788
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
789
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
790 </div><!-- presentation -->
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
791 </body>
0a4cafd954b9 add slide
ichikitakahiro <e165713@ie.u-ryukyu.ac.jp>
parents:
diff changeset
792 </html>