SlideShare a Scribd company logo
1 of 9
Download to read offline
12/14/2014
1
Computer Organization
Instructors :
Dr. Abdul Raouf Khan
Mr.Marwan El-Haj
Central Processing Unit
The Central Processing Unit is made of three
major parts, as shown below.
Control
Arithmetic
Logic Unit
(ALU)
Register Set
12/14/2014
2
Central Processing Unit
The register set stores intermediate data
used during the execution of the instructions.
ALU performs the required microoperation
for executing the instruction.
The control unit supervises the transfer of
information among the registers and instructs
the ALU as to which instruction to perform
Central Processing Unit
Computer architecture is sometimes defined
as the computer structure and behavior as
seen by programmer that uses machine
language instructions. This include the
instruction formats, addressing modes, the
instruction set, and the general organization
of the CPU registers.
12/14/2014
3
General Register Organization
Referring Memory repeatedly is time consuming
Intermediate values can be stored in registers
large number of registers are included in CPU,
connected through bus
Registers can communicate with each other
A bus organization for seven registers is shown
next
12/14/2014
4
General Register Organization
The control Unit directs the operations e.g.
To perform R1 R2+R3
1. MUX A selector (SELA): to place the contents of R2
into bus A
2. MUX B selector (SELB): to place the contents of R3
into bus B
3. ALU operation selector (OPR): to provide arithmetic
addition A+B
4. Decoder destination selector (SELD): to transfer the
content of the output bus into R1.
Stack Organization
Stack is a storage device (memory) that
stores information in such a manner that the
items stored last is retrieved first. Also known
as LIFO (Last-In-First-Out)
The register that holds the address of the top
of the stack is called Stack Pointer (SP).
The two operations of stack are insertion and
deletion of items known as PUSH & POP.
12/14/2014
5
Push operation
1. If (Full=0)Then ‘Check Stack Not Full
1. Begin
2. SP SP + 1 ‘Increment stack pointer
3. M[SP] DR ‘write on top of stack
4. If (SP=0) then FULL 1 ‘Check if stack is full
5. EMPTY 0 ‘Mark the stack not empty
6. End
12/14/2014
6
POP Operation
1. If (Empty=0)Then ‘Check if Stack not Empty
1. Begin
2. DR M[SP] ‘Read from top of stack
3. SP SP-1 ‘Decrement stack pointer
4. If (SP=0) then EMPTY 1 ‘Check if stack is empty
5. FULL 0 ‘Mark the stack not Full
6. End
Memory Stack
A stack can exist as a stand-alone unit as
shown above or can be implemented in a
random access memory attached to CPU.
The implementation of a stack in the CPU is
done by assigning a portion of memory to
stack operation and using a processor
register as stack pointer.
See figure next
12/14/2014
7
Reverse Polish Notation
A stack operation is very effective in
evaluating arithmetic expressions.
Infix Notation A + B
Prefix or polish Notation + AB
Postfix or reverse polish notation AB+
Reverse polish notation is in a form suitable
for stack manipulation
12/14/2014
8
Examples
Infix (A * B) + (C * D)
Postfix AB * CD * +
Infix (A+B) * [C * (D + E) + F]
Postfix AB + DE + C * F + *
Evaluation of arithmetic expression
First Arithmetic expression is converted to
reverse polish notation
Operands are pushed into the stack in the
order of appearance
Two topmost operands in the stack are used
for operation
The stack is popped & the result of the
operation replaces the lower operand
The expression is evaluated in this order &
final result remains in the top of stack
12/14/2014
9
Example ( 3*4)+(5*6) = 34*56*+
3 4 * 5 6 * +
3
4
3 12
5
12 42
30
12
6
5
12

More Related Content

What's hot

Register introduction
Register introductionRegister introduction
Register introductionmaamir farooq
 
System Programming- Unit I
System Programming- Unit ISystem Programming- Unit I
System Programming- Unit ISaranya1702
 
Data Manipulation
Data ManipulationData Manipulation
Data ManipulationAsfi Bhai
 
Processor organization & register organization
Processor organization & register organizationProcessor organization & register organization
Processor organization & register organizationGhanshyam Patel
 
