Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
TruffleでPHPぽい言語を実装したら爆速だった話 / truffle php at jj...
Search
Naoki Kishida
February 27, 2019
Technology
2.8k
3
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
TruffleでPHPぽい言語を実装したら爆速だった話 / truffle php at jjug night seminar
TruffleでPHPを実装したら爆速だった話です
Naoki Kishida
February 27, 2019
More Decks by Naoki Kishida
See All by Naoki Kishida
Java 27新機能 / Java 27 new features
kishida
2
150
ローカルLLMでどこまでコードが書けるか -LLM基礎知識 / How much code can be written on a local LLM - fundamental knowledge
kishida
10
9.6k
ソフトウェアエンジニアにとっての生成AI - 特性を知って使い倒す / generative ai for software enginner
kishida
7
2.4k
ローカルLLMでどこまでコードが書けるか -縮小版 / How much code can be written on a local LLM Shortened
kishida
2
400
ローカルLLMでどこまでコードが書けるか -拡張版 / How much code can be written on a local LLM Extended
kishida
12
5.6k
Javaの型とAI時代に型が大事な理由 / java types and type in AI era
kishida
2
230
ローカルLLMでどこまでコードが書けるか / How much code can be written on a local LLM
kishida
2
640
ローカルLLM基礎知識 / local LLM basics 2025
kishida
30
17k
AIエージェントでのJava開発がはかどるMCPをAIを使って開発してみた / java mcp for jjug
kishida
5
1.3k
Other Decks in Technology
See All in Technology
安心して変更できるWebフロントエンドの作り方
pirosikick
5
2.7k
AI de Idea
kawaguti
PRO
2
120
AIエージェントの一手は 誰も見ていない - Falco拡張OSS「Prempti」とeBPFで サーバーレス実行基盤を二層防御する
keitah
0
200
10Xに技術的負債をもたらした「2つの境界の歪み」その構造と解消への営み
10xinc
0
2.1k
俺の仕事は AIに奪われないし、たぶんその BIも要らない
hikaruri
0
520
アクセスキーこわい やめかたと漏らさない工夫
sassssan68
1
410
絵ではじめるKubernetesセキュリティ
aoi1
4
670
バイブコーディング時代のWebアプリ開発入門~Cloud Runで学ぶセキュアなビルドとデプロイ
waiwai2111
1
140
Claude Code本って、 読む必要あるの?
oikon48
2
480
作って終わりじゃないサーバーレス 〜9年運用する大規模EC物流API基盤の設計・運用のリアル〜
zozotech
PRO
0
160
AIエージェントの権限管理 3: Agentic RAG の Fine grained access control 編
ren8k
0
110
LTのテーマ どうきめてる?〜5つの型と私のやり方〜
yama3133
1
110
Featured
See All Featured
Organizational Design Perspectives: An Ontology of Organizational Design Elements
kimpetersen
PRO
1
830
Side Projects
sachag
456
43k
Six Lessons from altMBA
skipperchong
29
4.5k
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
4.6k
Navigating the moral maze — ethical principles for Al-driven product design
skipperchong
2
550
What’s in a name? Adding method to the madness
productmarketing
PRO
24
4.2k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
12
1.8k
Optimising Largest Contentful Paint
csswizardry
37
4k
AI in Enterprises - Java and Open Source to the Rescue
ivargrimstad
0
1.5k
How to Talk to Developers About Accessibility
jct
2
550
What does AI have to do with Human Rights?
axbom
PRO
1
2.4k
Taking LLMs out of the black box: A practical guide to human-in-the-loop distillation
inesmontani
PRO
3
2.4k
Transcript
TrufflePHP JJUG 2019/2/27 LINE Fukuoka
• • LINE Fukuoka •
• @kis
Truffle •
Truffle • ()
Truffle
PHP • jparsec ( ) • https://github.com/jparsec/jparsec/ •
• +-<>.( ) • • • if • echo https://github.com/kishida/phpparser
<?php function fib($n) { if ($n
< 2) { return $n; } return fib($n - 1) + fib($n - 2); } echo "fib:".fib(31); echo "¥n";
(1/6) • Node
(2/6) • • (Specialization)
(3/6) • CallNode
(4/6) •
(5/6) • NodeDirectCallNodeCompilerAssertsGraal • Java
(6/6) • 5; • 0:, 4 %)5210:, 69; •
return=-2/ goto(JVM%)) jmp(*!' +) ReturnException #+&"$(87 resultObject <3.
<?php function fib($n) { if ($n < 2) {
return $n; } return fib($n - 1) + fib($n - 2); } $start = microtime(1); echo "fib:".fib(31); echo "¥n"; echo "time:".(microtime(1) - $start); echo "¥n"; fib(31);fib(31);fib(31);fib(31);fib(31); $start = microtime(1); echo "fib:".fib(31); echo "¥n"; echo "time:".(microtime(1) - $start); echo "¥n";
• (interpreter) on JDK 11 • Truffle
JDK 11 • Truffle GraalVM CE • Truffle GraalVM CE • Truffle GraalVM EE • Truffle GraalVM EE • PHP 5.6 • PHP 7.3
(JIT) • PHP 7.3PHP5.63 • PHP7.37 • Truffle+GraalVM
CEPHP7.3 • Truffle+GraalVM EEPHP7.32 • GraalVM CE PHP7.32 • GraalVM EE PHP7.34
• JIT • •
• EE PHP7.3 • CE PHP7.3
• PHP # &!"' • %
• • EE$CE% <?php function fib($n) { if ($n < 2) { return $n; } return fib($n - 1) + fib($n - 2); } echo "fib:".fib(31); echo "¥n";
• Real$) "UserCPU! " • JVMUser" ' •
( CPU" ' • GraalVMRealUser & • Graal#% ( CPU"
• PHPPHP3PHP4PHP5PHP7 '5# !"(PHP6&8) • (0, +*:% PHP7941
• "$!(03 • . '5# (0,6 -2 • 5/$7)#(Specialization)
• GraalVM • Truffle • "
# SimpleLanguage • Writing a Language in Truffle • gitter ! % • Graal&$