Skip to main content
QUICK REVIEW

[Paper Review] Optimizing ccNUMA locality for task-parallel execution under OpenMP and TBB on multicore-based systems

Markus Wittmann, Georg Hager|arXiv (Cornell University)|Dec 30, 2010
Parallel Computing and Optimization TechniquesComputer Science9 references12 citations
TL;DR

This paper proposes a software layer that optimizes data locality in task-parallel workloads on ccNUMA systems by sorting tasks into locality-specific queues, ensuring threads process data from their local memory domain. The approach preserves dynamic load balancing within each domain while minimizing nonlocal memory access, significantly improving performance on OpenMP and TBB workloads, especially under irregular or load-imbalanced workloads.

ABSTRACT

Task parallelism as employed by the OpenMP task construct or some Intel Threading Building Blocks (TBB) components, although ideal for tackling irregular problems or typical producer/consumer schemes, bears some potential for performance bottlenecks if locality of data access is important, which is typically the case for memory-bound code on ccNUMA systems. We present a thin software layer ameliorates adverse effects of dynamic task distribution by sorting tasks into locality queues, each of which is preferably processed by threads that belong to the same locality domain. Dynamic scheduling is fully preserved inside each domain, and is preferred over possible load imbalance even if nonlocal access is required, making this strategy well-suited for typical multicore-mutisocket systems. The effectiveness of the approach is demonstrated by using a blocked six-point stencil solver as a toy model.

Motivation & Objective

  • To address performance degradation in task-parallel applications on ccNUMA systems due to nonlocal memory accesses.
  • To enable effective data locality optimization without requiring changes to the OpenMP or TBB programming model.
  • To preserve dynamic load balancing within each locality domain while minimizing inter-domain memory access.
  • To evaluate the effectiveness of locality queues in improving performance on real ccNUMA hardware with irregular or load-imbalanced workloads.
  • To compare the proposed approach with existing mechanisms like the TBB affinity partitioner and round-robin memory placement.

Proposed method

  • Introduce a user-level software layer that sorts tasks into multiple locality queues based on the target memory domain of the data.
  • Assign each thread to a specific locality domain and ensure it primarily processes tasks from its local queue.
  • Preserve dynamic scheduling within each locality domain to maintain load balance, even when tasks require nonlocal data access.
  • Use a work-stealing mechanism to redistribute tasks across domains when load imbalance occurs, prioritizing load balancing over strict locality.
  • Implement the mechanism using standard OpenMP tasking and TBB’s parallel_for with a custom partitioner or concurrent queues.
  • Leverage thread-core affinity and runtime detection of locality domain IDs to map tasks to appropriate queues.

Experimental results

Research questions

  • RQ1Can a lightweight software layer effectively improve data locality in task-parallel applications on ccNUMA systems?
  • RQ2How does the proposed locality queue mechanism compare to native TBB affinity partitioning in terms of performance and scalability?
  • RQ3To what extent does the approach reduce nonlocal memory access and improve bandwidth utilization in irregular or load-imbalanced workloads?
  • RQ4Does the method maintain dynamic load balancing while optimizing for memory locality?
  • RQ5Can the technique be applied effectively to real scientific workloads like sparse matrix solvers or stencil computations?

Key findings

  • The locality queue mechanism significantly reduces nonlocal memory access and improves performance on ccNUMA systems, especially under irregular or load-imbalanced workloads.
  • On the AMD Istanbul system, the approach achieved performance close to optimal round-robin memory placement, outperforming naive dynamic scheduling.
  • The TBB affinity partitioner achieved performance comparable to the locality queue approach, but the latter offers more control and extensibility.
  • Using locality queues with TBB’s parallel_do construct may offer advantages over the built-in partitioner, though this was not fully evaluated in the study.
  • The method is effective even without strict thread-core affinity, as locality domain IDs can be determined at runtime.
  • The approach enables temporal blocking and communication-computation overlap in sparse matrix solvers by associating queues with shared cache levels.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.