Csa stack
Csa stackCsa stack
Csa stackPCTE
 
Flag registers (assembly language) with types and examples
Flag registers (assembly language) with types and examplesFlag registers (assembly language) with types and examples
Flag registers (assembly language) with types and examplesComputer_ at_home
 
Computer organization basics
Computer organization  basicsComputer organization  basics
Computer organization basicsDeepak John
 
Central processing unit
Central processing unitCentral processing unit
Central processing unitKumar
 
Process & Mutlithreading
Process & MutlithreadingProcess & Mutlithreading
Process & MutlithreadingRahul Jamwal
 
Assembly Language Basics
Assembly Language BasicsAssembly Language Basics
Assembly Language BasicsEducation Front
 
Datapath Design of Computer Architecture
Datapath Design of Computer ArchitectureDatapath Design of Computer Architecture
Datapath Design of Computer ArchitectureAbu Zaman
 
Addressing modes/Addressing Mode with illustration/ Addressing mode in 8086
Addressing modes/Addressing Mode with illustration/ Addressing mode in 8086Addressing modes/Addressing Mode with illustration/ Addressing mode in 8086
Addressing modes/Addressing Mode with illustration/ Addressing mode in 8086samirbharat77
 
C++ Memory Management
C++ Memory ManagementC++ Memory Management
C++ Memory ManagementRahul Jamwal
 

What's hot (20)

Register introduction
Register introductionRegister introduction
Register introduction
 
System Programming- Unit I
System Programming- Unit ISystem Programming- Unit I
System Programming- Unit I
 
Lecture 23
Lecture 23Lecture 23
Lecture 23
 
Data Manipulation
Data ManipulationData Manipulation
Data Manipulation
 
Processor organization & register organization
Processor organization & register organizationProcessor organization & register organization
Processor organization & register organization
 
Cpu organisation
Cpu organisationCpu organisation
Cpu organisation
 
Csa stack
Csa stackCsa stack
Csa stack
 
Flag registers (assembly language) with types and examples
Flag registers (assembly language) with types and examplesFlag registers (assembly language) with types and examples
Flag registers (assembly language) with types and examples
 
Computer organization basics
Computer organization  basicsComputer organization  basics
Computer organization basics
 
Chapter 1
Chapter 1Chapter 1
Chapter 1
 
Central processing unit
Central processing unitCentral processing unit
Central processing unit
 
Chapter 10
Chapter 10Chapter 10
Chapter 10
 
Process & Mutlithreading
Process & MutlithreadingProcess & Mutlithreading
Process & Mutlithreading
 
Assembly Language Basics
Assembly Language BasicsAssembly Language Basics
Assembly Language Basics
 
INSTRUCTION SET
INSTRUCTION SETINSTRUCTION SET
INSTRUCTION SET
 
Datapath Design of Computer Architecture
Datapath Design of Computer ArchitectureDatapath Design of Computer Architecture
Datapath Design of Computer Architecture
 
Addressing modes/Addressing Mode with illustration/ Addressing mode in 8086
Addressing modes/Addressing Mode with illustration/ Addressing mode in 8086Addressing modes/Addressing Mode with illustration/ Addressing mode in 8086
Addressing modes/Addressing Mode with illustration/ Addressing mode in 8086
 
addressing modes
addressing modesaddressing modes
addressing modes
 
C++ Memory Management
C++ Memory ManagementC++ Memory Management
C++ Memory Management
 
Hennchthree
HennchthreeHennchthree
Hennchthree
 

Viewers also liked (20)

2-bit comparator
2-bit comparator2-bit comparator
2-bit comparator
 
Basic computer organization
Basic computer organizationBasic computer organization
Basic computer organization
 
Basic MIPS implementation
Basic MIPS implementationBasic MIPS implementation
Basic MIPS implementation
 
Acc logic
Acc logicAcc logic
Acc logic
 
Strongly connected components
Strongly connected componentsStrongly connected components
Strongly connected components
 
Minimum spanning trees
Minimum spanning treesMinimum spanning trees
Minimum spanning trees
 
Mst 2
Mst 2Mst 2
Mst 2
 
