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
yubessy
January 29, 2018
Programming
0
220
Scala Native
社内勉強会用資料です
yubessy
January 29, 2018
Tweet
Share
More Decks by yubessy
See All by yubessy
DDIA (Designing Data-Intensive Applications) はいいぞ
yubessy
0
1.5k
Introduction to CircleCI
yubessy
1
110
Docker Hands-on
yubessy
0
100
Resource Polymorphism
yubessy
0
290
不動点コンビネータ?
yubessy
0
290
とりあえず機械学習したかった
yubessy
0
330
Type Erasure と Reflection のはなし
yubessy
1
450
量子暗号
yubessy
0
220
5分ちょいでわかった気になるラムダアーキテクチャ
yubessy
0
2.2k
Other Decks in Programming
See All in Programming
Navigating Dependency Injection with Metro
zacsweers
3
960
実用的なGOCACHEPROG実装をするために / golang.tokyo #40
mazrean
1
280
Updates on MLS on Ruby (and maybe more)
sylph01
1
180
「待たせ上手」なスケルトンスクリーン、 そのUXの裏側
teamlab
PRO
0
530
為你自己學 Python - 冷知識篇
eddie
1
350
Ruby×iOSアプリ開発 ~共に歩んだエコシステムの物語~
temoki
0
320
テストコードはもう書かない:JetBrains AI Assistantに委ねる非同期処理のテスト自動設計・生成
makun
0
320
go test -json そして testing.T.Attr / Kyoto.go #63
utgwkk
3
300
The Past, Present, and Future of Enterprise Java with ASF in the Middle
ivargrimstad
0
120
AIと私たちの学習の変化を考える - Claude Codeの学習モードを例に
azukiazusa1
10
4.2k
チームのテスト力を鍛える
goyoki
2
150
Oracle Database Technology Night 92 Database Connection control FAN-AC
oracle4engineer
PRO
1
450
Featured
See All Featured
Rebuilding a faster, lazier Slack
samanthasiow
83
9.2k
Why You Should Never Use an ORM
jnunemaker
PRO
59
9.5k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
367
27k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
53
2.9k
Scaling GitHub
holman
463
140k
Fireside Chat
paigeccino
39
3.6k
Speed Design
sergeychernyshev
32
1.1k
Building an army of robots
kneath
306
46k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
48
9.7k
The Myth of the Modular Monolith - Day 2 Keynote - Rails World 2024
eileencodes
26
3k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
PRO
188
55k
RailsConf 2023
tenderlove
30
1.2k
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