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
Scala Native
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
yubessy
January 29, 2018
Programming
240
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Scala Native
社内勉強会用資料です
yubessy
January 29, 2018
More Decks by yubessy
See All by yubessy
DDIA (Designing Data-Intensive Applications) はいいぞ
yubessy
0
1.6k
Introduction to CircleCI
yubessy
1
130
Docker Hands-on
yubessy
0
120
Resource Polymorphism
yubessy
0
310
不動点コンビネータ?
yubessy
0
320
とりあえず機械学習したかった
yubessy
0
350
Type Erasure と Reflection のはなし
yubessy
1
490
量子暗号
yubessy
0
250
5分ちょいでわかった気になるラムダアーキテクチャ
yubessy
0
2.3k
Other Decks in Programming
See All in Programming
【SRE NEXT 2026 Lunch Session】一人目専任SREの立ち上げを加速する ― AIと進めたオンボーディングで2分を0.04秒にした話
pkshadeck
PRO
0
3.6k
Welcome to the "Parametricity" 🏙️ − Generic だけど Specific な世界 −
guvalif
PRO
1
210
AI時代、エンジニアはどう育つのか -未経験エンジニアの成長を間近で見て考えたこと-
thasu0123
0
220
メールのエイリアス機能を履き違えない
isshinfunada
0
230
komatsuna「分散システムにおけるバグ分析手法」
komatsunaqa
0
240
継続モナドとリアクティブプログラミング
yukikurage
3
700
言語を使う側から、作る側へ。 自作 Lisp で得た新たな気づき。
andpad
0
160
関東Kaggler会_NVIDIA_Nemotron_コンペ_振り返り
rick_ds
0
490
torikago - Ruby::Boxで照らすモジュラモノリスの実行境界
se4weed
1
350
属人化した知識を、 AIが辿れる地図にする
pkshadeck
PRO
1
150
Go言語とトイモデルで学ぶTransformerの気持ち / fukuokago23-transformer
monochromegane
0
160
GDG Korea Android: 2026 I/O Extended ~ What's new in Android development tools
pluu
0
220
Featured
See All Featured
What Being in a Rock Band Can Teach Us About Real World SEO
427marketing
0
1.1k
Site-Speed That Sticks
csswizardry
13
1.4k
Effective software design: The role of men in debugging patriarchy in IT @ Voxxed Days AMS
baasie
0
470
Reflections from 52 weeks, 52 projects
jeffersonlam
356
21k
Testing 201, or: Great Expectations
jmmastey
46
8.2k
Stop Working from a Prison Cell
hatefulcrawdad
274
21k
New Earth Scene 8
popppiees
3
2.5k
Visualization
eitanlees
152
17k
How to build a perfect <img>
jonoalderson
1
5.9k
From Legacy to Launchpad: Building Startup-Ready Communities
dugsong
0
290
The Anti-SEO Checklist Checklist. Pubcon Cyber Week
ryanjones
0
200
The SEO identity crisis: Don't let AI make you average
varn
0
530
Transcript
Scala Native @yubessy 0x64 Reboot #10 " "
: : ( ) x -> o +
Scala Native Scala Scala JVM -> Java Scala Native ->
Java
LLVM (?) Scala Native Scala SBT
$ sbt new scala-native/scala-native.g8 object Main { def main(args: Array[String]):
Unit = println("Hello, world!") } $ sbt run Hello, World!
LLVM https://github.com/okapies/scala-native-example bonacci
(rec) def fib(n: Long): Long = n match { case
0 => 0 case 1 => 1 case _ => fib(n - 2) + fib(n - 1) }
(tail rec) def fibImpl(n: Long, a: Long, b: Long): Long
= n match { case 0 => a case _ => fibImpl(n - 1, b, a + b) } def fib(n: Long): Long = { fibImpl(n, 0, 1) }
(mut rec) def fib(n: Long): Long = n match {
case 0 => 0 case _ => fibS(n - 1) } def fibS(n: Long): Long = n match { case 0 => 1 case _ => fib(n - 1) + fibS(n - 1) }
(μs) rec tail rec mut rec JAR 74801223 262 67248872
Native -O0 168336051 4 164421481 Native -O2 77311107 4 34026913 Native -O0 ( ) rec, mute rec JAR . tail rec Native -O2 ( ) mute rec JAR
Scala Native LLVM