Lect10 organization
Lect10 organizationLect10 organization
Lect10 organization
 
Chain matrix multiplication
Chain matrix multiplicationChain matrix multiplication
Chain matrix multiplication
 
Lecture02
Lecture02Lecture02
Lecture02
 
Lect11 organization
Lect11 organizationLect11 organization
Lect11 organization
 
Dijekstra
DijekstraDijekstra
Dijekstra
 
Complexity theory 3
Complexity theory 3Complexity theory 3
Complexity theory 3
 
Lect9 organization
Lect9 organizationLect9 organization
Lect9 organization
 
Complexity theory 2
Complexity theory 2Complexity theory 2
Complexity theory 2
 
Bfs and dfs
Bfs and dfsBfs and dfs
Bfs and dfs
 
Floyd warshal 2
Floyd warshal 2Floyd warshal 2
Floyd warshal 2
 
Matrix chain multiplication
Matrix chain multiplicationMatrix chain multiplication
Matrix chain multiplication
 
Lect8 organization
Lect8 organizationLect8 organization
Lect8 organization
 
Lect14 organization
Lect14 organizationLect14 organization
Lect14 organization
 

Similar to Lect12 organization

Addressing modes (detailed data path)
Addressing modes (detailed data path)Addressing modes (detailed data path)
Addressing modes (detailed data path)Mahesh Kumar Attri
 
Operating system
Operating systemOperating system
Operating systemraj732723
 
Computer Organization and 8085 microprocessor notes
Computer Organization and 8085 microprocessor notesComputer Organization and 8085 microprocessor notes
Computer Organization and 8085 microprocessor notesLakshmi Sarvani Videla
 
pdfslide.net_morris-mano-ppt.ppt
pdfslide.net_morris-mano-ppt.pptpdfslide.net_morris-mano-ppt.ppt
pdfslide.net_morris-mano-ppt.pptSaurabhPorwal14
 
ITEC582-Chapter 12.pptx
ITEC582-Chapter 12.pptxITEC582-Chapter 12.pptx
ITEC582-Chapter 12.pptxSabaNaeem26
 
Cs2253 coa-2marks-2013
Cs2253 coa-2marks-2013Cs2253 coa-2marks-2013
Cs2253 coa-2marks-2013Buvana Buvana
 
Computer Arithmetic and Processor Basics
Computer Arithmetic and Processor BasicsComputer Arithmetic and Processor Basics
Computer Arithmetic and Processor BasicsShinuMMAEI
 
Introduction to Operating Systems
 Introduction to Operating Systems Introduction to Operating Systems
Introduction to Operating SystemsJérôme Kehrli
 
4th sem,(cs is),computer org unit-7
4th sem,(cs is),computer org unit-74th sem,(cs is),computer org unit-7
4th sem,(cs is),computer org unit-7Sujay pai
 
Bca examination 2015 csa
Bca examination 2015 csaBca examination 2015 csa
Bca examination 2015 csaAnjaan Gajendra
 
Central processing unit
Central processing unitCentral processing unit
Central processing unitKumar
 
the-cpu-design-central-processing-unit-design-1
the-cpu-design-central-processing-unit-design-1the-cpu-design-central-processing-unit-design-1
the-cpu-design-central-processing-unit-design-1Basel Mansour
 
Chapter 4 the processor
Chapter 4 the processorChapter 4 the processor
Chapter 4 the processors9007912
 

Similar to Lect12 organization (20)

Addressing modes (detailed data path)
Addressing modes (detailed data path)Addressing modes (detailed data path)
Addressing modes (detailed data path)
 
Operating system
Operating systemOperating system
Operating system
 
Computer Organization and 8085 microprocessor notes
Computer Organization and 8085 microprocessor notesComputer Organization and 8085 microprocessor notes
Computer Organization and 8085 microprocessor notes
 
pdfslide.net_morris-mano-ppt.ppt
pdfslide.net_morris-mano-ppt.pptpdfslide.net_morris-mano-ppt.ppt
pdfslide.net_morris-mano-ppt.ppt
 
ITEC582-Chapter 12.pptx
ITEC582-Chapter 12.pptxITEC582-Chapter 12.pptx
ITEC582-Chapter 12.pptx
 
