SlideShare a Scribd company logo
1 of 14
Basic Computer Concepts
1
 Central Processing Unit (CPU)
 Instruction Addressing
 CPU Architectures
2
 Registers
 Instruction Decoder
 Arithmetic Logic Unit (ALU)
 Example of operation
◦ Registers - Fetch instruction
◦ Instruction Decoder – Decode
instruction
◦ ALU - Execute instruction
◦ Registers - Go back to 1.
3
 Program counter (auto-increments)
 Instruction register
 Accumulator
 Flag register
 Stack pointer
 Index register
 General purpose registers
4
 Instruction - example: add a,b
◦ Directive (“add”)
◦ Source operand (“a”)
◦ Destination operand (“b”)
 Move memory to/from register
 Move register to/from register
 ALU operation to register
 ALU operation to memory
 Program flow control
5
 Add
 Subtract
 Multiply
 Divide
 Logic functions
6
 How are registers used in computer systems?
 What is the purpose of the program counter?
 What is the purpose of the instruction decoder?
 What does “ALU” stand for? What is its purpose?
 Compare and contrast the type of computer
language used versus the ease of generating code
and the control of timing.
 Which register of the CPU holds the address of the
instruction to be fetched?
 Which section of the CPU is responsible for
performing addition?
 What is the largest hex value that can be moved
into an 8-bit register? What is the decimal
equivalent of the hex value?
7
 1 clock cycle modes
◦ Inherent – no operand
◦ Indexed – operand address in register
 2 clock cycle modes
◦ Immediate – 8 bit constant follows
◦ Direct – 8 bit operand address follows
◦ Relative – 8 bit operand address offset follows
 3 clock cycle modes
◦ Immediate – 16 bit constant follows
◦ Extended – 16 bit operand address follows
8
 High level language
◦ lightCtr = 0; // reset the counter
◦ err = OS_ERR_Q_EMPTY;
 Assembly language
◦ LDAB #$12 ;load 12H into B
◦ LDAA source ;copy source to reg A.
 Machine language
9
 Can a microcontroller programmer
make up new addressing modes? Why
or why not?
 Compare and contrast the different
addressing modes available in most
microprocessors.
 True or false. HCS12 instructions using
extended addressing mode are 3-byte
/3-clock cycle instructions.
10
 von Neumann
◦ One data bus
◦ One address bus
 Harvard
◦ Two data busses
◦ Two address busses
 Direct Memory Access (DMA)
 Microcontroller (e.g. PIC795, HCS12)
◦ Harvard internally
◦ Von Neumann for add-ons
◦ Separate ports for I/O
◦ Sets of “shadow” registers
11
 High level versus assembly
 Instruction size
 Clock cycles per instruction
 Number of registers
 Register vs memory operations
12
 Compare and contrast the Harvard and von
Neumann architectures in terms of the use of
address and data busses to fetch code and data.
 Which architecture is most commonly used by
microcontrollers internally and why? Externally?
 What do RISC and CISC stand for? Compare and
contrast the size of instructions in each.
 Which of the following operations do not exist
for the ADD instruction in RISC?
(a) register to register
(b) immediate to register
(c) memory to memory
13
 Central Processing Unit (CPU)
 Instruction Addressing
 CPU Architectures
14

More Related Content

What's hot

Computer Architecture and organization ppt.
Computer Architecture and organization ppt.Computer Architecture and organization ppt.
Computer Architecture and organization ppt.mali yogesh kumar
 
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
 
Computer organization and architecture
Computer organization and architectureComputer organization and architecture
Computer organization and architectureSubesh Kumar Yadav
 
Class 7 an 8 bit embedded platform -instruction set
Class 7 an 8 bit embedded platform -instruction setClass 7 an 8 bit embedded platform -instruction set
Class 7 an 8 bit embedded platform -instruction setSURYAPRAKASH S
 
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
 
Assembly Language Basics
Assembly Language BasicsAssembly Language Basics
Assembly Language BasicsEducation Front
 
Addresing mode and timing diagram
Addresing mode and timing diagramAddresing mode and timing diagram
Addresing mode and timing diagramtrivediau1
 
Datapath Design of Computer Architecture
Datapath Design of Computer ArchitectureDatapath Design of Computer Architecture
Datapath Design of Computer ArchitectureAbu Zaman
 
Addressing modes of 8085 by Er. Swapnil V. Kaware
Addressing modes of 8085 by Er. Swapnil V. KawareAddressing modes of 8085 by Er. Swapnil V. Kaware
Addressing modes of 8085 by Er. Swapnil V. KawareProf. Swapnil V. Kaware
 
Computer registers
Computer registersComputer registers
Computer registersJatin Grover
 
