~/talk

Swift 2 Under the Hood

Talkat GOTO Berlin 2015 · 2015-12-03..12-04· [swift, compilers-and-language-design]
links:none on file
slides:none on file

Swift 2.1 compiles through an AST to SIL -> LLVM IR and uses whole-module optimizations and inlining to remove calls (example: a private add function disappears), producing fewer CPU instructions and fewer cache misses; value types lay out arrays contiguously so scanning ints hits cached 64-byte lines instead of dereferencing objc pointer arrays. objc_msgSend overhead is highlighted historically (hundreds to ~47 bytes), Apple accepts bitcode for App Store relinking, and a sill-inspector (GitHub) tool shows the pipeline.

AI-written summary · about

  1. 0:00Introduction
  2. 0:16About This Talk
  3. 1:22Pre-history
  4. 5:14A lot has changed...
  5. 6:05CPU speed
  6. 8:11Memory latency
  7. 9:59Why Swift?
  8. 10:47Modules
  9. 11:57Types
  10. 12:47Numeric values
  11. 14:31Protocols
  12. 15:40Memory optimisation
  13. 17:57Static and Dynamic?
  14. 19:34Static Dispatch
  15. 20:25objc_msgSend
  16. 22:10Optimisations
  17. 23:16Whole Module Optimisation
  18. 24:46Swift and LLVM
  19. 25:34Swift compile pipeline
  20. 28:17Example C based IR
  21. 29:21Advantages of IR
  22. 29:56Example Swift based IR
  23. 32:54Swift Name Mangling
  24. 33:26Swift Intermediate Language
  25. 34:25Swift v Tables
  26. 35:38SIL Inspector
  27. 47:19Is Swift swift yet?
  28. 48:52Summary
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.