Cs2253 coa-2marks-2013
Cs2253 coa-2marks-2013Cs2253 coa-2marks-2013
Cs2253 coa-2marks-2013
 
Computer Arithmetic and Processor Basics
Computer Arithmetic and Processor BasicsComputer Arithmetic and Processor Basics
Computer Arithmetic and Processor Basics
 
Unit iii
Unit iiiUnit iii
Unit iii
 
Introduction to Operating Systems
 Introduction to Operating Systems Introduction to Operating Systems
Introduction to Operating Systems
 
Os unit 2
Os unit 2Os unit 2
Os unit 2
 
4th sem,(cs is),computer org unit-7
4th sem,(cs is),computer org unit-74th sem,(cs is),computer org unit-7
4th sem,(cs is),computer org unit-7
 
PLSQL Advanced
PLSQL AdvancedPLSQL Advanced
PLSQL Advanced
 
Bca examination 2015 csa
Bca examination 2015 csaBca examination 2015 csa
Bca examination 2015 csa
 
Bc0040
Bc0040Bc0040
Bc0040
 
pipelining
pipeliningpipelining
pipelining
 
Central processing unit
Central processing unitCentral processing unit
Central processing unit
 
Design
DesignDesign
Design
 
the-cpu-design-central-processing-unit-design-1
the-cpu-design-central-processing-unit-design-1the-cpu-design-central-processing-unit-design-1
the-cpu-design-central-processing-unit-design-1
 
Chapter 4 the processor
Chapter 4 the processorChapter 4 the processor
Chapter 4 the processor
 
Assembly p1
Assembly p1Assembly p1
Assembly p1
 

More from Maher Alshammari (20)

Cis cvs risc
Cis cvs riscCis cvs risc
Cis cvs risc
 
Lect7 organization
Lect7 organizationLect7 organization
Lect7 organization
 
Lect13 organization
Lect13 organizationLect13 organization
Lect13 organization
 
Lect15 organization
Lect15 organizationLect15 organization
Lect15 organization
 
Lect6 organization
Lect6 organizationLect6 organization
Lect6 organization
 
Lect1 organization 2
Lect1 organization 2Lect1 organization 2
Lect1 organization 2
 
Lect4 organization
Lect4 organizationLect4 organization
Lect4 organization
 
Lect2 organization 2
Lect2 organization 2Lect2 organization 2
Lect2 organization 2
 
Lect3 organization 2
Lect3 organization 2Lect3 organization 2
Lect3 organization 2
 
Lect5 organization
Lect5 organizationLect5 organization
Lect5 organization
 
Greedy algorithm
Greedy algorithmGreedy algorithm
Greedy algorithm
 
Matrix chain multiplication 2
Matrix chain multiplication 2Matrix chain multiplication 2
Matrix chain multiplication 2
 
Edit distance problem
Edit distance problemEdit distance problem
Edit distance problem
 
Topological sort
Topological sortTopological sort
Topological sort
 
Merge sort
Merge sortMerge sort
Merge sort
 
Lecture01
Lecture01Lecture01
Lecture01
 
Bellman ford and floyd warshal
Bellman ford and floyd warshalBellman ford and floyd warshal
Bellman ford and floyd warshal
 
Dijekstra algorithm
Dijekstra algorithmDijekstra algorithm
Dijekstra algorithm
 
Greedy algorithm huffman encoding
Greedy algorithm huffman encodingGreedy algorithm huffman encoding
Greedy algorithm huffman encoding
 
Activity selection 2
Activity selection 2Activity selection 2
Activity selection 2
 

Recently uploaded

Islamabad Call Girls # 03091665556 # Call Girls in Islamabad | Islamabad Escorts
Islamabad Call Girls # 03091665556 # Call Girls in Islamabad | Islamabad EscortsIslamabad Call Girls # 03091665556 # Call Girls in Islamabad | Islamabad Escorts
Islamabad Call Girls # 03091665556 # Call Girls in Islamabad | Islamabad Escortswdefrd
 
