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
SwiftコンパイラにContributeする
Search
freddi(Yuki Aki)
September 30, 2020
2
360
SwiftコンパイラにContributeする
freddi(Yuki Aki)
September 30, 2020
Tweet
Share
More Decks by freddi(Yuki Aki)
See All by freddi(Yuki Aki)
輝け俺のViewController 〜海外iOSカンファレンス登壇編〜
freddi
4
200
Deep Dive into "any" and "some"
freddi
3
1.3k
挑戦!ISUCON de Server-side Swift 〜タイムゾーンには気をつけろ〜
freddi
0
1.4k
意外と知られてないXcode13の新しい参照カウンタ最適化オプションの挙動
freddi
2
100
How to develop SIL Optimizer in Swift Language
freddi
0
290
SwiftコンパイラがSwiftで開発できるようになる話
freddi
3
560
知ろう! ShazamKit
freddi
1
160
Swift Optimizing at Compiler World
freddi
1
740
Recap Pointfree Vol. 1~3
freddi
1
770
Featured
See All Featured
Bootstrapping a Software Product
garrettdimon
PRO
305
110k
Embracing the Ebb and Flow
colly
84
4.5k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
26
1.9k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
45
2.2k
Writing Fast Ruby
sferik
628
61k
GitHub's CSS Performance
jonrohan
1030
460k
Keith and Marios Guide to Fast Websites
keithpitt
410
22k
RailsConf 2023
tenderlove
29
940
Facilitating Awesome Meetings
lara
50
6.1k
How to Ace a Technical Interview
jacobian
276
23k
Build your cross-platform service in a week with App Engine
jlugia
229
18k
A designer walks into a library…
pauljervisheath
204
24k
Transcript
4XJGUίϯύΠϥʹ $POUSJCVUF͢Δ·Ͱ Swift愛好会 Vol. 54 "QQMF͕։ൃͨ͠ΦʔϓϯιʔεͳίϯύΠϥʹߩݙ͢Δ GSFEEJ <ొஃऀ> ͔ΜͨΜͳ 4XJGUͷਂ͍ϨΠϠʔͷಡΈา͖ํ
4XJGU*OUFSNFEJBUF-BOHVBHFɹɹ4*-0QUJNJ[FS
GSFEEJ ొஃऀ ʹ͍ͭͯ ΠΩϦJ04&OHJOFFS
ࠓॳ৺ऀ͚ͷίϯύΠϥͷ ͕$POUSJCVUF͢Δ·ͰʹͲΜͳ͜ͱ͔ͬͨ w Ͳ͏͍͏ࣝΛಘ͔ͨ w Ͳ͏͍͏ΞΫγϣϯΛ͔ͨ͠
୯ೖʹݴ͑ 4XJGUίϯύΠϥʹ$POUSJCVUF͠·ͨ͠ w IUUQTHJUIVCDPNBQQMFTXJGUQVMM w IUUQTHJUIVCDPNBQQMFTXJGUQVMM
ԿΛ$POUSJCVUFͨ͠ͷʁ Ұͭ%PDTͷϛεͷగਖ਼ w 4XJGUͷதؒදݱͷ(SBNNFS͕ϛεͬͯͨ ͏Ұͭ࠷దԽϩδοΫͷόά w ੲɺొஃࢿྉ࡞ͬͯͨͱ͖ۮવݟ͚ͭͨͭ
ͱ͍͏Θ͚Ͱ4XJGU$POUSJCVUPSσϏϡʔ 4XJGUίϯύΠϥͷษڧࣗମڈ͔Β w ίϯύΠϥશൠͷษڧͬͯͨ w ͦͬͪʹཱ͔ͬͨඍົ
4XJGUίϯύΠϥͷษڧʹ͍ͭͯ ׂ̑͘Β͍ಠֶͰͬͨ ׂ̑͘Β͍Θ͍Θ͍TXJGUDͱ͔Ͱษڧ w ݄̍ͷ4XJGUίϯύΠϥͷษڧձ w աڈͷษڧձͷࢿྉಡΜͩΓ w ؔ࿈͢ΔํͷࢿྉΛಡΜͩΓ
ϞνϕͬͯԿʁ తح৺ͷෝ͘··ʹ͍ͬͯΔ w ͕ΒதϞνϕ͋ΔΘ͚Ͱͳ͍ ࣄͰ4XJGU͍ͬͯΔਂ͘Γ͍͔ͨΒ ͋ͱͦͷࣝͰΈΜͳͱΘ͍Θ͍͢Δͷָ͍͠
4XJGUίϯύΠϥͷೖͱ͍͑ ͜ͷίϯύΠϥͷϑϩʔਤ w ίϯύΠϥΔͱͷإΑΓݟΔӋʹͳΔ
4XJGUίϯύΠϥͷೖͱ͍͑ 4XJGU*OUFSNFEJBUF-BOHVBHF͔Β w 4XJGUͷதؒදݱݴޠ
4XJGU*OUFSNFEJBUF-BOHVBHF 4XJGUͷಛ༗ͷதؒදݱ w ௨শ4*- ίʔυΛநߏจʢ"45ʣʹͨ͠ޙͷϑΣʔζ 3VTUʹಉ͡Α͏ͳதؒදݱ͕͋Δ
ͳͥ4*-͔Βͳͷ͔ TXJGUDͷίʔυҾͬுΒΜ͍͍ͯ͘ 4*-͓खݩͰ͔ΜͨΜʹੜͰ͖Δ 4*-Λ࠷దԽ͢ΔίϯύΠϥͷίʔυಡΈ͍͢ w TXJGUDͷதͰൺֱతͱ͍͏ҙຯ ຊਓ͕Α͘4*-Λղઆ͍ͯ͠ΔͷͰจݙ๛
4XJGU͔Β4*-Λੜ͢Δ w ҎԼͷίϚϯυͰมͰ͖Δ swiftc -emit-sil hello.swift -o hello.sil w ҎԼͷίʔυΛม͑ͯΈΔ
print(“Hello SIL!”)
ಡΊͳ͍ɾɾɾʁ
Ͱେৎ LJUBTVLF͞Μͱ͍͏ํ͕ղઆ͍ͯ͠Δ IUUQTXXXTMJEFTIBSFOFULJUBTVLFTJMGPSpSTUUJNFMFBOFST
Ͱେৎ LJUBTVLF͞Μͱ͍͏ํ͕ຊΛॻ͍͍ͯΔ IUUQTLJUBTVLFCPPUIQNJUFNT
ͷ4*-ͷษڧ๏ ͖ͬ͞հͨ͠ຊͱࢿྉಡΈړͬͨ ͍ΖΜͳ4XJGUίʔυΛ4*-ʹͯ͠ಡΜͩ 4*-ͷߏΛཧղͨ͠
ͷ4*-ͷษڧ๏ 4*-͕ಡΊΔΑ͏ʹͳͬͨ ͢Δͱ4*-0QUJNJ[FS͕ಡΊΔΑ͏ʹͳΔ͜ͱʹؾͮ͘
4*-0QUJNJ[FS ͖ͬ͞ͷ4*-Λ࠷దԽ͢ΔίϯύΠϥͷϞδϡʔϧ 4XJGUಛ༗ͷ࠷దԽΛߦ͏
4*-0QUJNJ[FSʹؔͯ͠ ͜ͷຊ͕ࢀߟʹͳΔ IUUQTLJUBTVLFCPPUIQNJUFNT
࣍4*-0QUJNJ[FS ͜ͷ͜Ζ͔ΒࣗͰίϯύΠϥΛHJUDMPOFͨ͠ ίϯύΠϥͷίʔυΛ࿔ͬͯࣗͷ0QUJNJ[FS࡞ͬͨ
4*-0QUJNJ[FSͷษڧ ͦͷ࣌ͷͷղઆಈը͕͜Ε IUUQTXXXZPVUVCFDPNXBUDI W2#9D$5GXZ;
࣍0QUJNJ[FSͷதͷΈ͕ؾʹͳΔ ʮ෭࡞༻ͷ͋ΔίʔυʯΛൃݟ͢ΔΈ w ͜Ε͕ؾʹͳΓ͗ͯ͢͠ΐ͏͕ͳ͍ͷͰௐࠪ
ʮ෭࡞༻ͷ͋ΔίʔυʯΛൃݟ͢ΔΈ ΜͰ͜Εʹ͍ͭͯొஃ IUUQTTQFBLFSEFDLDPNGSFEEJNBZIBWFTJEFF⒎FDU
͜ͷௐࠪΛ௨ͯ͡ۮવόάΛݟ͚ͭΔ ͦΕ͕͖ͬ͞ͷ̎ͭͷBQQMFTXJGUͷ13 ҙ֎ͳͱ͜Ζͷௐ͕͖͔͚ࠪͬͯ$POUSJCVUF
͑ɺ$POUSJCVUFͨ͠ͷӡήʔ͡ΌΜ ͦ͏Ͱͳ͍ؾ͕͢Δ w (JUIVCʹ͋Δެࣜͷ4*-ͷղઆΨόΨό w '*9.&ͱ͔ҙ֎ͱࢸΔͱ͜Ζʹ͋Δ w νϟϯϨϯδͷՄೳੑແݶେ
$POUSJCVUFνϟϯεɺଞʹʁ IUUQTCVHTTXJGUPSHͱ͔όάใࠂͨ͘͞Μ͋Δ
͓લͷೖͬ͘͟Γ͗ͯ͢͠Θ͔ΒΜ LJUBTVLF͞Μ͕ຊΛ SZ IUUQTLJUBTVLFCPPUIQNJUFNT
ࣗ৴͕͍ͭͯདྷͯɺࣗ৴͕ͳͯ͘ Θ͍Θ͍TXJGUDʹࢀՃͯ͠Ͷʂొஃେܴ IUUQTJPTEJTDPSEDPOOQBTTDPN
·ͱΊ 4XJGUίϯύΠϥҙ֎ͱೖ͍͢͠Α Θ͍Θָ͍͘͠ษڧ͢Δͱ͍͔ͭ$POUSJCVUFͰ͖ΔΑ Θ͍Θ͍TXJGUDੋඇࢀՃͯ͠Ͷʢొஃʂʣ