~/talk

Hitchhiker’s Guide to the EVM

Talkat SmartCon Developer 2021 · on Friday, 2021-08-06· [smart-contracts, security]
name:Alex Roan
github:alexroan
slides:none on file

Practical EVM gas rules: avoid persistent storage when the data is never read again and emit events instead of storage, which in an example saves ~25,000 gas; prefer s_store/s_load alternatives like constants or immutables to cut repeated loads (example: 2.5k gas → 450); minimize reads by caching storage to memory (small examples save ~500 gas); account for EIP‑2929 cold/warm access; and pack structs (32‑byte slots, use uint96 and reorder fields) to halve slot usage.

AI-written summary · about

  1. 0:00Introduction
  2. 0:30Topics
  3. 1:27Gas Golfing
  4. 4:29Dont Store
  5. 6:32Use Constants
  6. 8:27Make it Obvious
  7. 9:35Dont ReadWrite Too Often
  8. 12:41Pack Your structs
  9. 14:00Structure
  10. 14:41Storage
  11. 16:25Uint 96
  12. 17:26Two Slots
  13. 18:54Recap
  14. 19:51Outro
~/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.