GPUOcelot
|
A class for determining thread frontiers for all basic blocks. More...
#include <ThreadFrontierAnalysis.h>
Public Types | |
typedef ir::ControlFlowGraph::ConstBlockPointerVector | BlockVector |
typedef ir::ControlFlowGraph::const_iterator | const_iterator |
typedef unsigned int | Priority |
typedef std::unordered_map < const_iterator, Priority > | PriorityMap |
Public Member Functions | |
ThreadFrontierAnalysis () | |
Create the analysis. | |
void | analyze (ir::IRKernel &kernel) |
Computes an up to date set of thread frontiers. | |
BlockVector | getThreadFrontier (const_iterator block) const |
Get the blocks in the thread frontier of a specified block. | |
Priority | getPriority (const_iterator block) const |
Get the scheduling priorty of a specified block. |
A class for determining thread frontiers for all basic blocks.
Thread frontiers defines a scheduling order of threads and identifies re-convergence points. The approach has two main steps: 1) Assign a priority order to basic blocks. 2) For each basic block, determine all other possible blocks where stalled threads may be waiting.
The intersection of this set and a branch target's predecessors need to be checked for re-convergence. The algorithm used here is taken directly from [1].
[1] - "SIMD Reconvergence at Thread Frontiers" by Diamos et al.
typedef unsigned int analysis::ThreadFrontierAnalysis::Priority |
typedef std::unordered_map<const_iterator, Priority> analysis::ThreadFrontierAnalysis::PriorityMap |
analysis::ThreadFrontierAnalysis::ThreadFrontierAnalysis | ( | ) |
Create the analysis.
void analysis::ThreadFrontierAnalysis::analyze | ( | ir::IRKernel & | kernel | ) | [virtual] |
Computes an up to date set of thread frontiers.
Implements analysis::KernelAnalysis.
ThreadFrontierAnalysis::Priority analysis::ThreadFrontierAnalysis::getPriority | ( | const_iterator | block | ) | const |
Get the scheduling priorty of a specified block.
ThreadFrontierAnalysis::BlockVector analysis::ThreadFrontierAnalysis::getThreadFrontier | ( | const_iterator | block | ) | const |
Get the blocks in the thread frontier of a specified block.