Reducing false sharing on shared memory multiprocessors through compile time data transformations

  • Authors:
  • Tor E. Jeremiassen;Susan J. Eggers

  • Affiliations:
  • AT&T Bell Laboratories, 600 Mountain Ave., Murray Hill, New Jersey;Department of Computer Science and Engineering, University of Washington, Seattle, Washington

  • Venue:
  • PPOPP '95 Proceedings of the fifth ACM SIGPLAN symposium on Principles and practice of parallel programming
  • Year:
  • 1995

Quantified Score

Hi-index 0.01

Visualization

Abstract

We have developed compiler algorithms that analyze explicitly parallel programs and restructure their shared data to reduce the number of false sharing misses. The algorithms analyze per-process shared data accesses, pinpoint the data structures that are susceptible to false sharing and choose an appropriate transformation to reduce it. The transformations either group data that is accessed by the same processor or separate individual data items that are shared.This paper evaluates that technique. We show through simulation that our analysis successfully identifies the data structures that are responsible for most false sharing misses, and then transforms them without unduly decreasing spatial locality. The reduction in false sharing positively impacts both execution time and program scalability when executed on a KSR2. Both factors combine to increase the maximum achievable speedup for all programs, more than doubling it for several. Despite being able to only approximate actual inter-processor memory accesses, the compiler-directed transformations always outperform programmer efforts to eliminate false sharing.