Low Rate Call Girls in Laxmi Nagar Delhi Call 9990771857
Low Rate Call Girls in Laxmi Nagar Delhi Call 9990771857Low Rate Call Girls in Laxmi Nagar Delhi Call 9990771857
Low Rate Call Girls in Laxmi Nagar Delhi Call 9990771857delhimodel235
 
Faridabad Call Girls : ☎ 8527673949, Low rate Call Girls
Faridabad Call Girls : ☎ 8527673949, Low rate Call GirlsFaridabad Call Girls : ☎ 8527673949, Low rate Call Girls
Faridabad Call Girls : ☎ 8527673949, Low rate Call Girlsashishs7044
 
Downtown Call Girls O5O91O128O Pakistani Call Girls in Downtown
Downtown Call Girls O5O91O128O Pakistani Call Girls in DowntownDowntown Call Girls O5O91O128O Pakistani Call Girls in Downtown
Downtown Call Girls O5O91O128O Pakistani Call Girls in Downtowndajasot375
 
Greater Noida Call Girls : ☎ 8527673949, Low rate Call Girls
Greater Noida Call Girls : ☎ 8527673949, Low rate Call GirlsGreater Noida Call Girls : ☎ 8527673949, Low rate Call Girls
Greater Noida Call Girls : ☎ 8527673949, Low rate Call Girlsashishs7044
 
FULL ENJOY - 9953040155 Call Girls in Shahdara | Delhi
FULL ENJOY - 9953040155 Call Girls in Shahdara | DelhiFULL ENJOY - 9953040155 Call Girls in Shahdara | Delhi
FULL ENJOY - 9953040155 Call Girls in Shahdara | DelhiMalviyaNagarCallGirl
 
Bur Dubai Call Girls O58993O4O2 Call Girls in Bur Dubai
Bur Dubai Call Girls O58993O4O2 Call Girls in Bur DubaiBur Dubai Call Girls O58993O4O2 Call Girls in Bur Dubai
Bur Dubai Call Girls O58993O4O2 Call Girls in Bur Dubaidajasot375
 
Mandi House Call Girls : ☎ 8527673949, Low rate Call Girls
Mandi House Call Girls : ☎ 8527673949, Low rate Call GirlsMandi House Call Girls : ☎ 8527673949, Low rate Call Girls
Mandi House Call Girls : ☎ 8527673949, Low rate Call Girlsashishs7044
 
FULL ENJOY - 9953040155 Call Girls in Gandhi Vihar | Delhi
FULL ENJOY - 9953040155 Call Girls in Gandhi Vihar | DelhiFULL ENJOY - 9953040155 Call Girls in Gandhi Vihar | Delhi
FULL ENJOY - 9953040155 Call Girls in Gandhi Vihar | DelhiMalviyaNagarCallGirl
 
Alex and Chloe by Daniel Johnson Storyboard
Alex and Chloe by Daniel Johnson StoryboardAlex and Chloe by Daniel Johnson Storyboard
Alex and Chloe by Daniel Johnson Storyboardthephillipta
 
Laxmi Nagar Call Girls : ☎ 8527673949, Low rate Call Girls
Laxmi Nagar Call Girls : ☎ 8527673949, Low rate Call GirlsLaxmi Nagar Call Girls : ☎ 8527673949, Low rate Call Girls
Laxmi Nagar Call Girls : ☎ 8527673949, Low rate Call Girlsashishs7044
 
FULL ENJOY - 9953040155 Call Girls in Uttam Nagar | Delhi
FULL ENJOY - 9953040155 Call Girls in Uttam Nagar | DelhiFULL ENJOY - 9953040155 Call Girls in Uttam Nagar | Delhi
FULL ENJOY - 9953040155 Call Girls in Uttam Nagar | DelhiMalviyaNagarCallGirl
 
Delhi Room Call Girls : ☎ 8527673949, Low rate Call girl service
Delhi Room Call Girls : ☎ 8527673949, Low rate Call girl serviceDelhi Room Call Girls : ☎ 8527673949, Low rate Call girl service
Delhi Room Call Girls : ☎ 8527673949, Low rate Call girl serviceashishs7044
 
