Introduction to Computing Systems (4th Exam). 1.[10] Please convert each machine language instruction to its assembly language counterpart. –0101001001100000.

Slides:



Advertisements
Similar presentations
Instruction Sets: Characteristics and Functions Addressing Modes
Advertisements

Chapter 7 Introduction to LC-3 Assembly Language Assembly Language Assembly Process Using the Editor & Simulator for Assembly Language Programming.
Machine Instructions Operations
Introduction to Computing Systems from bits & gates to C & beyond Chapter 7 LC-2 Assembly Language.
Introduction to Computing Systems from bits & gates to C & beyond Chapter 7 LC-2 Assembly Language.
Programming 68HC11.
CEG 320/520: Computer Organization and Assembly Language Programming1 Assembly Language Programming Machine Code Hand Assembly.
Overview Program in LC-3 machine language Use the Editor
Some thoughts: If it is too good to be true, it isn’t. Success is temporary. It is hard work to make it simple. Knowing you did it right is enough reward.
Overview Review Trap Instruction Program in LC-3 machine language Use LC-3 Simulator.
Chapter 9_2 Following Instructions: Principles of Computer Operation.
Chapter 6 Programming in Machine Language The LC-3 Simulator
Introduction to Computing Systems (3rd Exam). 1.[5] Suppose R1 contains an integer x and R2 contains another integer y. Please write an instruction which.
Chapter 8 Overview Programmed I/O Introduction to Interrupt Driven I/O Project 3.
Chapters 4 & 5: LC-3 Computer Architecture Machine Instructions Assembly language Programming in Machine and Assembly Language.
Chapter 8 Overview Programmed I/O Interrupt Driven I/O.
Lecture 13 - Introduction to the Central Processing Unit (CPU)
Quiz (Representative of what might appear on a test, see posted sample tests.) Instruction formats and addressing modes.
Chapter 7 LC-3 Assembly Language. 2 College of Charleston, School of Science and Mathematics Dr. Anderson, Computer Science CS 250 Comp. Org. & Assembly.
EKT 221/4 DIGITAL ELECTRONICS II  Registers, Micro-operations and Implementations - Part2.
Introduction to Computer Engineering ECE/CS 252, Fall 2010 Prof. Mikko Lipasti Department of Electrical and Computer Engineering University of Wisconsin.
Assembly Language A Brief Introduction. Unit Learning Goals CPU architecture. Basic Assembler Commands High level Programming  Assembler  Machine Language.
Chapter 5 The LC Instruction Set Architecture ISA = All of the programmer-visible components and operations of the computer memory organization.
Fall EE 333 Lillevik 333f06-l5 University of Portland School of Engineering Computer Organization Lecture 5 MIPS Instructions Loops Machine Instructions.
SSST: CS130 F. Hadziomerovic
Introduction to Computing Systems and Programming The LC-2.
INTRODUCTION TO COMPUTERS
1 Bits, Bytes, Binary & Hex CIS TAG ▪ Byte Bit.
Chapter 2- Visual Basic Schneider1 Programming Languages: Machine Language Assembly Language High level Language.
Master Boot Record (MBR)
Chapter 6 Programming Adapted from slides provided by McGraw-Hill Companies Inc., modified by professors at University of Wisconsin-Madison.
Compsci 210 Tutorial Five.
Computer Science 210 Computer Organization
Computer Science 210 Computer Organization
Chapter 7 Assembly Language
Introduction to programming
Problem Identification
Chapter 7 & 9.2 Assembly Language
Chapter 7 Assembly Language
Conditional Branches What distinguishes a computer from a simple calculator is its ability to make decisions Decisions are made using the if statement,
Chapter 5 The LC-3.
Computer Science 210 Computer Organization
LC-3 Details and Examples
Figure 8.1 Architecture of a Simple Computer System.
ECE243 Interpreter Lab.
Chapter 7 LC-2 Assembly Language.
Introduction to Assembly Chapter 2
Computer Programming Machine and Assembly.
Computer Science 210 Computer Organization
MIPS Instruction Encoding
Computer Science 210 Computer Organization
MIPS Instruction Encoding
Computer Science 210 Computer Organization
CSE 113 A January 19 – 23, 2009.
TRAP Routines Subroutines Privileged Instructions
Introduction to Assembly Chapter 2
Chapter 7 LC-2 Assembly Language.
January 19 – 23, 2009 CSE 113 B.
Computer Science 210 Computer Organization
The University of Adelaide, School of Computer Science
CS334: Memory _ Mars simulator Lab 4(part2-2)
Chapter 7 Assembly Language
MARIE: An Introduction to a Simple Computer
Chapter 7 Assembly Language An Hong 2016 Fall
Lecture 11 Z80 Instruction Hong DGU.
CS334: Number Systems Lab 1.
Example 1: (expression evaluation)
CPSC 171 Introduction to Computer Science
Little Man Computer.
Chapter 5 The LC-3.
Presentation transcript:

Introduction to Computing Systems (4th Exam)

1.[10] Please convert each machine language instruction to its assembly language counterpart. – – – – – AND R1,R1,#0 ADD R5,R5,#-1 NOT R7,R7 ADD R4,R1,R4 HALT

2.[10] Please convert each machine language instruction to its assembly language counterpart. –ADD R1, R1, R0 –AND R3, R3, #5 –NOT R1, R4 –ADD R5, R5, #-3 –.FILL xFF

3.[20] Consider the following program: x x x x x x300A x300B x300C x300D (a) Explain what the program does. (b) What will the value be contained in R0 when the program is executed? (a) Perform (b) 21

4.[20] Consider the following program: x x x x x x x x x x x400A (a) Explain what the program does. (b) What will the value be contained in the address x400A when the program is executed? (a) Shift x0003 left 5 times (b) 96 or x0060

5.[20] Consider the following program:.ORIG 5000 AND R2, R2, #0 LD R0, DATA1 NOT R0, R0 ADD R0, R0, #1 LD R1, DATA2 AGAIN ADD R2, R2, #1 ADD R1, R0, R1 BRzp AGAIN FINISH ADD R2, R2, #-1 HALT.BLKW x0021 DATA1.FILL x0003 DATA2.FILL x000E.END Explain what the program does. What will the value be contained in R2 when the program is executed? Perform 4

6.[20] Please assemble the program of Problem 5. x x x x x x x x x x x502B x502C