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
840
fukuoka.rb#202 RustでつくるRuby
monochrome
March 24, 2021
Tweet
Share
More Decks by monochrome
See All by monochrome
Improving my own Ruby thereafter
sisshiki1969
1
200
あなたとJIT, 今すぐアセンブ ル
sisshiki1969
1
910
Improve my own Ruby
sisshiki1969
1
420
My own Ruby, thereafter
sisshiki1969
0
360
Running Optcarrot (faster) on my own Ruby.
sisshiki1969
1
260
仮想マシンにおけるスタックの管理
sisshiki1969
0
220
Rustでゴミ集め
sisshiki1969
1
340
RustでつくるRubyのFiber
sisshiki1969
0
300
Shinjuku.rs#15 Rustでつくるx86アセンブラ
sisshiki1969
0
1.7k
Other Decks in Programming
See All in Programming
從冷知識到漏洞,你不懂的 Web,駭客懂 - Huli @ WebConf Taiwan 2025
aszx87410
2
3.2k
「コードは上から下へ読むのが一番」と思った時に、思い出してほしい話
panda728
PRO
39
26k
Claude Codeの「Compacting Conversation」を体感50%減! CLAUDE.md + 8 Skills で挑むコンテキスト管理術
kmurahama
1
680
これならできる!個人開発のすゝめ
tinykitten
PRO
0
140
LLM Çağında Backend Olmak: 10 Milyon Prompt'u Milisaniyede Sorgulamak
selcukusta
0
140
AIエージェントの設計で注意するべきポイント6選
har1101
6
2.8k
Patterns of Patterns
denyspoltorak
0
400
AI時代を生き抜く 新卒エンジニアの生きる道
coconala_engineer
1
480
Navigating Dependency Injection with Metro
l2hyunwoo
1
200
GISエンジニアから見たLINKSデータ
nokonoko1203
0
190
ゲームの物理 剛体編
fadis
0
390
AI前提で考えるiOSアプリのモダナイズ設計
yuukiw00w
0
210
Featured
See All Featured
The State of eCommerce SEO: How to Win in Today's Products SERPs - #SEOweek
aleyda
2
9.2k
Collaborative Software Design: How to facilitate domain modelling decisions
baasie
0
110
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
234
17k
Visual Storytelling: How to be a Superhuman Communicator
reverentgeek
2
400
How to Think Like a Performance Engineer
csswizardry
28
2.4k
Bioeconomy Workshop: Dr. Julius Ecuru, Opportunities for a Bioeconomy in West Africa
akademiya2063
PRO
0
34
Leading Effective Engineering Teams in the AI Era
addyosmani
9
1.4k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
47
7.9k
Getting science done with accelerated Python computing platforms
jacobtomlinson
0
84
Lessons Learnt from Crawling 1000+ Websites
charlesmeaden
PRO
0
980
SEOcharity - Dark patterns in SEO and UX: How to avoid them and build a more ethical web
sarafernandez
0
96
Ethics towards AI in product and experience design
skipperchong
1
150
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/