Sunday, February 7, 2010

Week 5: Clear


The concept I found most interesting and most understandable during this week of Hardware lectures, was during the section on the Processor. The processor is constantly directing, organizing, receiving, interpreting, and initiating instructions. It makes sure that the correct sequence is carried out by the correct application. Instructions are cycled through the processor atleast a million times a second.

There are two ways to process this information; the first is similar to an assembly line for a vehicle. The parts are put into place and then moved down the row for the next pieces to be added on. The beginning operations are "dormant" while the next steps are taking place, which is extremly wasteful and inefficient. The second way is termed pipelining. With this process, the CPU is simultaneously working on 4 instructions. While the CPU is decoding instruction 1, it is fetching the information for instruction 2. When the first instruction is done, it can begin on instruction 5, as opposed to instruction 2. This is an extremely efficient process, increasing the performance of the system. There are even systems set up for if a decision needs to be made down the pipeline. There are 2 options for handling this situation. The first is to stall the pipeline, which would stop "fetching" new information until the decision has enough information to be made. Then the pipeline will continue with all instructions. The other is called branch predicting. The pipeline in this case follows through with one option, lets call it assumption A. If this was guessed correctly, the CPU keeps rolling along at full speed and the pipeline never stops working. If it guesses incorrectly and needs to perform assumption B, then it throws away the other, partially executed instructions, and follows assumption B. This process of pipelining is incredibly more productive than the simple assembly line approach.

If the concept is still unclear at all, the following website provides animations and graphics along with further explanations:

No comments:

Post a Comment