FULL ENJOY - 9953040155 Call Girls in Paschim Vihar | Delhi
FULL ENJOY - 9953040155 Call Girls in Paschim Vihar | DelhiFULL ENJOY - 9953040155 Call Girls in Paschim Vihar | Delhi
FULL ENJOY - 9953040155 Call Girls in Paschim Vihar | DelhiMalviyaNagarCallGirl
 
How Can You Get Dubai Call Girls +971564860409 Call Girls Dubai?
How Can You Get Dubai Call Girls +971564860409 Call Girls Dubai?How Can You Get Dubai Call Girls +971564860409 Call Girls Dubai?
How Can You Get Dubai Call Girls +971564860409 Call Girls Dubai?kexey39068
 
Retail Store Scavanger Hunt - Foundation College Park
Retail Store Scavanger Hunt - Foundation College ParkRetail Store Scavanger Hunt - Foundation College Park
Retail Store Scavanger Hunt - Foundation College Parkjosebenzaquen
 
Govindpuri Call Girls : ☎ 8527673949, Low rate Call Girls
Govindpuri Call Girls : ☎ 8527673949, Low rate Call GirlsGovindpuri Call Girls : ☎ 8527673949, Low rate Call Girls
Govindpuri Call Girls : ☎ 8527673949, Low rate Call Girlsashishs7044
 
The First Date by Daniel Johnson (Inspired By True Events)
The First Date by Daniel Johnson (Inspired By True Events)The First Date by Daniel Johnson (Inspired By True Events)
The First Date by Daniel Johnson (Inspired By True Events)thephillipta
 
Hazratganj ] (Call Girls) in Lucknow - 450+ Call Girl Cash Payment 🧄 89231135...
Hazratganj ] (Call Girls) in Lucknow - 450+ Call Girl Cash Payment 🧄 89231135...Hazratganj ] (Call Girls) in Lucknow - 450+ Call Girl Cash Payment 🧄 89231135...
Hazratganj ] (Call Girls) in Lucknow - 450+ Call Girl Cash Payment 🧄 89231135...akbard9823
 
Strip Zagor Extra 322 - Dva ortaka.pdf
Strip   Zagor Extra 322 - Dva ortaka.pdfStrip   Zagor Extra 322 - Dva ortaka.pdf
Strip Zagor Extra 322 - Dva ortaka.pdfStripovizijacom
 

Recently uploaded (20)

Islamabad Call Girls # 03091665556 # Call Girls in Islamabad | Islamabad Escorts
Islamabad Call Girls # 03091665556 # Call Girls in Islamabad | Islamabad EscortsIslamabad Call Girls # 03091665556 # Call Girls in Islamabad | Islamabad Escorts
Islamabad Call Girls # 03091665556 # Call Girls in Islamabad | Islamabad Escorts
 
Low Rate Call Girls in Laxmi Nagar Delhi Call 9990771857
Low Rate Call Girls in Laxmi Nagar Delhi Call 9990771857Low Rate Call Girls in Laxmi Nagar Delhi Call 9990771857
Low Rate Call Girls in Laxmi Nagar Delhi Call 9990771857
 
Faridabad Call Girls : ☎ 8527673949, Low rate Call Girls
Faridabad Call Girls : ☎ 8527673949, Low rate Call GirlsFaridabad Call Girls : ☎ 8527673949, Low rate Call Girls
Faridabad Call Girls : ☎ 8527673949, Low rate Call Girls
 
Downtown Call Girls O5O91O128O Pakistani Call Girls in Downtown
Downtown Call Girls O5O91O128O Pakistani Call Girls in DowntownDowntown Call Girls O5O91O128O Pakistani Call Girls in Downtown
Downtown Call Girls O5O91O128O Pakistani Call Girls in Downtown
 
Greater Noida Call Girls : ☎ 8527673949, Low rate Call Girls
Greater Noida Call Girls : ☎ 8527673949, Low rate Call GirlsGreater Noida Call Girls : ☎ 8527673949, Low rate Call Girls
Greater Noida Call Girls : ☎ 8527673949, Low rate Call Girls
 
