News for hackers. Stuff that matters.
Re:DRAM Prices in ‘Freefall’ by vvanders on Thursday March 07, 2019 @03:07PM (#19331771)
Conversely cache misses are painful and largely haven't gotten faster over the years.
Re:DRAM Prices in ‘Freefall’ by mbreese on Thursday March 07, 2019 @03:19PM (#19331899)
Exactly. And the reason why programs that use a lot of memory might feel slower than one with a little is that cache miss rate.

Adding memory often makes an entire system faster (again, because you can cache things in the faster RAM rather than paging out to disk). But for two comparable programs, I could see the argument that the lower-memory footprint program would be faster. (For comparable programs).

Re:DRAM Prices in ‘Freefall’ by fwip on Thursday March 07, 2019 @04:08PM (#19332456)
If the algorithms are otherwise identical, sure.

Often the memory being used is doing things like pre-loading information from disk or the network before it's needed, or caching results for reuse.

Or it's storing the information in a faster but less dense data structure - kind of like denormalizing a database for performance reasons.

Re:DRAM Prices in ‘Freefall’ by vvanders on Thursday March 07, 2019 @03:39PM (#19332112)
Yup, as DDR clock speed increased so have CAS timings.
Re:DRAM Prices in ‘Freefall’ by segfaultbuserr on Thursday March 07, 2019 @04:13PM (#19332508)
It's a serious problem in compiler optimization. In the ideal world, a program with loop unrolling and vectorization should always be faster, but in practice, the bigger binary size induces cache misses and may produce a slower problem. Time goes by, and compilers keep adding increasingly complex techniques based on space/time tradeoffs, making the problem trickier.

Historically, under some circumstances, a problem compiled with -Os, may paradoxically be faster than -O2, and -O2 may be faster than -O3. I think the situation is getting better now, and the optimizing level mostly works as advertised. But there's still some problems in automatic loop vectorization.

Re:DRAM Prices in ‘Freefall’ by 0815test on Thursday March 07, 2019 @08:10PM (#19334275)
> In the ideal world, a program with loop unrolling and vectorization should always be faster, but in practice, the bigger binary size induces cache misses and may produce a slower problem.

The solution is to use abstract, arbitrary vectors in the ISA instead of packed SIMD and unrolled loops. RISC-V gets this right with their V extension.

Re:DRAM Prices in ‘Freefall’ by greglindahl on Thursday March 07, 2019 @08:23PM (#19334339)
There are many different kinds of loop unrolling, and RISC-V's V extension is not the only one. Itanium had the same issue: the loop unrolling assist in the instruction set was not viewed by many compiler people as being sufficient.
Re:DRAM Prices in ‘Freefall’ by colejohnson66 on Friday March 08, 2019 @03:15PM (#19341746)
ForwardCom has abitrary length vector support. http://www.forwardcom.info/ https://news.ycombinator.com/item?id=19340267
Re:DRAM Prices in ‘Freefall’ by greglindahl on Thursday March 07, 2019 @08:07PM (#19334262)
What's the paradox? The compiler simply can't tell.