-- Mar 23 In-Class Exercise
1. Each processor performs one step of computation with 2 map-reduce rounds, so we need 20 map-reduce rounds to simulate a 10-step PRAM computation.
2. To handle accumulators, we could reserve certain registers that can be read only by a particular processor and store any accumulated values of that processor in those registers.
3. To simulate the command LoadProcid k, we simply store the processor id in an accumulator k reserved to a particular processor.
4. In a given timestamp t, all PRAM processors are not doing the same instruction. Instead, the simulation uses a separate accumulator for each processor as a program counter to determine the current progress of the processor.
(
Edited: 2022-03-23)
1. Each processor performs one step of computation with 2 map-reduce rounds, so we need 20 map-reduce rounds to simulate a 10-step PRAM computation.
2. To handle accumulators, we could reserve certain registers that can be read only by a particular processor and store any accumulated values of that processor in those registers.
3. To simulate the command LoadProcid k, we simply store the processor id in an accumulator k reserved to a particular processor.
4. In a given timestamp t, all PRAM processors are not doing the same instruction. Instead, the simulation uses a separate accumulator for each processor as a program counter to determine the current progress of the processor.