#

branch-prediction

CPU branch prediction, misprediction penalties and how they affect control flow.

ProgrammingWhy sorted arrays run faster: branch prediction, cache

Why processing a sorted array is faster: fewer branch mispredictions, improved vectorization and cache locality. C++/Java benchmarks and fixes. Practical fixes.

1 answer 6 views