Modern Dictionaries by Raymond Hettinger
SF PythonYouTube ↗
Further reading 2
When one component fails, who can keep working? →One process fails. Must unrelated requests wait? Separate failure propagation from throughput limits, then trace what the operating system and service manager can actually isolate.This video helps answer · What does a repeated microbenchmark leave out?When does input become an instruction? →A typo can still be valid code. A data format can turn out to express computation. Follow an input inward and identify who decides how to interpret it.This video helps answer · When is a typo a valid program?
Caption notes
Python dictionaries use sparse indices and dense entries to improve memory use and iteration. Deletion, probing and ordering semantics shape the tradeoffs.
Original passages · 6
smush all of these together and put the holes in a tiny little tablestore is key one time the hash one time and only save the valuesfeatures that individually seem to make sense but brought together might be terriblewhen you go to time it you're timing the feature of interest which puts it in cash anywaywe fetch an entire cache line at a timethere's no space in between them