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
AkarengaLT vol.38
Search
hashimoto-kei
October 19, 2025
Programming
1
140
AkarengaLT vol.38
AkarengaLT vol.38 に登壇した際の資料です。
https://engineercafe.connpass.com/event/370316/
hashimoto-kei
October 19, 2025
Tweet
Share
More Decks by hashimoto-kei
See All by hashimoto-kei
AkarengaLT vol.37
hashimoto_kei
0
69
AkarengaLT vol.36
hashimoto_kei
0
66
AkarengaLT vol.35
hashimoto_kei
0
170
Boast Code Party | RubyKaigi 2025 After Event
hashimoto_kei
2
270
Other Decks in Programming
See All in Programming
Blazing Fast UI Development with Compose Hot Reload (droidcon London 2025)
zsmb
0
480
Eloquentを使ってどこまでコードの治安を保てるのか?を新人が考察してみた
itokoh0405
0
3.1k
AI時代に必須!状況言語化スキル / ai-context-verbalization
minodriven
2
350
Making Angular Apps Smarter with Generative AI: Local and Offline-capable
christianliebel
PRO
0
110
Tangible Code
chobishiba
2
460
Amazon Bedrock Knowledge Bases Hands-on
konny0311
0
120
フロントエンド開発のためのブラウザ組み込みAI入門
masashi
7
3.7k
Vue 3.6 時代のリアクティビティ最前線 〜Vapor/alien-signals の実践とパフォーマンス最適化〜
hiranuma
2
400
iOSでSVG画像を扱う
kishikawakatsumi
0
180
実践Claude Code:20の失敗から学ぶAIペアプログラミング
takedatakashi
18
9.7k
CSC305 Lecture 14
javiergs
PRO
0
240
Migration to Signals, Resource API, and NgRx Signal Store
manfredsteyer
PRO
0
150
Featured
See All Featured
The Myth of the Modular Monolith - Day 2 Keynote - Rails World 2024
eileencodes
26
3.2k
Git: the NoSQL Database
bkeepers
PRO
431
66k
How Fast Is Fast Enough? [PerfNow 2025]
tammyeverts
2
300
GraphQLの誤解/rethinking-graphql
sonatard
73
11k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
34
2.3k
Optimising Largest Contentful Paint
csswizardry
37
3.5k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
132
19k
Designing for Performance
lara
610
69k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
194
16k
How GitHub (no longer) Works
holman
315
140k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
140
34k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
249
1.3M
Transcript
2025/10/19 hashimoto-kei AkarengaLT Vol. 38
ࣗݾհ Let me introduce myself.
໊લɿhashimoto-kei name: hashimoto-kei
ग़ɿԬ birthplace: Fukuoka City
ॴଐɿελʔτΞοϓ@Ԭ belong_to: startup at Fukuoka
ݞॻɿݚڀһ position: researcher
ࣄɿΤϯδχΞ work: engineer
ٕज़ελοΫɿPython, AWS technology stack: Python, AWS
͖ͳຊɿNand2Tetris favorite book: Nand2Tetris
None
ࠓͷςʔϚ Today’s theme
͘͠Έ.py
⚙.🐍
Python ͷΈ How Python works
CPython
Python͕ϓϩάϥϜΛ࣮ߦ͢ΔྲྀΕɺ࠷ޙʹʮόΠτίʔυʯ͕ੜ͞ΕΔ https://xtech.nikkei.com/ a tcl/nxt/column/18/02585/092000003/?SS=imgview&FD=1420927604
CRuby
Rubyͷதͷ༧උࣝ_RubyK a igiͷલʹΓୄʂ_ެ։༻ https://docs.google.com/present a tion/d/1oFvP4W3Ox8uiGXsW a 3ibyDg a 1cpLguVZhwCjpD46hFU/
mobilepresent?slide=id.g3389fccf211_0_100
4 components
None
Hands-on
Version
https://www.python.org/downlo a ds/
None
લఏࣝ Background
Modules
Python Language Services
https://docs.python.org/3.13/libr a ry/l a ngu a ge.html
🐍
ࣈ۟ղੳث Lexical Analyzer
None
લఏࣝ Background
ࣈ۟ lexeme
ϓϩάϥϜΛߏ͢Δ࠷খ୯Ґ Minimum unit for program
ࣗવݴޠͷʮ୯ޠʯ Like word in natural language
τʔΫϯ token
จ๏ͷߏ୯Ґ unit for grammar
ࣗવݴޠͷʮࢺʮจܕཁૉʯ Like grammatical element in natural language
ࣈ۟ղੳ Lexical Analysis
ίʔυΛτʔΫϯʹม Convert source code into tokens
https://docs.python.org/3.13/gloss a ry.html#term-token
https://docs.python.org/3.13/gloss a ry.html#term-lexic a l- a n a lyzer
Hands-on
https://docs.python.org/3.13/libr a ry/tokenize.html
None
ߏจղੳث Parser
None
લఏࣝ Background
நߏจ Abstract Syntax Tree
จ๏ߏΛʮʯͰදݱ Represent syntax as tree
ߏจղੳ Parsing
จ๏ϧʔϧΛͱʹ τʔΫϯྻΛ AST ʹม Convert tokens into AST with grammar
Hands-on
https://docs.python.org/3.13/libr a ry/ a st.html
None
None
ίϯύΠϥ Compiler
None
લఏࣝ Background
όΠτίʔυ bytecode
VM ͕࣮ߦͰ͖Δதؒදݱ IR run by Python’s VM
https://docs.python.org/3.13/gloss a ry.html#term-bytecode
Hands-on
https://docs.python.org/3.13/libr a ry/dis.html
None
ԾϚγϯ VM
None
લఏࣝ Background
ԾϚγϯ VM
தؒදݱΛղऍ࣮ͯ͠ߦ͢Δ Execute IR
https://docs.python.org/3.13/gloss a ry.html#term-virtu a l-m a chine
Let’s try !
⚠
1 + 2 * 3
NUMBER (1) PLUS (‘+’) NUMBER (2) MULT (‘*’) NUMBER (3)
EOF (‘’)
จ๏ϧʔϧΛͱʹ τʔΫϯྻΛ AST ʹม Convert tokens into AST with grammar
όοΧεɾφΞه๏ BNF
จ๏Λهड़͢ΔͨΊͷه๏ Notation to define grammar
None
ύʔαδΣωϨʔλ Parser Generator
จ๏ϑΝΠϧΛೖྗ͢Δͱ ύʔαʔΛੜ͢Δ Generate parser with grammar file
LALR (1) Parser
None
None
ਂ͞༏ઌ୳ࡧ/ؼΓ͕͚ॱ DFS / post-order
PUSH 1 PUSH 2 PUSH 3 MULT PLUS POP
ελοΫϚγϯ Stack Machine
PUSH 1 PUSH 2 PUSH 3 MULT PLUS POP =>
PUSH 1 PUSH 2 PUSH 3 MULT PLUS POP =>
1
PUSH 1 PUSH 2 PUSH 3 MULT PLUS POP =>
1 2
PUSH 1 PUSH 2 PUSH 3 MULT PLUS POP =>
1 2 3
PUSH 1 PUSH 2 PUSH 3 MULT PLUS POP =>
1 6
PUSH 1 PUSH 2 PUSH 3 MULT PLUS POP =>
7
PUSH 1 PUSH 2 PUSH 3 MULT PLUS POP =>
1 + 2 * 3
End ...?
None
None
Thank you for listening!