Live data from Hacker News

Memory Bandwidth Napkin Math

forrestthewoods.com

1–10 of 56 posts

Re: Memory Bandwidth Napkin Math

#3
post #2

This is a lot more than just Napkin Math. He writes a synthetic benchmark to demonstrate the orders of magnitude difference in performance you can see depending on how you approach a problem.

... to get the numbers presented at the end for doing napkin math.

Re: Memory Bandwidth Napkin Math

#5
It's funny, I had this conversation last week as the coworker, but didn't actually know how to go about calculating this without running tests.

It does seem like there are classes of problems which are completely bandwidth-limited. I've heard this is the next area of expansion for hardware tech, but I haven't seen much yet.

Re: Memory Bandwidth Napkin Math

#6
I’ve been fascinated by the 'napkin math' topic recently, but felt a need for a way to routinely practise. It’s an acquired skill once it’s effortless to do the order of magnitude calculations in a meeting, or zipping through possible solutions on a whiteboard (what I imagine Jeff Dean does). Will it be fast enough? How much will it cost? Does the benchmarked performance match the order of magnitude we’d expect?

To practise, I created a newsletter last year with a monthly problem that may be of interest to others wanting to sharpen their napkin math: https://sirupsen.com/napkin/

Re: Memory Bandwidth Napkin Math

#7
post #6

I’ve been fascinated by the 'napkin math' topic recently, but felt a need for a way to routinely practise. It’s an acquired skill once it’s effortless to do the order of magnitude calculations in a meeting, or zipping through possible solutions on a whiteboard (what I imagine Jeff Dean does). Will it be fast enough? How much will it cost? Does the benchmarked performance match the order of magnitude we’d expect? To p…

The article isn't really about napkin math and rough estimates. It actually goes into using simple benchmarks to calibrate to modern performance numbers.

Re: Memory Bandwidth Napkin Math

#8

Sounds like he's trying to reinvent the roofline model. A lot of work has been already done in this area. https://en.wikipedia.org/wiki/Roofline_model

He didn't try to 'reinvent a model' he just showed where modern numbers fall in his simple benchmarks.

Re: Memory Bandwidth Napkin Math

#9

Sounds like he's trying to reinvent the roofline model. A lot of work has been already done in this area. https://en.wikipedia.org/wiki/Roofline_model

Are you andi kleen from toplev ? Used it quite extensively during a summer a few years ago for profiling stuff. Great toolkit.

Re: Memory Bandwidth Napkin Math

#10
That's a really great post!

Good problem description, good introduction, explained code, meaningful and explained graphs, full source code available, conclusion and even possible further exercises. I wish (all) scientific papers were that well written.

Post reply on HN