News for hackers. Stuff that matters.
Re:How to speed up the Rust compiler some more by twoodfin on Wednesday November 23, 2016 @10:09AM (#13023125)
This is important to keep in mind when looking at profiling reports: The cost of cache effects (both I and D!) can be spread throughout the critical path. Even if your profile shows your allocator being executed only in (say) 2% of the samples, if what it's doing during that time is pushing lots of useful instructions or data out of the fastest caches into which they otherwise would fit, the total cost of that allocation is likely much greater, but hard to pinpoint.
Re:How to speed up the Rust compiler some more by ronjouch on Wednesday November 23, 2016 @10:28AM (#13023244)
Thanks unwind/twoodfin! @twoodfin, can you precise what you mean by "cache effects (both I and D!)" ? (Indirect and Direct? By Indirect you mean Associative and by Direct you mean Direct Mapped as defined in http://www.ecs.umass.edu/ece/koren/architecture/Cache/tutori... ?). Also, googling "direct indirect cache" yielded the hilarious http://onlinelibrary.wiley.com/doi/10.1046/j.1439-0310.2003....

To other programmers not so familiar with CPU caching, resharing two blurbs that helped me get a start of a grasp on it:

- Why do CPUs have multiple cache levels? https://news.ycombinator.com/item?id=12245458 , https://fgiesen.wordpress.com/2016/08/07/why-do-cpus-have-mu...

- CppCon 2014 - Mike Acton: Data-oriented design and C++ , https://www.youtube.com/watch?v=rX0ItVEVjHc

Re:How to speed up the Rust compiler some more by kibwen on Wednesday November 23, 2016 @10:51AM (#13023401)
I believe by "I and D" the parent is referring to instruction cache and data cache: http://stackoverflow.com/questions/22394750/what-is-meant-by...
Re:How to speed up the Rust compiler some more by hrydgard on Wednesday November 23, 2016 @10:43AM (#13023343)
I-cache and D-cache means instruction cache and data cache.
Re:How to speed up the Rust compiler some more by vvanders on Wednesday November 23, 2016 @12:08PM (#13023959)
We used to call that a "flat profile" where everything looks slow due to cache thrashing but there's no inner loop that's a smoking gun.

It's really a shame more platforms don't show cache/icache misses in an easy to access manner.