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
770
fukuoka.rb#202 RustでつくるRuby
monochrome
March 24, 2021
Tweet
Share
More Decks by monochrome
See All by monochrome
My own Ruby, thereafter
sisshiki1969
0
270
Running Optcarrot (faster) on my own Ruby.
sisshiki1969
1
170
仮想マシンにおけるスタックの管理
sisshiki1969
0
180
Rustでゴミ集め
sisshiki1969
1
300
RustでつくるRubyのFiber
sisshiki1969
0
250
Shinjuku.rs#15 Rustでつくるx86アセンブラ
sisshiki1969
0
1.6k
RustでつくるRubyのFiber
sisshiki1969
0
460
Rustでつくるガーベジコレクタ
sisshiki1969
0
640
Other Decks in Programming
See All in Programming
Kubernetes History Inspector(KHI)を触ってみた
bells17
0
230
ファインディLT_ポケモン対戦の定量的分析
fufufukakaka
0
740
GAEログのコスト削減
mot_techtalk
0
120
2024年のWebフロントエンドのふりかえりと2025年
sakito
3
250
Honoのおもしろいミドルウェアをみてみよう
yusukebe
1
210
なぜイベント駆動が必要なのか - CQRS/ESで解く複雑系システムの課題 -
j5ik2o
12
4.1k
Amazon ECS とマイクロサービスから考えるシステム構成
hiyanger
2
570
プログラミング言語学習のススメ / why-do-i-learn-programming-language
yashi8484
0
130
AIの力でお手軽Chrome拡張機能作り
taiseiue
0
170
Unity Android XR入門
sakutama_11
0
160
pylint custom ruleで始めるレビュー自動化
shogoujiie
0
120
『品質』という言葉が嫌いな理由
korimu
0
160
Featured
See All Featured
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
49
2.3k
Java REST API Framework Comparison - PWX 2021
mraible
28
8.4k
The Myth of the Modular Monolith - Day 2 Keynote - Rails World 2024
eileencodes
21
2.5k
A Modern Web Designer's Workflow
chriscoyier
693
190k
It's Worth the Effort
3n
184
28k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
133
33k
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
29
1k
Intergalactic Javascript Robots from Outer Space
tanoku
270
27k
Side Projects
sachag
452
42k
Building a Scalable Design System with Sketch
lauravandoore
461
33k
The Power of CSS Pseudo Elements
geoffreycrofte
75
5.5k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
40
2k
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/