How Processors work


© Shashank Nagaraja

A Central Processing Unit or CPU (or processor in general) is the brain of any computing device. They play a very vital role in our daily lives. They are tiny silicon made micro-circuits, which can be found in almost any modern device such as cars, home appliances, unmanned planes, missiles, cell-phones, etc.

How a CPU works

The function of a CPU is similar to that of a calculator, only much more complex and powerful. The CPU performs arithmetic and logical operations on data obtained from the memory or different input devices. The CPU functions as directed by a set of instructions called a program. A program is usually stored in a storage device such as floppy disk, hard disk, or a CD-ROM drive. The program is passed on to the main memory of the computer, which is known as the RAM or Random Access Memory after being read from the storage device. Here, each instruction is given a unique address in the memory so that, the CPU accesses the data it wants, by specifying the memory address of the data stored.

The data flows from the RAM to the CPU, upon execution, through an interface unit called memory bus, which connects the CPU and the RAM. A processing unit inside the CPU called the instruction decoder then decodes the data, before interpreting and implementing the software instructions. From the instruction decoder the data passes on to the Arithmetic Logic Unit (ALU), which performs the necessary calculations.

Frequently accessed data is stored in temporary memory locations called registers. Registers are special types of memory, which are located inside the CPU for faster access of frequently used data. They are faster than the system RAM. The absence of registers would slow down the CPU operations, as it would repeatedly have to go all the way to the main memory and search for the necessary instruction to carry out the specified operations. Different mathematical operations such as add, subtract, divide, multiply and other conditional tests are performed on the data, after which the results are stored back into the RAM for further use. A unit called the program counter is employed during this process, to keep track of each successive instruction, to make sure that the program instructions are followed by the CPU in the correct order.

Branching Instructions

During the execution of a program, the program counter advances sequentially through the instructions. However, sometimes it is required by the CPU to abruptly shift to an instruction location out of sequence. These branches could either be unconditional or conditional.  The difference between unconditional and conditional is that the former branch always accesses an out of order instruction stream, while the latter branch tests

Go To Page: 1 2


The copyright of the article How Processors work in Computer Processors is owned by . Permission to republish How Processors work in print or online must be granted by the author in writing.

Post this Article to facebook Add this Article to del.icio.us! Digg this Article furl this Article Add this Article to Reddit Add this Article to Technorati Add this Article to Newsvine Add this Article to Windows Live Add this Article to Yahoo Add this Article to StumbleUpon Add this Article to BlinkLists Add this Article to Spurl Add this Article to Google Add this Article to Ask Add this Article to Squidoo