Two counters that slow each other down
Two threads increment two separate counters, with no shared data and no locks. Performance is far worse than expected, and improves when padding is added between the counters.
What is happening?
Two threads increment two separate counters, with no shared data and no locks. Performance is far worse than expected, and improves when padding is added between the counters.
What is happening?