~/talk

Taking Elixir to the Metal

Talkat ElixirDaze 2018 · 2018-03-01..03-02· [rust]
speakerdeck:scrogson
slides:none on file

Demonstrates building Elixir NIFs in Rust using Rustler to avoid crashing the BEAM and to catch panics, with a native JSON parser wired into Mix. A naive NIF decoding an 8 MB JSON takes ~1.5s and reports only 10 reductions; reworking to chunked parsing with resource objects and a mutex raises that to 11,000 reductions and avoids scheduler collapse. Also shows dirty schedulers and threaded NIFs so long work returns immediately and sends results asynchronously.

AI-written summary · about

  1. 0:00Intro
  2. 0:50Elixir
  3. 1:06Trinity
  4. 1:19Orchestration
  5. 2:17Erlang
  6. 3:27Port Drivers
  7. 5:34WARNING
  8. 6:02ElixirNIFs
  9. 6:52Functionality
  10. 8:17If structure
  11. 9:45NIF term
  12. 9:57NIF func
  13. 10:56C
  14. 11:13Rust
  15. 12:20Rust accolades
  16. 13:16Erlang NIF sis
  17. 14:25Rust Library
  18. 16:33Getting Started
  19. 16:45Rustler
  20. 17:13Mix
  21. 18:09Init
  22. 18:24Rust File
  23. 19:48Simple Approach
  24. 20:07Decoder
  25. 22:28JSON2Term
  26. 23:05Time
  27. 24:07naive approach
  28. 24:32strange behaviors
  29. 25:22Cores
  30. 26:09Schedulers
  31. 26:22Run Queue
  32. 28:16Thread Progress
  33. 28:39Scheduler Threads
  34. 31:06Account Reductions
  35. 31:32Count Reductions
  36. 31:47Chunking
  37. 32:09JSON Parser
  38. 33:19Resource Objects
  39. 35:35Mutex
  40. 37:19Sink
  41. 39:44Results
  42. 39:57Reschedule
  43. 41:12Threaded News
  44. 41:50Threaded Decode
  45. 42:52Elixir Decode
  46. 43:14Dirtiness
  47. 44:19scheduler flags
  48. 45:19Conclusion
~/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.