Instruction Set (Part 2)
Instruction Set (Part 2)Instruction Set (Part 2)
Instruction Set (Part 2)Ajeng Savitri
 
Assembly language (Example with mapping from C++ to Assembly)
Assembly language (Example with mapping from C++ to Assembly)Assembly language (Example with mapping from C++ to Assembly)
Assembly language (Example with mapping from C++ to Assembly)Tish997
 
Central processing unit and stack organization r013
Central processing unit and stack organization   r013Central processing unit and stack organization   r013
Central processing unit and stack organization r013arunachalamr16
 
Unit 3 assembler and processor
Unit 3   assembler and processorUnit 3   assembler and processor
Unit 3 assembler and processorAbha Damani
 

What's hot (20)

Computer Architecture and organization ppt.
Computer Architecture and organization ppt.Computer Architecture and organization ppt.
Computer Architecture and organization ppt.
 
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
 
Computer organization and architecture
Computer organization and architectureComputer organization and architecture
Computer organization and architecture
 
Presentation1
Presentation1Presentation1
Presentation1
 
Class 7 an 8 bit embedded platform -instruction set
Class 7 an 8 bit embedded platform -instruction setClass 7 an 8 bit embedded platform -instruction set
Class 7 an 8 bit embedded platform -instruction set
 
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
 
Registers
RegistersRegisters
Registers
 
Assembly Language Basics
Assembly Language BasicsAssembly Language Basics
Assembly Language Basics
 
Addresing mode and timing diagram
Addresing mode and timing diagramAddresing mode and timing diagram
Addresing mode and timing diagram
 
Datapath Design of Computer Architecture
Datapath Design of Computer ArchitectureDatapath Design of Computer Architecture
Datapath Design of Computer Architecture
 
Cpu registers
Cpu registersCpu registers
Cpu registers
 
Addressing modes of 8085 by Er. Swapnil V. Kaware
Addressing modes of 8085 by Er. Swapnil V. KawareAddressing modes of 8085 by Er. Swapnil V. Kaware
Addressing modes of 8085 by Er. Swapnil V. Kaware
 
Computer registers
Computer registersComputer registers
Computer registers
 
Instruction Set (Part 2)
Instruction Set (Part 2)Instruction Set (Part 2)
Instruction Set (Part 2)
 
Assembly language (Example with mapping from C++ to Assembly)
Assembly language (Example with mapping from C++ to Assembly)Assembly language (Example with mapping from C++ to Assembly)
Assembly language (Example with mapping from C++ to Assembly)
 
MICROPROCESSOR
MICROPROCESSORMICROPROCESSOR
MICROPROCESSOR
 
Central processing unit and stack organization r013
Central processing unit and stack organization   r013Central processing unit and stack organization   r013
Central processing unit and stack organization r013
 
Unit 3 assembler and processor
Unit 3   assembler and processorUnit 3   assembler and processor
Unit 3 assembler and processor
 
Computer System Architecture
Computer System ArchitectureComputer System Architecture
Computer System Architecture
 
Register & Memory
Register & MemoryRegister & Memory
Register & Memory
 

Similar to Ecet330 1 b - basic computer concepts

pdfslide.net_morris-mano-ppt.ppt
pdfslide.net_morris-mano-ppt.pptpdfslide.net_morris-mano-ppt.ppt
pdfslide.net_morris-mano-ppt.pptSaurabhPorwal14
 
Addressing modes (detailed data path)
Addressing modes (detailed data path)Addressing modes (detailed data path)
Addressing modes (detailed data path)Mahesh Kumar Attri
 
Z 80 processors (History-Products)
Z 80 processors (History-Products)Z 80 processors (History-Products)
Z 80 processors (History-Products)Mohammed Hilal
 
Ee6403 --unit v -digital signal processors
Ee6403 --unit v -digital signal processorsEe6403 --unit v -digital signal processors
Ee6403 --unit v -digital signal processorsJeya Bright
 
4bit pc report[cse 08-section-b2_group-02]
4bit pc report[cse 08-section-b2_group-02]4bit pc report[cse 08-section-b2_group-02]
4bit pc report[cse 08-section-b2_group-02]shibbirtanvin
 
4bit PC report
4bit PC report4bit PC report
4bit PC reporttanvin
 
UNIT 1 Microprocessors.pptx
UNIT 1 Microprocessors.pptxUNIT 1 Microprocessors.pptx
UNIT 1 Microprocessors.pptxGowrishankar C
 
Effisiensi prog atmel
Effisiensi prog atmelEffisiensi prog atmel
Effisiensi prog atmelrm_dhozooo
 
ITEC582-Chapter 12.pptx
ITEC582-Chapter 12.pptxITEC582-Chapter 12.pptx
ITEC582-Chapter 12.pptxSabaNaeem26
 
