News for hackers. Stuff that matters.
Re:David Patterson Says It’s Time for New Computer Architect... by RcouF1uZ4gsC on Monday September 17, 2018 @05:29PM (#18010256)
C++ has alignas since C++11 https://en.cppreference.com/w/cpp/language/alignas

and since C++17 has std::hardware_destructive_interference_size and std::hardware_constructive_interference_size https://en.cppreference.com/w/cpp/thread/hardware_destructiv...

which you can use together to either make sure that 2 variables are not in the same cache line (if you are making a lock-free list for example) or to make sure at compile-time that 2 variables are close enough to share a cache-line.

Re:David Patterson Says It’s Time for New Computer Architect... by geezerjay on Monday September 17, 2018 @06:01PM (#18010521)
Thank you for pointing out that gem. Good to know!