Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
fukuoka.rb#202 RustでつくるRuby
Search
monochrome
March 24, 2021
Programming
1
800
fukuoka.rb#202 RustでつくるRuby
monochrome
March 24, 2021
Tweet
Share
More Decks by monochrome
See All by monochrome
Improve my own Ruby
sisshiki1969
1
260
My own Ruby, thereafter
sisshiki1969
0
310
Running Optcarrot (faster) on my own Ruby.
sisshiki1969
1
210
仮想マシンにおけるスタックの管理
sisshiki1969
0
200
Rustでゴミ集め
sisshiki1969
1
320
RustでつくるRubyのFiber
sisshiki1969
0
270
Shinjuku.rs#15 Rustでつくるx86アセンブラ
sisshiki1969
0
1.6k
RustでつくるRubyのFiber
sisshiki1969
0
490
Rustでつくるガーベジコレクタ
sisshiki1969
0
690
Other Decks in Programming
See All in Programming
レガシーシステムの機能調査・開発におけるAI利活用
takuya_ohtonari
0
590
カクヨムAndroidアプリのリブート
numeroanddev
0
410
AIエージェントによるテストフレームワーク Arbigent
takahirom
0
370
SODA - FACT BOOK
sodainc
1
860
データベースコネクションプール(DBCP)の変遷と理解
fujikawa8
1
250
GoのWebAssembly活用パターン紹介
syumai
3
10k
PT AI без купюр
v0lka
0
230
Development of an App for Intuitive AI Learning - Blockly Summit 2025
teba_eleven
0
110
TypeScript LSP の今までとこれから
quramy
1
500
XSLTで作るBrainfuck処理系
makki_d
0
190
iOSアプリ開発で 関数型プログラミングを実現する The Composable Architectureの紹介
yimajo
2
210
統一感のある Go コードを生成 AI の力で手にいれる
otakakot
0
3k
Featured
See All Featured
Producing Creativity
orderedlist
PRO
346
40k
Optimizing for Happiness
mojombo
379
70k
Facilitating Awesome Meetings
lara
54
6.4k
Speed Design
sergeychernyshev
31
990
Scaling GitHub
holman
459
140k
Evolution of real-time – Irina Nazarova, EuRuKo, 2024
irinanazarova
8
780
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
107
19k
Balancing Empowerment & Direction
lara
1
290
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
PRO
181
53k
The Cost Of JavaScript in 2023
addyosmani
50
8.3k
Visualization
eitanlees
146
16k
Fashionably flexible responsive web design (full day workshop)
malarkey
407
66k
Transcript
RustでつくるRuby処理系 monochrome twitter: @s_isshiki1969 GitHub: https://github.com/sisshiki1969 Slack: プログラミング言語処理系が好きな人の集まり https://prog-lang-sys-ja-slack.github.io/wiki/
ruruby (https://github.com/sisshiki1969/ruruby) • Rust製のRuby実装 • 仮想マシンインタプリタ • 他の既存実装・仮想マシンへの依存なし • 3万行ぐらい
モチベーション 1. Rustの勉強がしたい 2. 何か言語処理系を作りたい 3. Ruby面白そう
benchmark
開発のモチベーションをいかに維持するか 1. おもちゃじゃないプログラムを動かしたい 2. 「正しく動いている」ことがわかるもの 3. 実行速度を測定できるもの 4. 極力外部ライブラリに依存しないもの
Optcarrot • Rubyで書かれたファミコンのエミュレータ • 「Ruby3x3」のための準公式ベンチマーク • ベンチマーク用の速度測定モードがある • 生成した画像の正しさをチェックサムで検証できる •
(ベンチマークモードでは)外部ライブラリを使用しない
optcarrot benchmark
None
技術的に難しかった点 • ガベージコレクタ →自作した。 • Fiber →アセンブリで実装 (x86-64/linux, aarch64/MacOS)
言語処理系自作は • モチベーションを維持する工夫が大切 • 対象言語の実行モデルの勉強になる • 楽しいので、みんなで作ろう Slack: プログラミング言語処理系が好きな人の集まり https://prog-lang-sys-ja-slack.github.io/wiki/