Computer organiztion5
Computer organiztion5Computer organiztion5
Computer organiztion5Umang Gupta
 

Similar to Ecet330 1 b - basic computer concepts (20)

pdfslide.net_morris-mano-ppt.ppt
pdfslide.net_morris-mano-ppt.pptpdfslide.net_morris-mano-ppt.ppt
pdfslide.net_morris-mano-ppt.ppt
 
Arm11
Arm11Arm11
Arm11
 
Bc0040
Bc0040Bc0040
Bc0040
 
Addressing modes (detailed data path)
Addressing modes (detailed data path)Addressing modes (detailed data path)
Addressing modes (detailed data path)
 
Z 80 processors (History-Products)
Z 80 processors (History-Products)Z 80 processors (History-Products)
Z 80 processors (History-Products)
 
Ee6403 --unit v -digital signal processors
Ee6403 --unit v -digital signal processorsEe6403 --unit v -digital signal processors
Ee6403 --unit v -digital signal processors
 
Chapter 3
Chapter 3Chapter 3
Chapter 3
 
4bit pc report[cse 08-section-b2_group-02]
4bit pc report[cse 08-section-b2_group-02]4bit pc report[cse 08-section-b2_group-02]
4bit pc report[cse 08-section-b2_group-02]
 
4bit PC report
4bit PC report4bit PC report
4bit PC report
 
UNIT 1 Microprocessors.pptx
UNIT 1 Microprocessors.pptxUNIT 1 Microprocessors.pptx
UNIT 1 Microprocessors.pptx
 
Effisiensi prog atmel
Effisiensi prog atmelEffisiensi prog atmel
Effisiensi prog atmel
 
ITEC582-Chapter 12.pptx
ITEC582-Chapter 12.pptxITEC582-Chapter 12.pptx
ITEC582-Chapter 12.pptx
 
8051d
8051d8051d
8051d
 
Central processor organization
Central processor organizationCentral processor organization
Central processor organization
 
microprocessor
 microprocessor microprocessor
microprocessor
 
Highridge ISA
Highridge ISAHighridge ISA
Highridge ISA
 
Doc8453
Doc8453Doc8453
Doc8453
 
Computer organiztion5
Computer organiztion5Computer organiztion5
Computer organiztion5
 
Instruction codes
Instruction codesInstruction codes
Instruction codes
 
Cao
CaoCao
Cao
 

More from Ralph Ambuehl

Ecet375 1 a - basic networking concepts
Ecet375   1 a - basic networking conceptsEcet375   1 a - basic networking concepts
Ecet375 1 a - basic networking conceptsRalph Ambuehl
 
Background knowledge probe
Background knowledge probeBackground knowledge probe
Background knowledge probeRalph Ambuehl
 
Classroom Expectations
Classroom ExpectationsClassroom Expectations
Classroom ExpectationsRalph Ambuehl
 
R.A. Ambuehl Teacher
R.A. Ambuehl TeacherR.A. Ambuehl Teacher
R.A. Ambuehl TeacherRalph Ambuehl
 

More from Ralph Ambuehl (7)

Ecet375 1 a - basic networking concepts
Ecet375   1 a - basic networking conceptsEcet375   1 a - basic networking concepts
Ecet375 1 a - basic networking concepts
 
Background knowledge probe
Background knowledge probeBackground knowledge probe
Background knowledge probe
 
Ecet330 lab rubric
Ecet330 lab rubricEcet330 lab rubric
Ecet330 lab rubric
 
Math Grades
Math GradesMath Grades
Math Grades
 
Math Rubrics
Math RubricsMath Rubrics
Math Rubrics
 
Classroom Expectations
Classroom ExpectationsClassroom Expectations
Classroom Expectations
 
R.A. Ambuehl Teacher
R.A. Ambuehl TeacherR.A. Ambuehl Teacher
R.A. Ambuehl Teacher
 

Recently uploaded

How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxmanuelaromero2013
 
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
Crayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon ACrayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon AUnboundStockton
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxNirmalaLoungPoorunde1
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17Celine George
 
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxiammrhaywood
 
Introduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher EducationIntroduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher Educationpboyjonauth
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxSayali Powar
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdfssuser54595a
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentInMediaRes1
 
internship ppt on smartinternz platform as salesforce developer
internship ppt on smartinternz platform as salesforce developerinternship ppt on smartinternz platform as salesforce developer
internship ppt on smartinternz platform as salesforce developerunnathinaik
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTiammrhaywood
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 
DATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersDATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersSabitha Banu
 
