SlideShare a Scribd company logo
Dft1113 (COMPUTER ORGANIZATION)
CHAPTER 4:
THE CENTRAL PROCESSING UNIT
CENTRAL PROCESSING UNIT (CPU)
Introduction of Central Processing Unit (CPU)
– The part of computer that performs the bulk of data processing operations is called the
central processing unit (CPU).
– The CPU is made up of three major parts; Control, Register set and Arithmetic Logic Unit
(ALU) as shown in Figure 1.
• Register set – stores intermediate data used using execution of the instructions
• Arithmetic Logic Unit (ALU) – performs the required microoperations for executing
the instructions
• Control – supervises the transfer of information among the registers and instruct the
ALU as to which operation to perform.
Figure 1: Major components of CPU
Instruction cycle: Fetch cycle and Execute cycle
1 | P a g e
Lesson outcome:
1) Select appropriate hardware technical specification and software for maximum performance in
computer system.
2) Identify the current trends in computer architecture such as multiprocessor, vector, stack and
RISC.
Control
Register set
Arithmetic Logic
Unit (ALU)
Dft1113 (COMPUTER ORGANIZATION)
In computing, the two-phase cycle used by the computer's central processing unit to process
the instructions in a program is a fetch and execute cycle.
Figure 2: Computer Component; Top Level View
Figure 3: Fetch and execute cycle
Fetch Cycle
Program Counter (PC) holds address of next instruction to fetch
– Processor fetches instruction from memory location pointed to by PC
– Increment PC
• Unless told otherwise
– Instruction loaded into Instruction Register (IR)
– Processor interprets instruction and performs required actions
Execute Cycle
2 | P a g e
Dft1113 (COMPUTER ORGANIZATION)
Four categories of actions
1. Processor-memory
• data transfer between CPU and main memory
2. Processor I/O
• Data transfer between CPU and I/O module
3. Data processing
• Some arithmetic or logical operation on data
4. Control
• Alteration of sequence of operations (e.g. jump)
• Instruction execution may involve a combination of these
Basic Organization of Stack in Computer System
– Stack: A storage device that stores information in such a manner that the item stored last
is the first item retrieved. Also called last-in first-out (LIFO) list. It is useful for
compound arithmetic operations and nested subroutine calls.
– The stack in digital computers is a group of memory locations with a register that holds
the address of top of element. This register that holds the address of top of element of the
stack is called Stack Pointer.
– Stack Operations
The two operations of a stack are:
1. Push: Inserts an item on top of stack.
2. Pop : Deletes an item from top of stack.
– Implementation of Stack
In digital computers, stack can be implemented in two ways:
1. Register Stack
2. Memory Stack
3 | P a g e
Dft1113 (COMPUTER ORGANIZATION)
– Register Stack
• A stack can be organized as a collection of finite number of registers that are used
to store temporary information during the execution of a program. The stack
pointer (SP) is a register that holds the address of top of element of the stack.
– Memory Stack
• A stack can be implemented in a random access memory (RAM) attached to a
CPU. The implementation of a stack in the CPU is done by assigning a portion of
memory to a stack operation and using a processor register as a stack pointer. The
starting memory location of the stack is specified by the processor register
as stack pointer.
Reverse Polish Notation
– Reverse polish notation :is a postfix notation (places operators after operands)
– (Example)
Infix notation A + B
Reverse Polish notation AB+ also called postfix.
– A stack organization is very effective for evaluating arithmetic expressions
• A * B + C * D → (AB *)+(CD *) → AB * CD * +
• ( 3 * 4 ) + ( 5 * 6 ) → 34 * 56 * +
– Evaluation procedure:
1. Scan the expression from left to right.
2. When an operator is reached, perform the operation with the two operands found on
the left side of the operator.
Replace the two operands and the operator by the result obtained from the operation.
3. (Example)
infix 3 * 4 + 5 * 6 = 42
postfix 3 4 * 5 6 * +
12 5 6 * +
12 30 +
42
– Reverse Polish notation evaluation with a stack. Stack is the most efficient way for
evaluating arithmetic expressions.
4 | P a g e
Stack evaluation:
Get value
If value is data: push data
Else if value is operation: pop, pop evaluate and push.
Dft1113 (COMPUTER ORGANIZATION)
– (Example) using stacks to do this.
3 * 4 + 5 * 6 = 42
=> 3 4 * 5 6 * +
Reduced Instruction Set Computer (RISC) and Complex Instruction Set
Computers (CISC)
Complex Instruction Set Computers (CISC) has a large instruction set, with hardware
support for a wide variety of operations. In scientific, engineering, and mathematical
operations with hand coded assembly language (and some business applications with hand
coded assembly language), CISC processors usually perform the most work in the shortest
time.
Reduced Instruction Set Computers (RISC) has a small, compact instruction set. In most
business applications and in programs created by compilers from high level language source,
RISC processors usually perform the most work in the shortest time.
RISC architecture
The first prototype computer to use reduced instruction set computer (RISC) architecture was
designed by IBM researcher John Cocke and his team in the late 1970s. For his efforts, Cocke
received the Turing Award in 1987, the US National Medal of Science in 1994, and the US
National Medal of Technology in 1991.
5 | P a g e
Dft1113 (COMPUTER ORGANIZATION)
IBM RT PC
The RISC Technology Personal Computer (RT PC) was introduced in 1986, and featured the
32-bit RISC architecture.
IBM RS/6000
The IBM RS/6000 was released in 1990. It was the first machine to feature the IBM POWER
architecture. The RS/6000 has gone through several name changes throughout the years,
including IBM eServer™ pSeries®, IBM System p® and IBM Power Systems™.
The differences between RISC and CISC
Reduced Instruction Set Computer
(RISC)
Complex Instruction Set Computer
(CISC)
• Reduced instruction set. • Extensive instructions.
• Less complex, simple instructions. • Complex and efficient machine
instructions.
• Single word instruction • Variable length istruction
• Hardwired control unit and machine
instructions.
• Microencoding of the machine
instructions.
• Few addressing schemes for memory
operands with only two basic
instructions, LOAD and STORE
• Extensive addressing capabilities for
memory operations.
• Many symmetric registers which
are organized into a register file.
• Relatively few registers.
• Simple operations • Complex operations
6 | P a g e
Dft1113 (COMPUTER ORGANIZATION)
Concept of Pipelining
A technique used in advanced microprocessors where the microprocessor
begins executing a second instruction before the first has been completed (instruction pre-
fetch). That is, several instructions are in the pipeline simultaneously, each at a different
processing stage.
The pipeline is divided into segments and each segment can execute its operation
concurrently with the other segments. When a segment completes an operation, it passes the
result to the next segment in the pipeline and fetches the next operation from the preceding
segment. The final results of each instruction emerge at the end of the pipeline in rapid
succession.
Although formerly a feature only of high-performance and RISC -based microprocessors,
pipelining is now common in microprocessors used in personal computers. Intel's
Pentium chip, for example, uses pipelining to execute as many as six instructions
simultaneously.
Pipelining is also called pipeline processing.
7 | P a g e

