BASIC COMPUTING CONCEPTS Part 3 Dr. Abdel-Rahman Al-Qawasmi INSIDE THE MACHINE. 2007 by Jon Stokes.

Slides:



Advertisements
Similar presentations
Instruction Set Design
Advertisements

Goal: Write Programs in Assembly
Instruction Set-Intro
CPU Review and Programming Models CT101 – Computing Systems.
Chapter 2.
ITCS 3181 Logic and Computer Systems 2015 B. Wilkinson slides3.ppt Modification date: March 16, Addressing Modes The methods used in machine instructions.
The CPU Revision Typical machine code instructions Using op-codes and operands Symbolic addressing. Conditional and unconditional branches.
Operand And Instructions Representation By Dave Maung.
COMP3221 lec08-arith.1 Saeid Nooshabadi COMP 3221 Microprocessors and Embedded Systems Lecture 8: C/Assembler Data Processing
Instructions Set Bo Cheng Instruction Set Design An Instruction Set provides a functional description of a processor. It is the visible.
Execution of an instruction
Data Manipulation Computer System consists of the following parts:
Memory - Registers Instruction Sets
Chapters 5 - The LC-3 LC-3 Computer Architecture Memory Map
Dr. Abdel-Rahman Al-Qawasmi
Part II: Addressing Modes
ADDRESSING MODES OF Addressing Modes of  To perform any operation, we have to give the corresponding instructions to the microprocessor.
Operand Addressing and Instruction Representation
SUPERSCALAR EXECUTION. two-way superscalar The DLW-2 has two ALUs, so it’s able to execute two arithmetic instructions in parallel (hence the term two-way.
Topic 8: Data Transfer Instructions CSE 30: Computer Organization and Systems Programming Winter 2010 Prof. Ryan Kastner Dept. of Computer Science and.
Basic Operational Concepts of a Computer
MIPS assembly. Computer What’s in a computer? Processor, memory, I/O devices (keyboard, mouse, LCD, video camera, speaker), disk, CD drive, …
Processor Structure & Operations of an Accumulator Machine
P IPEL INED EXECUT ION(1) Part 4 Dr. Abdel-Rahman Al-Qawasmi.
IT253: Computer Organization Lecture 4: Instruction Set Architecture Tonga Institute of Higher Education.
Computer Architecture and the Fetch-Execute Cycle
Lecture Objectives: 1)Define the terms least significant bit and most significant bit. 2)Explain how unsigned integer numbers are represented in memory.
MEMORY ORGANIZTION & ADDRESSING Presented by: Bshara Choufany.
Instruction Set Architecture The portion of the machine visible to the programmer Issues: Internal storage model Addressing modes Operations Operands Encoding.
Execution of an instruction
Module : Algorithmic state machines. Machine language Machine language is built up from discrete statements or instructions. On the processing architecture,
Indira Gandhi National Open University presents. A Video Lecture Course: Computer Platforms.
Computer Organization and Architecture Instructions: Language of the Machine Hennessy Patterson 2/E chapter 3. Notes are available with photocopier 24.
Computer Architecture EKT 422
Operand Addressing And Instruction Representation Cs355-Chapter 6.
Computer Architecture Lecture 03 Fasih ur Rehman.
Instruction Sets: Addressing modes and Formats Group #4  Eloy Reyes  Rafael Arevalo  Julio Hernandez  Humood Aljassar Computer Design EEL 4709c Prof:
Chapter 2 — Instructions: Language of the Computer — 1 Memory Operands Main memory used for composite data – Arrays, structures, dynamic data To apply.
What is a program? A sequence of steps
Arrays in MIPS Assembly Computer Organization and Assembly Language: Module 6.
Computer Organization Instructions Language of The Computer (MIPS) 2.
Instruction Sets. Instruction set It is a list of all instructions that a processor can execute. It is a list of all instructions that a processor can.
MIPS assembly. Computer  What’s in a computer?  Processor, memory, I/O devices (keyboard, mouse, LCD, video camera, speaker), disk, CD drive, …
Assembly Variables: Registers Unlike HLL like C or Java, assembly cannot use variables – Why not? Keep Hardware Simple Assembly Operands are registers.
F453 Module 8: Low Level Languages 8.1: Use of Computer Architecture.
EEL 4709C Prof. Watson Herman Group 4 Ali Alshamma, Derek Montgomery, David Ortiz 11/11/2008.
Computers’ Basic Organization
Instruction sets : Addressing modes and Formats
Addressing Modes in Microprocessors
A Closer Look at Instruction Set Architectures
Morgan Kaufmann Publishers
A Closer Look at Instruction Set Architectures
A Closer Look at Instruction Set Architectures: Expanding Opcodes
Computer Organization and Assembly Language (COAL)
Processor Organization and Architecture
CSCI206 - Computer Organization & Programming
CS149D Elements of Computer Science
CSCI206 - Computer Organization & Programming
MIPS assembly.
Computer Architecture and the Fetch-Execute Cycle
Architecture Overview
Introduction to Micro Controllers & Embedded System Design
MIPS Assembly.
COMP541 Datapaths I Montek Singh Mar 18, 2010.
COMS 361 Computer Organization
Mastering Memory Modes
ECE 352 Digital System Fundamentals
Instructions in Machine Language
CPU Structure CPU must:
Presentation transcript:

BASIC COMPUTING CONCEPTS Part 3 Dr. Abdel-Rahman Al-Qawasmi INSIDE THE MACHINE by Jon Stokes

The DLW-1’s Basic Architecture and Arithmetic Instruction Format The DLW-1 microprocessor consists of an ALU attached to four registers, named A, B, C, and D for convenience. The DLW-1 is attached to a bank of main memory that’s laid out as a line of 256 memory cells, numbered #0 to #255.

The DLW-1’s Arithmetic Instruction Format The instruction field specifies the type of operation being performed (for example, an addition, a subtraction, a multiplication, and so on). The two source fields tell the computer which registers hold the two numbers being operated on, or the operands. Finally, the destination field tells the computer which register to place the result in.

An Example DLW-1 Program

Memory Accesses: Register vs. Immediate Real computers have billions of possible locations in which data can be stored, so programmers need a more flexible way to access memory, a way that doesn’t require each memory access to specify numerically an exact memory address. Modern computers allow the contents of a register to be used as a memory address, a move that provides the programmer with the desired flexibility.

Register as a memory address Since the content of D is the number 12, we can tell the computer to look in D for the memory cell address by substituting the register name (this time marked with a # sign for use as an address), for the actual memory cell number in line 1’s load instruction. Thus, the first lines of Programs 1-1 and 1-2 are functionally equivalent.

Register as a memory address Capabilities are designed to make programmers’ lives easier, because when used with the register-relative addressing technique described next they make managing code and data traffic between the processor and massive amounts of main memory much less complex.

Register-Relative Addressing In real-world programs, loads and stores most often use register- relative addressing, which is a way of specifying memory addresses relative to a register that contains a fixed base address. A data segment is a block of contiguous memory cells that a program stores all of its data An offset is the distance in bytes of the desired memory location from the data segment’s base address.

Register-Relative Addressing In the case of the load, the processor takes the number in D, which is the base address of the data segment, adds 108 to it, and uses the result as the load’s destination memory address. By using register-relative addressing instead of absolute addressing (in which memory addresses are given as immediate values), a programmer can write programs without knowing the exact location of data in memory Because both memory addresses and regular integer numbers are stored in the same registers, these registers are called general-purpose registers (GPRs). On the DLW-1, A, B, C, and D are all GPRs.