FULL ENJOY - 9953040155 Call Girls in Shahdara | Delhi
FULL ENJOY - 9953040155 Call Girls in Shahdara | DelhiFULL ENJOY - 9953040155 Call Girls in Shahdara | Delhi
FULL ENJOY - 9953040155 Call Girls in Shahdara | Delhi
 
Bur Dubai Call Girls O58993O4O2 Call Girls in Bur Dubai
Bur Dubai Call Girls O58993O4O2 Call Girls in Bur DubaiBur Dubai Call Girls O58993O4O2 Call Girls in Bur Dubai
Bur Dubai Call Girls O58993O4O2 Call Girls in Bur Dubai
 
Mandi House Call Girls : ☎ 8527673949, Low rate Call Girls
Mandi House Call Girls : ☎ 8527673949, Low rate Call GirlsMandi House Call Girls : ☎ 8527673949, Low rate Call Girls
Mandi House Call Girls : ☎ 8527673949, Low rate Call Girls
 
FULL ENJOY - 9953040155 Call Girls in Gandhi Vihar | Delhi
FULL ENJOY - 9953040155 Call Girls in Gandhi Vihar | DelhiFULL ENJOY - 9953040155 Call Girls in Gandhi Vihar | Delhi
FULL ENJOY - 9953040155 Call Girls in Gandhi Vihar | Delhi
 
Alex and Chloe by Daniel Johnson Storyboard
Alex and Chloe by Daniel Johnson StoryboardAlex and Chloe by Daniel Johnson Storyboard
Alex and Chloe by Daniel Johnson Storyboard
 
Laxmi Nagar Call Girls : ☎ 8527673949, Low rate Call Girls
Laxmi Nagar Call Girls : ☎ 8527673949, Low rate Call GirlsLaxmi Nagar Call Girls : ☎ 8527673949, Low rate Call Girls
Laxmi Nagar Call Girls : ☎ 8527673949, Low rate Call Girls
 
FULL ENJOY - 9953040155 Call Girls in Uttam Nagar | Delhi
FULL ENJOY - 9953040155 Call Girls in Uttam Nagar | DelhiFULL ENJOY - 9953040155 Call Girls in Uttam Nagar | Delhi
FULL ENJOY - 9953040155 Call Girls in Uttam Nagar | Delhi
 
Delhi Room Call Girls : ☎ 8527673949, Low rate Call girl service
Delhi Room Call Girls : ☎ 8527673949, Low rate Call girl serviceDelhi Room Call Girls : ☎ 8527673949, Low rate Call girl service
Delhi Room Call Girls : ☎ 8527673949, Low rate Call girl service
 
FULL ENJOY - 9953040155 Call Girls in Paschim Vihar | Delhi
FULL ENJOY - 9953040155 Call Girls in Paschim Vihar | DelhiFULL ENJOY - 9953040155 Call Girls in Paschim Vihar | Delhi
FULL ENJOY - 9953040155 Call Girls in Paschim Vihar | Delhi
 
How Can You Get Dubai Call Girls +971564860409 Call Girls Dubai?
How Can You Get Dubai Call Girls +971564860409 Call Girls Dubai?How Can You Get Dubai Call Girls +971564860409 Call Girls Dubai?
How Can You Get Dubai Call Girls +971564860409 Call Girls Dubai?
 
Retail Store Scavanger Hunt - Foundation College Park
Retail Store Scavanger Hunt - Foundation College ParkRetail Store Scavanger Hunt - Foundation College Park
Retail Store Scavanger Hunt - Foundation College Park
 
Govindpuri Call Girls : ☎ 8527673949, Low rate Call Girls
Govindpuri Call Girls : ☎ 8527673949, Low rate Call GirlsGovindpuri Call Girls : ☎ 8527673949, Low rate Call Girls
Govindpuri Call Girls : ☎ 8527673949, Low rate Call Girls
 
The First Date by Daniel Johnson (Inspired By True Events)
The First Date by Daniel Johnson (Inspired By True Events)The First Date by Daniel Johnson (Inspired By True Events)
The First Date by Daniel Johnson (Inspired By True Events)
 
