Skip to content

libomptarget

Ye Luo edited this page Jul 29, 2020 · 18 revisions

micro steps in omptarget.

  1. Enter data region. map analysis, allocate memory and increase reference counting. Generate H2D and D2H pair lists, first-private array list.
  2. Resolve dependency in. wait events
  3. Transfer H2D
  4. Launch kernel
  5. Transfer D2H
  6. Create dependency out. record events.
  7. Exit data region. decrease reference counting, delete first-private array items.

Rules:

  • q_start must be before 2.
  • q_stop must be after 6.

Decompose target constructs:

In nowait case,

  • target: 1, q_start, 2-6, q_stop, 7
  • target data:. 1, q_start, 2-3, q_stop, host region, q_start, 5, 6, q_stop, 7
  • target enter data: 1, q_start, 2-3, 6 q_stop
  • target exit data: 1, q_start, 2, 5-6, q_stop, 7
  • target update 1, q_start, 2-3, 5-6, q_stop, 7
Clone this wiki locally