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
820
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
320
My own Ruby, thereafter
sisshiki1969
0
320
Running Optcarrot (faster) on my own Ruby.
sisshiki1969
1
220
仮想マシンにおけるスタックの管理
sisshiki1969
0
200
Rustでゴミ集め
sisshiki1969
1
330
RustでつくるRubyのFiber
sisshiki1969
0
280
Shinjuku.rs#15 Rustでつくるx86アセンブラ
sisshiki1969
0
1.6k
RustでつくるRubyのFiber
sisshiki1969
0
500
Rustでつくるガーベジコレクタ
sisshiki1969
0
710
Other Decks in Programming
See All in Programming
バイブコーディング超えてバイブデプロイ〜CloudflareMCPで実現する、未来のアプリケーションデリバリー〜
azukiazusa1
3
780
Claude Code派?Gemini CLI派? みんなで比較LT会!_20250716
junholee
1
800
Understanding Kotlin Multiplatform
l2hyunwoo
0
250
AWS Summit Japan 2024と2025の比較/はじめてのKiro、今あなたは岐路に立つ
satoshi256kbyte
1
260
iOS開発スターターキットの作り方
akidon0000
0
230
LLMは麻雀を知らなすぎるから俺が教育してやる
po3rin
3
1.9k
MCP連携で加速するAI駆動開発/mcp integration accelerates ai-driven-development
bpstudy
0
250
変化を楽しむエンジニアリング ~ いままでとこれから ~
murajun1978
0
660
Comparing decimals in Swift Testing
417_72ki
0
160
QA x AIエコシステム段階構築作戦
osu
0
240
可変性を制する設計: 構造と振る舞いから考える概念モデリングとその実装
a_suenami
10
1.5k
DataformでPythonする / dataform-de-python
snhryt
0
150
Featured
See All Featured
Building a Modern Day E-commerce SEO Strategy
aleyda
43
7.4k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
139
34k
A better future with KSS
kneath
238
17k
How to Think Like a Performance Engineer
csswizardry
25
1.8k
Designing for Performance
lara
610
69k
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
Documentation Writing (for coders)
carmenintech
73
5k
The Pragmatic Product Professional
lauravandoore
36
6.8k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
130
19k
Large-scale JavaScript Application Architecture
addyosmani
512
110k
Agile that works and the tools we love
rasmusluckow
329
21k
Testing 201, or: Great Expectations
jmmastey
45
7.6k
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/