Hazratganj ] (Call Girls) in Lucknow - 450+ Call Girl Cash Payment 🧄 89231135...
Hazratganj ] (Call Girls) in Lucknow - 450+ Call Girl Cash Payment 🧄 89231135...Hazratganj ] (Call Girls) in Lucknow - 450+ Call Girl Cash Payment 🧄 89231135...
Hazratganj ] (Call Girls) in Lucknow - 450+ Call Girl Cash Payment 🧄 89231135...
 
Strip Zagor Extra 322 - Dva ortaka.pdf
Strip   Zagor Extra 322 - Dva ortaka.pdfStrip   Zagor Extra 322 - Dva ortaka.pdf
Strip Zagor Extra 322 - Dva ortaka.pdf
 

Lect12 organization

  • 1. 12/14/2014 1 Computer Organization Instructors : Dr. Abdul Raouf Khan Mr.Marwan El-Haj Central Processing Unit The Central Processing Unit is made of three major parts, as shown below. Control Arithmetic Logic Unit (ALU) Register Set
  • 2. 12/14/2014 2 Central Processing Unit The register set stores intermediate data used during the execution of the instructions. ALU performs the required microoperation for executing the instruction. The control unit supervises the transfer of information among the registers and instructs the ALU as to which instruction to perform Central Processing Unit Computer architecture is sometimes defined as the computer structure and behavior as seen by programmer that uses machine language instructions. This include the instruction formats, addressing modes, the instruction set, and the general organization of the CPU registers.
  • 3. 12/14/2014 3 General Register Organization Referring Memory repeatedly is time consuming Intermediate values can be stored in registers large number of registers are included in CPU, connected through bus Registers can communicate with each other A bus organization for seven registers is shown next
  • 4. 12/14/2014 4 General Register Organization The control Unit directs the operations e.g. To perform R1 R2+R3 1. MUX A selector (SELA): to place the contents of R2 into bus A 2. MUX B selector (SELB): to place the contents of R3 into bus B 3. ALU operation selector (OPR): to provide arithmetic addition A+B 4. Decoder destination selector (SELD): to transfer the content of the output bus into R1. Stack Organization Stack is a storage device (memory) that stores information in such a manner that the items stored last is retrieved first. Also known as LIFO (Last-In-First-Out) The register that holds the address of the top of the stack is called Stack Pointer (SP). The two operations of stack are insertion and deletion of items known as PUSH & POP.
  • 5. 12/14/2014 5 Push operation 1. If (Full=0)Then ‘Check Stack Not Full 1. Begin 2. SP SP + 1 ‘Increment stack pointer 3. M[SP] DR ‘write on top of stack 4. If (SP=0) then FULL 1 ‘Check if stack is full 5. EMPTY 0 ‘Mark the stack not empty 6. End
  • 6. 12/14/2014 6 POP Operation 1. If (Empty=0)Then ‘Check if Stack not Empty 1. Begin 2. DR M[SP] ‘Read from top of stack 3. SP SP-1 ‘Decrement stack pointer 4. If (SP=0) then EMPTY 1 ‘Check if stack is empty 5. FULL 0 ‘Mark the stack not Full 6. End Memory Stack A stack can exist as a stand-alone unit as shown above or can be implemented in a random access memory attached to CPU. The implementation of a stack in the CPU is done by assigning a portion of memory to stack operation and using a processor register as stack pointer. See figure next
  • 7. 12/14/2014 7 Reverse Polish Notation A stack operation is very effective in evaluating arithmetic expressions. Infix Notation A + B Prefix or polish Notation + AB Postfix or reverse polish notation AB+ Reverse polish notation is in a form suitable for stack manipulation
  • 8. 12/14/2014 8 Examples Infix (A * B) + (C * D) Postfix AB * CD * + Infix (A+B) * [C * (D + E) + F] Postfix AB + DE + C * F + * Evaluation of arithmetic expression First Arithmetic expression is converted to reverse polish notation Operands are pushed into the stack in the order of appearance Two topmost operands in the stack are used for operation The stack is popped & the result of the operation replaces the lower operand The expression is evaluated in this order & final result remains in the top of stack
  • 9. 12/14/2014 9 Example ( 3*4)+(5*6) = 34*56*+ 3 4 * 5 6 * + 3 4 3 12 5 12 42 30 12 6 5 12