More Related Content

What's hot

Real Time Operating Systems
Real Time Operating SystemsReal Time Operating Systems
Real Time Operating Systems
Pawandeep Kaur
 
INTERCONNECTION STRUCTURE
INTERCONNECTION STRUCTUREINTERCONNECTION STRUCTURE
INTERCONNECTION STRUCTURE
VENNILAV6
 
Ch1 internet Networks
Ch1 internet NetworksCh1 internet Networks
Ch1 internet Networks
cairo university
 
Ipv4 ppt
Ipv4 pptIpv4 ppt
Ipv4 ppt
Sonal Chandel
 
Computer network basics
Computer network basicsComputer network basics
Computer network basics
JAI MCA-STUDENT
 
Process Scheduling
Process SchedulingProcess Scheduling
Process scheduling (CPU Scheduling)
Process scheduling (CPU Scheduling)Process scheduling (CPU Scheduling)
Process scheduling (CPU Scheduling)
Mukesh Chinta
 
Assembly Language Programming By Ytha Yu, Charles Marut Chap 4 (Introduction ...
Assembly Language Programming By Ytha Yu, Charles Marut Chap 4 (Introduction ...Assembly Language Programming By Ytha Yu, Charles Marut Chap 4 (Introduction ...
Assembly Language Programming By Ytha Yu, Charles Marut Chap 4 (Introduction ...
Bilal Amjad
 
Comparision of scheduling algorithms
Comparision of scheduling algorithmsComparision of scheduling algorithms
Comparision of scheduling algorithms
Tanya Makkar
 
Fpga & VHDL
Fpga & VHDLFpga & VHDL
Fpga & VHDL
Francesco De Canio
 
Cara membongkar laptop
Cara membongkar laptopCara membongkar laptop
Cara membongkar laptop
Stevany Stevany
 
Ch 20 UNICAST ROUTING SECTION 2
Ch 20   UNICAST ROUTING  SECTION  2Ch 20   UNICAST ROUTING  SECTION  2
Ch 20 UNICAST ROUTING SECTION 2
Hossam El-Deen Osama
 
Multithreading computer architecture
 Multithreading computer architecture  Multithreading computer architecture
Multithreading computer architecture
Haris456
 
Class work 7,computer_network_317
Class work 7,computer_network_317Class work 7,computer_network_317
Class work 7,computer_network_317
Khondoker Sadia
 
protocol architecture
 protocol architecture protocol architecture
protocol architecture
Srinivasa Rao
 
Assembly Language and microprocessor
Assembly Language and microprocessorAssembly Language and microprocessor
Assembly Language and microprocessor
Khaled Sany
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 
Unit7 & 8 performance analysis and optimization
Unit7 & 8 performance analysis and optimizationUnit7 & 8 performance analysis and optimization
Unit7 & 8 performance analysis and optimization
leenachandra
 

What's hot (20)

Real Time Operating Systems
Real Time Operating SystemsReal Time Operating Systems
Real Time Operating Systems
 
INTERCONNECTION STRUCTURE
INTERCONNECTION STRUCTUREINTERCONNECTION STRUCTURE
INTERCONNECTION STRUCTURE
 
Ch1 internet Networks
Ch1 internet NetworksCh1 internet Networks
Ch1 internet Networks
 
Ipv4 ppt
Ipv4 pptIpv4 ppt
Ipv4 ppt
 
Computer network basics
Computer network basicsComputer network basics
Computer network basics
 
Process Scheduling
Process SchedulingProcess Scheduling
Process Scheduling
 
Process scheduling (CPU Scheduling)
Process scheduling (CPU Scheduling)Process scheduling (CPU Scheduling)
Process scheduling (CPU Scheduling)
 
Assembly Language Programming By Ytha Yu, Charles Marut Chap 4 (Introduction ...
Assembly Language Programming By Ytha Yu, Charles Marut Chap 4 (Introduction ...Assembly Language Programming By Ytha Yu, Charles Marut Chap 4 (Introduction ...
Assembly Language Programming By Ytha Yu, Charles Marut Chap 4 (Introduction ...
 
Comparision of scheduling algorithms
Comparision of scheduling algorithmsComparision of scheduling algorithms
Comparision of scheduling algorithms
 
Fpga & VHDL
Fpga & VHDLFpga & VHDL
Fpga & VHDL
 
Cara membongkar laptop
Cara membongkar laptopCara membongkar laptop
Cara membongkar laptop
 
Ch 20 UNICAST ROUTING SECTION 2
Ch 20   UNICAST ROUTING  SECTION  2Ch 20   UNICAST ROUTING  SECTION  2
Ch 20 UNICAST ROUTING SECTION 2
 
Ethernet Frames Explained
Ethernet Frames ExplainedEthernet Frames Explained
Ethernet Frames Explained
 
Multithreading computer architecture
 Multithreading computer architecture  Multithreading computer architecture
Multithreading computer architecture
 
Class work 7,computer_network_317
Class work 7,computer_network_317Class work 7,computer_network_317
Class work 7,computer_network_317
 
protocol architecture
 protocol architecture protocol architecture
protocol architecture
 
Assembly Language and microprocessor
Assembly Language and microprocessorAssembly Language and microprocessor
Assembly Language and microprocessor
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
Unit7 & 8 performance analysis and optimization
Unit7 & 8 performance analysis and optimizationUnit7 & 8 performance analysis and optimization
Unit7 & 8 performance analysis and optimization
 
Data transferschemes
Data transferschemesData transferschemes
Data transferschemes
 

Similar to POLITEKNIK MALAYSIA

isa architecture
isa architectureisa architecture
isa architecture
AJAL A J
 
module 1 computer architecture diploma
 module 1 computer architecture diploma   module 1 computer architecture diploma
module 1 computer architecture diploma
Manoharan Ragavan
 
Computer Organization : CPU, Memory and I/O organization
Computer Organization : CPU, Memory and I/O organizationComputer Organization : CPU, Memory and I/O organization
Computer Organization : CPU, Memory and I/O organization
AmrutaMehata
 
UNIT 3 - General Purpose Processors
UNIT 3 - General Purpose ProcessorsUNIT 3 - General Purpose Processors
UNIT 3 - General Purpose Processors
ButtaRajasekhar2
 
unit 1ARM INTRODUCTION.pptx
unit 1ARM INTRODUCTION.pptxunit 1ARM INTRODUCTION.pptx
unit 1ARM INTRODUCTION.pptx
KandavelEee
 
Bca 2nd sem-u-1.2 digital logic circuits, digital component
Bca 2nd sem-u-1.2 digital logic circuits, digital componentBca 2nd sem-u-1.2 digital logic circuits, digital component
Bca 2nd sem-u-1.2 digital logic circuits, digital component
Rai University
 
Instruction Set Architecture
Instruction Set ArchitectureInstruction Set Architecture
Instruction Set Architecture
Jaffer Haadi
 
B.sc cs-ii -u-1.2 digital logic circuits, digital component
B.sc cs-ii -u-1.2 digital logic circuits, digital componentB.sc cs-ii -u-1.2 digital logic circuits, digital component
B.sc cs-ii -u-1.2 digital logic circuits, digital component
Rai University
 
conrol_Unit_part_of_computer_architecture.pptx
conrol_Unit_part_of_computer_architecture.pptxconrol_Unit_part_of_computer_architecture.pptx
conrol_Unit_part_of_computer_architecture.pptx
jbri1395
 
Microchip's PIC Micro Controller
Microchip's PIC Micro ControllerMicrochip's PIC Micro Controller
Microchip's PIC Micro Controller
Midhu S V Unnithan
 
Basic structure of computers by aniket bhute
Basic structure of computers by aniket bhuteBasic structure of computers by aniket bhute
Basic structure of computers by aniket bhute
Aniket Bhute
 
Pipeline Computing by S. M. Risalat Hasan Chowdhury
Pipeline Computing by S. M. Risalat Hasan ChowdhuryPipeline Computing by S. M. Risalat Hasan Chowdhury
Pipeline Computing by S. M. Risalat Hasan Chowdhury
S. M. Risalat Hasan Chowdhury
 
Presentation on risc pipeline
Presentation on risc pipelinePresentation on risc pipeline
Presentation on risc pipeline
Arijit Chakraborty
 
Beneath the Linux Interrupt handling
Beneath the Linux Interrupt handlingBeneath the Linux Interrupt handling
Beneath the Linux Interrupt handling
Bhoomil Chavda
 
22CS201 COA
22CS201 COA22CS201 COA
22CS201 COA
Kathirvel Ayyaswamy
 
Ch01 .pptssysueueueueu65egegeg3f3geye6d6yeueu
Ch01 .pptssysueueueueu65egegeg3f3geye6d6yeueuCh01 .pptssysueueueueu65egegeg3f3geye6d6yeueu
Ch01 .pptssysueueueueu65egegeg3f3geye6d6yeueu
tasheebedane
 
DSP Processor.pptx
DSP Processor.pptxDSP Processor.pptx
DSP Processor.pptx
AswathSelvaraj
 
CAO.pptx
CAO.pptxCAO.pptx
CAO.pptx
FarhanaMariyam1
 

Similar to POLITEKNIK MALAYSIA (20)

isa architecture
isa architectureisa architecture
isa architecture
 
module 1 computer architecture diploma
 module 1 computer architecture diploma   module 1 computer architecture diploma
module 1 computer architecture diploma
 
Computer Organization : CPU, Memory and I/O organization
Computer Organization : CPU, Memory and I/O organizationComputer Organization : CPU, Memory and I/O organization
Computer Organization : CPU, Memory and I/O organization
 
UNIT 3 - General Purpose Processors
UNIT 3 - General Purpose ProcessorsUNIT 3 - General Purpose Processors
UNIT 3 - General Purpose Processors
 
CSC204PPTNOTES
CSC204PPTNOTESCSC204PPTNOTES
CSC204PPTNOTES
 
unit 1ARM INTRODUCTION.pptx
unit 1ARM INTRODUCTION.pptxunit 1ARM INTRODUCTION.pptx
unit 1ARM INTRODUCTION.pptx
 
Bca 2nd sem-u-1.2 digital logic circuits, digital component
Bca 2nd sem-u-1.2 digital logic circuits, digital componentBca 2nd sem-u-1.2 digital logic circuits, digital component
Bca 2nd sem-u-1.2 digital logic circuits, digital component
 
Instruction Set Architecture
Instruction Set ArchitectureInstruction Set Architecture
Instruction Set Architecture
 
B.sc cs-ii -u-1.2 digital logic circuits, digital component
B.sc cs-ii -u-1.2 digital logic circuits, digital componentB.sc cs-ii -u-1.2 digital logic circuits, digital component
B.sc cs-ii -u-1.2 digital logic circuits, digital component
 
conrol_Unit_part_of_computer_architecture.pptx
conrol_Unit_part_of_computer_architecture.pptxconrol_Unit_part_of_computer_architecture.pptx
conrol_Unit_part_of_computer_architecture.pptx
 
Microchip's PIC Micro Controller
Microchip's PIC Micro ControllerMicrochip's PIC Micro Controller
Microchip's PIC Micro Controller
 
Basic structure of computers by aniket bhute
Basic structure of computers by aniket bhuteBasic structure of computers by aniket bhute
Basic structure of computers by aniket bhute
 
Pipeline Computing by S. M. Risalat Hasan Chowdhury
Pipeline Computing by S. M. Risalat Hasan ChowdhuryPipeline Computing by S. M. Risalat Hasan Chowdhury
Pipeline Computing by S. M. Risalat Hasan Chowdhury
 
Presentation on risc pipeline
Presentation on risc pipelinePresentation on risc pipeline
Presentation on risc pipeline
 
Beneath the Linux Interrupt handling
Beneath the Linux Interrupt handlingBeneath the Linux Interrupt handling
Beneath the Linux Interrupt handling
 
abc
abcabc
abc
 
22CS201 COA
22CS201 COA22CS201 COA
22CS201 COA
 
Ch01 .pptssysueueueueu65egegeg3f3geye6d6yeueu
Ch01 .pptssysueueueueu65egegeg3f3geye6d6yeueuCh01 .pptssysueueueueu65egegeg3f3geye6d6yeueu
Ch01 .pptssysueueueueu65egegeg3f3geye6d6yeueu
 
DSP Processor.pptx
DSP Processor.pptxDSP Processor.pptx
DSP Processor.pptx
 
CAO.pptx
CAO.pptxCAO.pptx
CAO.pptx
 

More from Aiman Hud

POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
Aiman Hud
 

More from Aiman Hud (20)

POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 
POLITEKNIK MALAYSIA
POLITEKNIK MALAYSIAPOLITEKNIK MALAYSIA
POLITEKNIK MALAYSIA
 

Recently uploaded

一比一原版(IIT毕业证)伊利诺伊理工大学毕业证如何办理
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证如何办理一比一原版(IIT毕业证)伊利诺伊理工大学毕业证如何办理
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证如何办理
aozcue
 
一比一原版(UMich毕业证)密歇根大学|安娜堡分校毕业证如何办理
一比一原版(UMich毕业证)密歇根大学|安娜堡分校毕业证如何办理一比一原版(UMich毕业证)密歇根大学|安娜堡分校毕业证如何办理
一比一原版(UMich毕业证)密歇根大学|安娜堡分校毕业证如何办理
peuce
 
欧洲杯冠军-欧洲杯冠军网站-欧洲杯冠军|【​网址​🎉ac123.net🎉​】领先全球的买球投注平台
欧洲杯冠军-欧洲杯冠军网站-欧洲杯冠军|【​网址​🎉ac123.net🎉​】领先全球的买球投注平台欧洲杯冠军-欧洲杯冠军网站-欧洲杯冠军|【​网址​🎉ac123.net🎉​】领先全球的买球投注平台
欧洲杯冠军-欧洲杯冠军网站-欧洲杯冠军|【​网址​🎉ac123.net🎉​】领先全球的买球投注平台
andreassenrolf537
 
web-tech-lab-manual-final-abhas.pdf. Jer
web-tech-lab-manual-final-abhas.pdf. Jerweb-tech-lab-manual-final-abhas.pdf. Jer
web-tech-lab-manual-final-abhas.pdf. Jer
freshgammer09
 
MATHEMATICS BRIDGE COURSE (TEN DAYS PLANNER) (FOR CLASS XI STUDENTS GOING TO ...
MATHEMATICS BRIDGE COURSE (TEN DAYS PLANNER) (FOR CLASS XI STUDENTS GOING TO ...MATHEMATICS BRIDGE COURSE (TEN DAYS PLANNER) (FOR CLASS XI STUDENTS GOING TO ...
MATHEMATICS BRIDGE COURSE (TEN DAYS PLANNER) (FOR CLASS XI STUDENTS GOING TO ...
PinkySharma900491
 
一比一原版(UCSB毕业证)圣塔芭芭拉社区大学毕业证如何办理
一比一原版(UCSB毕业证)圣塔芭芭拉社区大学毕业证如何办理一比一原版(UCSB毕业证)圣塔芭芭拉社区大学毕业证如何办理
一比一原版(UCSB毕业证)圣塔芭芭拉社区大学毕业证如何办理
aozcue
 
Building a Raspberry Pi Robot with Dot NET 8, Blazor and SignalR - Slides Onl...
Building a Raspberry Pi Robot with Dot NET 8, Blazor and SignalR - Slides Onl...Building a Raspberry Pi Robot with Dot NET 8, Blazor and SignalR - Slides Onl...
Building a Raspberry Pi Robot with Dot NET 8, Blazor and SignalR - Slides Onl...
Peter Gallagher
 

Recently uploaded (7)

一比一原版(IIT毕业证)伊利诺伊理工大学毕业证如何办理
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证如何办理一比一原版(IIT毕业证)伊利诺伊理工大学毕业证如何办理
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证如何办理
 
一比一原版(UMich毕业证)密歇根大学|安娜堡分校毕业证如何办理
一比一原版(UMich毕业证)密歇根大学|安娜堡分校毕业证如何办理一比一原版(UMich毕业证)密歇根大学|安娜堡分校毕业证如何办理
一比一原版(UMich毕业证)密歇根大学|安娜堡分校毕业证如何办理
 
欧洲杯冠军-欧洲杯冠军网站-欧洲杯冠军|【​网址​🎉ac123.net🎉​】领先全球的买球投注平台
欧洲杯冠军-欧洲杯冠军网站-欧洲杯冠军|【​网址​🎉ac123.net🎉​】领先全球的买球投注平台欧洲杯冠军-欧洲杯冠军网站-欧洲杯冠军|【​网址​🎉ac123.net🎉​】领先全球的买球投注平台
欧洲杯冠军-欧洲杯冠军网站-欧洲杯冠军|【​网址​🎉ac123.net🎉​】领先全球的买球投注平台
 
web-tech-lab-manual-final-abhas.pdf. Jer
web-tech-lab-manual-final-abhas.pdf. Jerweb-tech-lab-manual-final-abhas.pdf. Jer
web-tech-lab-manual-final-abhas.pdf. Jer
 
MATHEMATICS BRIDGE COURSE (TEN DAYS PLANNER) (FOR CLASS XI STUDENTS GOING TO ...
MATHEMATICS BRIDGE COURSE (TEN DAYS PLANNER) (FOR CLASS XI STUDENTS GOING TO ...MATHEMATICS BRIDGE COURSE (TEN DAYS PLANNER) (FOR CLASS XI STUDENTS GOING TO ...
MATHEMATICS BRIDGE COURSE (TEN DAYS PLANNER) (FOR CLASS XI STUDENTS GOING TO ...
 
一比一原版(UCSB毕业证)圣塔芭芭拉社区大学毕业证如何办理
一比一原版(UCSB毕业证)圣塔芭芭拉社区大学毕业证如何办理一比一原版(UCSB毕业证)圣塔芭芭拉社区大学毕业证如何办理
一比一原版(UCSB毕业证)圣塔芭芭拉社区大学毕业证如何办理
 
Building a Raspberry Pi Robot with Dot NET 8, Blazor and SignalR - Slides Onl...
Building a Raspberry Pi Robot with Dot NET 8, Blazor and SignalR - Slides Onl...Building a Raspberry Pi Robot with Dot NET 8, Blazor and SignalR - Slides Onl...
Building a Raspberry Pi Robot with Dot NET 8, Blazor and SignalR - Slides Onl...
 

POLITEKNIK MALAYSIA

  • 1. Dft1113 (COMPUTER ORGANIZATION) CHAPTER 4: THE CENTRAL PROCESSING UNIT CENTRAL PROCESSING UNIT (CPU) Introduction of Central Processing Unit (CPU) – The part of computer that performs the bulk of data processing operations is called the central processing unit (CPU). – The CPU is made up of three major parts; Control, Register set and Arithmetic Logic Unit (ALU) as shown in Figure 1. • Register set – stores intermediate data used using execution of the instructions • Arithmetic Logic Unit (ALU) – performs the required microoperations for executing the instructions • Control – supervises the transfer of information among the registers and instruct the ALU as to which operation to perform. Figure 1: Major components of CPU Instruction cycle: Fetch cycle and Execute cycle 1 | P a g e Lesson outcome: 1) Select appropriate hardware technical specification and software for maximum performance in computer system. 2) Identify the current trends in computer architecture such as multiprocessor, vector, stack and RISC. Control Register set Arithmetic Logic Unit (ALU)
  • 2. Dft1113 (COMPUTER ORGANIZATION) In computing, the two-phase cycle used by the computer's central processing unit to process the instructions in a program is a fetch and execute cycle. Figure 2: Computer Component; Top Level View Figure 3: Fetch and execute cycle Fetch Cycle Program Counter (PC) holds address of next instruction to fetch – Processor fetches instruction from memory location pointed to by PC – Increment PC • Unless told otherwise – Instruction loaded into Instruction Register (IR) – Processor interprets instruction and performs required actions Execute Cycle 2 | P a g e
  • 3. Dft1113 (COMPUTER ORGANIZATION) Four categories of actions 1. Processor-memory • data transfer between CPU and main memory 2. Processor I/O • Data transfer between CPU and I/O module 3. Data processing • Some arithmetic or logical operation on data 4. Control • Alteration of sequence of operations (e.g. jump) • Instruction execution may involve a combination of these Basic Organization of Stack in Computer System – Stack: A storage device that stores information in such a manner that the item stored last is the first item retrieved. Also called last-in first-out (LIFO) list. It is useful for compound arithmetic operations and nested subroutine calls. – The stack in digital computers is a group of memory locations with a register that holds the address of top of element. This register that holds the address of top of element of the stack is called Stack Pointer. – Stack Operations The two operations of a stack are: 1. Push: Inserts an item on top of stack. 2. Pop : Deletes an item from top of stack. – Implementation of Stack In digital computers, stack can be implemented in two ways: 1. Register Stack 2. Memory Stack 3 | P a g e
  • 4. Dft1113 (COMPUTER ORGANIZATION) – Register Stack • A stack can be organized as a collection of finite number of registers that are used to store temporary information during the execution of a program. The stack pointer (SP) is a register that holds the address of top of element of the stack. – Memory Stack • A stack can be implemented in a random access memory (RAM) attached to a CPU. The implementation of a stack in the CPU is done by assigning a portion of memory to a stack operation and using a processor register as a stack pointer. The starting memory location of the stack is specified by the processor register as stack pointer. Reverse Polish Notation – Reverse polish notation :is a postfix notation (places operators after operands) – (Example) Infix notation A + B Reverse Polish notation AB+ also called postfix. – A stack organization is very effective for evaluating arithmetic expressions • A * B + C * D → (AB *)+(CD *) → AB * CD * + • ( 3 * 4 ) + ( 5 * 6 ) → 34 * 56 * + – Evaluation procedure: 1. Scan the expression from left to right. 2. When an operator is reached, perform the operation with the two operands found on the left side of the operator. Replace the two operands and the operator by the result obtained from the operation. 3. (Example) infix 3 * 4 + 5 * 6 = 42 postfix 3 4 * 5 6 * + 12 5 6 * + 12 30 + 42 – Reverse Polish notation evaluation with a stack. Stack is the most efficient way for evaluating arithmetic expressions. 4 | P a g e Stack evaluation: Get value If value is data: push data Else if value is operation: pop, pop evaluate and push.
  • 5. Dft1113 (COMPUTER ORGANIZATION) – (Example) using stacks to do this. 3 * 4 + 5 * 6 = 42 => 3 4 * 5 6 * + Reduced Instruction Set Computer (RISC) and Complex Instruction Set Computers (CISC) Complex Instruction Set Computers (CISC) has a large instruction set, with hardware support for a wide variety of operations. In scientific, engineering, and mathematical operations with hand coded assembly language (and some business applications with hand coded assembly language), CISC processors usually perform the most work in the shortest time. Reduced Instruction Set Computers (RISC) has a small, compact instruction set. In most business applications and in programs created by compilers from high level language source, RISC processors usually perform the most work in the shortest time. RISC architecture The first prototype computer to use reduced instruction set computer (RISC) architecture was designed by IBM researcher John Cocke and his team in the late 1970s. For his efforts, Cocke received the Turing Award in 1987, the US National Medal of Science in 1994, and the US National Medal of Technology in 1991. 5 | P a g e
  • 6. Dft1113 (COMPUTER ORGANIZATION) IBM RT PC The RISC Technology Personal Computer (RT PC) was introduced in 1986, and featured the 32-bit RISC architecture. IBM RS/6000 The IBM RS/6000 was released in 1990. It was the first machine to feature the IBM POWER architecture. The RS/6000 has gone through several name changes throughout the years, including IBM eServer™ pSeries®, IBM System p® and IBM Power Systems™. The differences between RISC and CISC Reduced Instruction Set Computer (RISC) Complex Instruction Set Computer (CISC) • Reduced instruction set. • Extensive instructions. • Less complex, simple instructions. • Complex and efficient machine instructions. • Single word instruction • Variable length istruction • Hardwired control unit and machine instructions. • Microencoding of the machine instructions. • Few addressing schemes for memory operands with only two basic instructions, LOAD and STORE • Extensive addressing capabilities for memory operations. • Many symmetric registers which are organized into a register file. • Relatively few registers. • Simple operations • Complex operations 6 | P a g e
  • 7. Dft1113 (COMPUTER ORGANIZATION) Concept of Pipelining A technique used in advanced microprocessors where the microprocessor begins executing a second instruction before the first has been completed (instruction pre- fetch). That is, several instructions are in the pipeline simultaneously, each at a different processing stage. The pipeline is divided into segments and each segment can execute its operation concurrently with the other segments. When a segment completes an operation, it passes the result to the next segment in the pipeline and fetches the next operation from the preceding segment. The final results of each instruction emerge at the end of the pipeline in rapid succession. Although formerly a feature only of high-performance and RISC -based microprocessors, pipelining is now common in microprocessors used in personal computers. Intel's Pentium chip, for example, uses pipelining to execute as many as six instructions simultaneously. Pipelining is also called pipeline processing. 7 | P a g e