automatically exploiting cross-invocation parallelism using runtime ...
automatically exploiting cross-invocation parallelism using runtime ... automatically exploiting cross-invocation parallelism using runtime ...
implemented in the Liberty parallelizing compiler infrastructure; second, each of its innerloop can be independently parallelized by a none-speculative and none partition-basedparallelization technique such as DOALL and LOCALWRITE; finally, the sequential codebetween two inner loops can be privatized and duplicated among all worker threads.After locating the candidate loops, SPECCROSS transformation is applied on each ofthem. SPECCROSS transformation consists of two major steps: first, we parallelize the hotloop by applying DOALL or LOCALWRITE to each inner loop and duplicate the sequentialcode among all worker threads; then SPECCROSS library function calls are inserted inthe parallel program to enable barrier speculation. Algorithm 5 demonstrates how thesefunction calls are inserted:1. A code region between two consecutive enter barrier functions is consideredas an epoch. For simplicity, each inner loop invocation is usually treated as an epoch.As a result, enter barrier functions are inserted at the beginning of each innerloop’s preheader basic block.2. Function enter task marks the beginning of each task. Since an inner loop iterationis usually treated as a separate task, enter task functions are inserted at thebeginning of each inner loop’s header.3. Function exit task is invoked at the end of each task. In other words, it is invokedbefore the execution exits an inner loop iteration or before the execution enters anotherinner loop iteration. Algorithm 5 (line 18-36) goes through each basic blockin an inner loop, checking its terminator instruction. If a terminator instruction is anunconditional branch which either exits the loop or branches back to the header ofthe loop, an exit task call is inserted right before the terminator instruction. If theterminator instruction is a conditional branch instruction and (1) if one of its targets isa basic block outside the loop and the other is the loop header, an exit task functionis also inserted before the terminator instruction; (2) if one target is a basic block70
outside the loop and the other is a basic block within the loop except the loop header,the exit task function is invoked only when the execution exits the loop; (3) ifone target is the header of the loop and the other is some other basic block within theloop, an exit task function is invoked only when the execution branches back tothe loop header.4. Function spec access is used to calculate the access signature for each task. Itis inserted before each memory operation (store or load) that is involved in a crossinvocationdependence (line 40-49).71
- Page 34 and 35: These techniques are referred to as
- Page 36 and 37: unnecessary overhead at runtime.Tab
- Page 38 and 39: Chapter 3Non-Speculatively Exploiti
- Page 40 and 41: for a variety of reasons. For insta
- Page 42 and 43: 12x11x10xDOMOREPthread Barrier9xLoo
- Page 44 and 45: Algorithm 1: Pseudo-code for schedu
- Page 46 and 47: Algorithm 2: Pseudo-code for worker
- Page 48 and 49: 3.3 Compiler ImplementationThe DOMO
- Page 50 and 51: to T i . DOMORE’s MTCG follows th
- Page 52 and 53: Outer_Preheaderbr BB1ABB1A:ind1 = P
- Page 54 and 55: Algorithm 3: Pseudo-code for genera
- Page 56 and 57: Scheduler Function SchedulerSync Fu
- Page 58 and 59: SchedulerWorker1 Worker2Worker3Work
- Page 60 and 61: 3.5 Related Work3.5.1 Cross-invocat
- Page 62 and 63: ations during the inspecting proces
- Page 64 and 65: for (t = 0; t < STEP; t++) {L1: for
- Page 66 and 67: sequential_func() {for (t = 0; t <
- Page 68 and 69: Workerthread 1Workerthread 2Workert
- Page 70 and 71: library provides efficient misspecu
- Page 72 and 73: Workerthread 1TimeFigure 4.6: Timin
- Page 74 and 75: 4.2 SPECCROSS Runtime System4.2.1 M
- Page 76 and 77: takes up to 200MB memory space.To d
- Page 78 and 79: checkpoint, the child spawns new wo
- Page 80 and 81: Operation DescriptionFunctions for
- Page 82 and 83: Main thread:main() {init();create_t
- Page 86 and 87: Algorithm 5: Pseudo-code for SPECCR
- Page 88 and 89: CROSS, since SPECCROSS can be appli
- Page 90 and 91: techniques.Synchronization via sche
- Page 92 and 93: Source Benchmark Function % of exec
- Page 94 and 95: applied to the outermost loop, gene
- Page 96 and 97: 5.2 SPECCROSS Performance Evaluatio
- Page 98 and 99: and the number of checking requests
- Page 100 and 101: 8x7xno misspec.with misspec.Geomean
- Page 102 and 103: This thesisPrevious workSpeedup (x)
- Page 104 and 105: Program Speedup6x5x4x3x2xLOCALWRITE
- Page 106 and 107: for DOMORE and SPECCROSS. Others (e
- Page 108 and 109: programs and it achieves a geomean
- Page 110 and 111: Bibliography[1] R. Allen and K. Ken
- Page 112 and 113: [15] R. Cytron. DOACROSS: Beyond ve
- Page 114 and 115: [31] T. B. Jablin, Y. Zhang, J. A.
- Page 116 and 117: [47] A. Nicolau, G. Li, A. V. Veide
- Page 118 and 119: [62] L. Rauchwerger and D. Padua. T
- Page 120: national conference on Parallel Arc
implemented in the Liberty parallelizing compiler infrastructure; second, each of its innerloop can be independently parallelized by a none-speculative and none partition-basedparallelization technique such as DOALL and LOCALWRITE; finally, the sequential codebetween two inner loops can be privatized and duplicated among all worker threads.After locating the candidate loops, SPECCROSS transformation is applied on each ofthem. SPECCROSS transformation consists of two major steps: first, we parallelize the hotloop by applying DOALL or LOCALWRITE to each inner loop and duplicate the sequentialcode among all worker threads; then SPECCROSS library function calls are inserted inthe parallel program to enable barrier speculation. Algorithm 5 demonstrates how thesefunction calls are inserted:1. A code region between two consecutive enter barrier functions is consideredas an epoch. For simplicity, each inner loop <strong>invocation</strong> is usually treated as an epoch.As a result, enter barrier functions are inserted at the beginning of each innerloop’s preheader basic block.2. Function enter task marks the beginning of each task. Since an inner loop iterationis usually treated as a separate task, enter task functions are inserted at thebeginning of each inner loop’s header.3. Function exit task is invoked at the end of each task. In other words, it is invokedbefore the execution exits an inner loop iteration or before the execution enters anotherinner loop iteration. Algorithm 5 (line 18-36) goes through each basic blockin an inner loop, checking its terminator instruction. If a terminator instruction is anunconditional branch which either exits the loop or branches back to the header ofthe loop, an exit task call is inserted right before the terminator instruction. If theterminator instruction is a conditional branch instruction and (1) if one of its targets isa basic block outside the loop and the other is the loop header, an exit task functionis also inserted before the terminator instruction; (2) if one target is a basic block70