Painted Grey Ware.pptx, PGW Culture of India
Painted Grey Ware.pptx, PGW Culture of IndiaPainted Grey Ware.pptx, PGW Culture of India
Painted Grey Ware.pptx, PGW Culture of IndiaVirag Sontakke
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxGaneshChakor2
 
भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,Virag Sontakke
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxpboyjonauth
 
Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...jaredbarbolino94
 

Recently uploaded (20)

How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptx
 
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
 
Crayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon ACrayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon A
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptx
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17
 
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
 
Introduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher EducationIntroduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher Education
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media Component
 
internship ppt on smartinternz platform as salesforce developer
internship ppt on smartinternz platform as salesforce developerinternship ppt on smartinternz platform as salesforce developer
internship ppt on smartinternz platform as salesforce developer
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
9953330565 Low Rate Call Girls In Rohini Delhi NCR
9953330565 Low Rate Call Girls In Rohini  Delhi NCR9953330565 Low Rate Call Girls In Rohini  Delhi NCR
9953330565 Low Rate Call Girls In Rohini Delhi NCR
 
DATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginnersDATA STRUCTURE AND ALGORITHM for beginners
DATA STRUCTURE AND ALGORITHM for beginners
 
Painted Grey Ware.pptx, PGW Culture of India
Painted Grey Ware.pptx, PGW Culture of IndiaPainted Grey Ware.pptx, PGW Culture of India
Painted Grey Ware.pptx, PGW Culture of India
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptx
 
भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptx
 
Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...Historical philosophical, theoretical, and legal foundations of special and i...
Historical philosophical, theoretical, and legal foundations of special and i...
 

Ecet330 1 b - basic computer concepts

  • 2.  Central Processing Unit (CPU)  Instruction Addressing  CPU Architectures 2
  • 3.  Registers  Instruction Decoder  Arithmetic Logic Unit (ALU)  Example of operation ◦ Registers - Fetch instruction ◦ Instruction Decoder – Decode instruction ◦ ALU - Execute instruction ◦ Registers - Go back to 1. 3
  • 4.  Program counter (auto-increments)  Instruction register  Accumulator  Flag register  Stack pointer  Index register  General purpose registers 4
  • 5.  Instruction - example: add a,b ◦ Directive (“add”) ◦ Source operand (“a”) ◦ Destination operand (“b”)  Move memory to/from register  Move register to/from register  ALU operation to register  ALU operation to memory  Program flow control 5
  • 6.  Add  Subtract  Multiply  Divide  Logic functions 6
  • 7.  How are registers used in computer systems?  What is the purpose of the program counter?  What is the purpose of the instruction decoder?  What does “ALU” stand for? What is its purpose?  Compare and contrast the type of computer language used versus the ease of generating code and the control of timing.  Which register of the CPU holds the address of the instruction to be fetched?  Which section of the CPU is responsible for performing addition?  What is the largest hex value that can be moved into an 8-bit register? What is the decimal equivalent of the hex value? 7
  • 8.  1 clock cycle modes ◦ Inherent – no operand ◦ Indexed – operand address in register  2 clock cycle modes ◦ Immediate – 8 bit constant follows ◦ Direct – 8 bit operand address follows ◦ Relative – 8 bit operand address offset follows  3 clock cycle modes ◦ Immediate – 16 bit constant follows ◦ Extended – 16 bit operand address follows 8
  • 9.  High level language ◦ lightCtr = 0; // reset the counter ◦ err = OS_ERR_Q_EMPTY;  Assembly language ◦ LDAB #$12 ;load 12H into B ◦ LDAA source ;copy source to reg A.  Machine language 9
  • 10.  Can a microcontroller programmer make up new addressing modes? Why or why not?  Compare and contrast the different addressing modes available in most microprocessors.  True or false. HCS12 instructions using extended addressing mode are 3-byte /3-clock cycle instructions. 10
  • 11.  von Neumann ◦ One data bus ◦ One address bus  Harvard ◦ Two data busses ◦ Two address busses  Direct Memory Access (DMA)  Microcontroller (e.g. PIC795, HCS12) ◦ Harvard internally ◦ Von Neumann for add-ons ◦ Separate ports for I/O ◦ Sets of “shadow” registers 11
  • 12.  High level versus assembly  Instruction size  Clock cycles per instruction  Number of registers  Register vs memory operations 12
  • 13.  Compare and contrast the Harvard and von Neumann architectures in terms of the use of address and data busses to fetch code and data.  Which architecture is most commonly used by microcontrollers internally and why? Externally?  What do RISC and CISC stand for? Compare and contrast the size of instructions in each.  Which of the following operations do not exist for the ADD instruction in RISC? (a) register to register (b) immediate to register (c) memory to memory 13
  • 14.  Central Processing Unit (CPU)  Instruction Addressing  CPU Architectures 14