annotate codedb.ind @ 7:319a58e580e4

...
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Mon, 17 Apr 2023 18:29:04 +0900
parents 977222ed78ab
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
1 -title: Gears OS の Code Database
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
2
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
3 --従来のOS
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
4
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
5 a.out にいろいろ入ってる
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
6
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
7 shared library
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
8
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
9 同じものがそこら中に
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
10
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
11 関数は実行前に linker が接続する
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
12
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
13 --Smalltalk / Lisp machine
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
14
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
15 byte code method が meory 上にある
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
16
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
17 同じものが重複しても良い
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
18
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
19 oblist に名前と関数の対応が入ってる
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
20
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
21 --code Gear
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
22
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
23 context から番号で参照される
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
24
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
25 引数は context から stub 経由で取り込まれる
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
26
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
27 --code gear database
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
28
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
29 番号で参照される codeGear を入れる database
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
30
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
31 --code set
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
32
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
33 context に入れて動かす code Gear を決める
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
34
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
35 実行時に変更されるかも知れない
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
36
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
37 番号と関数のアドレスの対応を用意する必要がある
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
38
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
39 これが a.out に対応する
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
40
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
41 対応表は構造をもっていても良い
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
42
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
43 --Linker / Loader が不要
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
44
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
45 かなり簡単になる
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
46
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
47 context の表を設定するものを書けば良い -- もちろん codeGear / dataGear
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
48
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
49 --現在の Gears OS
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
50
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
51 context の表はコンパイル時に構成されて最適化されている
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
52
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
53 実行時に構築すると最適化されない
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
54
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
55 JIT変換する方が望ましい
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
56
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
57 context の実行時再構成が必要になる
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
58
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
59 --code gear databas の検索
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
60
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
61 どうやって検索する?
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
62
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
63 interface name は ad-hoc
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
64
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
65 中身で検索する? code 自体と型自体
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
66
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
67 code 自体の記述は?
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
68
977222ed78ab first commit
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
69 とりあえずは ad-hoc でよいが...