CEN 226: Computer Organization & Assembly Language :CSC 225 (Lec#1) By Dr. Syed Noman.

Slides:



Advertisements
Similar presentations
Instruction Set-Intro
Advertisements

Dr. Ken Hoganson, © August 2014 Programming in R COURSE NOTES 2 Hoganson Language Translation.
Assembly Language for Intel-Based Computers, 4 th Edition Chapter 1: Basic Concepts (c) Pearson Education, All rights reserved. You may modify and.
4/23/2015Engineering Problem Solving with C++ second edition, J. ingber 1 Engineering Problem Solving with C++, Etter/Ingber Chapter 1.
The Assembly Language Level
ICS103 Programming in C Lecture 1: Overview of Computers & Programming
Lecture 1: Overview of Computers & Programming
EEE226 MICROPROCESSORBY DR. ZAINI ABDUL HALIM School of Electrical & Electronic Engineering USM.
COE Computer Organization & Assembly Language
CEN 226: Computer Organization & Assembly Language :CSC 225 (Lec#4)
Copyright © 2008 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Starting Out with Programming Logic & Design First Edition by Tony Gaddis.
The Analytical Engine Module 6 Program Translation.
Introduction to Computers and Programming. Some definitions Algorithm: –A procedure for solving a problem –A sequence of discrete steps that defines such.
Assembly Language for Intel-Based Computers, 5 th Edition Chapter 1: Basic Concepts (c) Pearson Education, All rights reserved. You may modify.
Table 1. Software Hierarchy Levels.. Essential Tools An assembler is a program that converts source-code programs into a machine language (object file).
Chapter 2: Impact of Machine Architectures What is the Relationship Between Programs, Programming Languages, and Computers.
Assembly Language for Intel-Based Computers, 5 th Edition Chapter 1: Basic Concepts (c) Pearson Education, All rights reserved. You may modify.
1 Introduction Chapter 1 n What is Assembly Language? n Data Representation.
Introduction to Computers and Programming. Some definitions Algorithm: Algorithm: A procedure for solving a problem A procedure for solving a problem.
Chapter 17 Microprocessor Fundamentals William Kleitz Digital Electronics with VHDL, Quartus® II Version Copyright ©2006 by Pearson Education, Inc. Upper.
Basic Concepts Computer Organization and Assembly Language.
Joseph L. Lindo Assembly Programming Sir Joseph Lindo University of the Cordilleras.
Assembly Language for Intel-Based Computers, 5th Edition
Assembly Language for Intel-Based Computers, 5 th Edition Chapter 1: Basic Concepts (c) Pearson Education, All rights reserved. You may modify.
Chapter 1: Basic Concepts (c) Pearson Education, All rights reserved. You may modify and copy this slide show for your personal use, or for.
1 Layers of Computer Science, ISA and uArch Alexander Titov 20 September 2014.
Topics Introduction Hardware and Software How Computers Store Data
CPS120: Introduction to Computer Science
CSU0014 Assembly Languages Homepage: Textbook: Kip R. Irvine, Assembly Language for Intel-Based Computers,
Summer 2014 Chapter 1: Basic Concepts. Irvine, Kip R. Assembly Language for Intel-Based Computers 6/e, Chapter Overview Welcome to Assembly Language.
Assembly Language for x86 Processors 7th Edition
An Introduction to Computers August 12, 2008 Mrs. C. Furman.
ACOE2511 ACOE251/AEEC335 -Assembly Language for the 80X86/Pentium Intel Microprocessors Lecturer: Dr. Konstantinos Tatas.
Chapter 1: Basic Concepts
1 Introduction Chapter 1 n What is Assembly Language? n Data Representation.
Computer Systems Organization CS 1428 Foundations of Computer Science.
Assembly Language for x86 Processors 7 th Edition Chapter 1: Basic Concepts (c) Pearson Education, All rights reserved. You may modify and copy this.
CPU Internal memory I/O interface circuit System bus
Assembly Language A Brief Introduction. Unit Learning Goals CPU architecture. Basic Assembler Commands High level Programming  Assembler  Machine Language.
Chapter 19 Number Systems. Irvine, Kip R. Assembly Language for Intel-Based Computers, Translating Languages English: Display the sum of A times.
Ass. Prof. Dr Masri Ayob TK 6123 Lecture 13: Assembly Language Level (Level 4)
Computer Engineering Rabie A. Ramadan Lecture 1. 2 Welcome Back.
ACOE2511 Assembly Language for the 80X86/Pentium Intel Microprocessors Lecturer: Dr. Konstantinos Tatas.
Computer organization Practical 1. Administrative Issues The course requirements are: –To be nice and open minded –To pass the exam (there is a boolean.
Computer Organization and Assembly Languages 2007/11/10
Princes Nora Bint Abdul Rahman University Dept. of Computer & Information Sciences CS 321 Computer Organization & Assembly Language Lecture 1 (Course Introduction)
8086/8088 Instruction Set, Machine Codes and Addressing Modes.
Digital Computer Concept and Practice Copyright ©2012 by Jaejin Lee Control Unit.
Computer Operation. Binary Codes CPU operates in binary codes Representation of values in binary codes Instructions to CPU in binary codes Addresses in.
Representation of Data - Instructions Start of the lesson: Open this PowerPoint from the A451 page – Representation of Data/ Instructions How confident.
Week 6 Dr. Muhammad Ayaz Intro. to Assembly Language.
1 Chapter 1: Introduction Appendix A: Binary and Hexadecimal Tutorial Assembly Language for Intel-Based Computers, 3rd edition Kip R. Irvine.
1 Chapter 1: Basic Concepts Assembly Language for Intel-Based Computers, 4th edition Kip R. Irvine 9/6/2003.
Assembly Language for x86 Processors 6th Edition
Assembly Language (CSW 353)
Operating System Interface between a user and the computer hardware
COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE
Why to use the assembly and why we need this course at all?
Microprocessor Systems Design I
Microprocessor and Assembly Language
Microprocessor Systems Design I
Microprocessor and Assembly Language
Chapter One: Introduction
Computer Organization and Assembly Language
Introduction to Computer Programming
Chapter 6 Programming the basic computer
Dept. of Computer & Information Sciences (Course Introduction)
Dr. Clincy Professor of CS
Presentation transcript:

CEN 226: Computer Organization & Assembly Language :CSC 225 (Lec#1) By Dr. Syed Noman

Course organization Course is divided into two sections: ▫Computer organization ▫Assembly language programming Computer organization and assembly language are interrelated. ▫Program in assembly and get better understanding of the machine ▫Get familiarized with the machine to better program in assembly language. To program in assembly language requires knowledge of the machine.

Text Book

Reference Book 4

Course Outline Introduction to PC hardware. von Neumann machine 8086 machine architecture PC software requirements Assembly language programmers requirements Program logical and control String operations Arithmetic operations for processing binary data Assembling linking and executing a program.

Marks Distribution Lab : 20 Marks Mid-1: 15 Marks Mid-2: 15 Marks Assignment: 6 marks Quizzes: 2 Marks (best of 2 out of 3) Attendance: 2 Marks (after 2 absents, 1 mark will be deducted) Final: 40 Marks

Collection of Programs Learning Tip: object of the program must be clearly defined. Program Codes are as follows: ▫EP#: Example program number ▫LT#: Lab Task number ▫QP#: Quiz program number ▫AP#: Assignment program#

8 Software Hierarchy Levels LevelDescription Application Program Software designed for a particular class of applications High-Level Language (HLL) Programs are compiled into either assembly language or machine language. E.g. C++, Pascal, Java, Visual Basic, etc. Operating Systems Contains procedures than can be called from programs written in either high-level language or assembly language. This system may also contain an application programming interface (API). Assembly Language (ASM) Uses instruction mnemonics that have a one-to-one correspondence with machine language. Machine Language (ML) Numeric instructions and operands that can be stored in memory and directly executed by the computer processor.

9 What is Assembly Language? A low-level processor- specific programming language, designed to match the processor’s machine instruction set each assembly language instruction matches exactly one machine language instruction we study here Intel’s 80x86 (and Pentiums)

10 Why learn Assembly Language? To learn how high-level language code gets translated into machine language ▫i.e.: to learn the details hidden in HLL code To learn the computer’s hardware ▫by direct access to memory, video controller, sound card, keyboard… To speed up applications ▫direct access to hardware (ex: writing directly to I/O ports instead of doing a system call) ▫good ASM code is faster and smaller: rewrite in ASM the critical areas of code

11 Table: Comparison of Assembly Language and High-Level Languages Type of ApplicationsHigh-Level LanguageAssembly Language Business application software for single platform. Formal structures make it easy to organize and maintain. No formal structure. Hardware device driver. Awkward coding techniques required. Hardware access is straightforward and simple. Business application for multiple platforms. Portable.Difficult to maintain. Embedded systems and computer games requiring direct hardware access. Produces too much executable code, and may not run efficiently. Ideal, because the executable code is small and runs quickly.

12 Machine Language An assembler is a program that converts ASM code into machine language code: ▫ mov al,5 (Assembly Language) ▫ (Machine Language)  most significant byte is the opcode for “move into register AL”  the least significant byte is for the operand “5” Directly programming in machine language offers no advantage (over Assembly)...

13 Binary Numbers/Storage Size are used to store both code and data On Intel’s x86: ▫byte = 8 bits (smallest addressable unit) ▫word = 2 bytes ▫doubleword = 2 words ▫quadword = 2 doublewords

14 Data Representation Even if we know that a block of memory contains data, to obtain its value we need to choose an interpretation Ex: memory content “ ” can either represent: ▫the number 2^{6} + 1 = 65 ▫or the ASCII code of character “A”

15 Data Representation Number Systems ▫Binary/Octal/Decimal/Hexadecimal ▫Converting between various number systems Signed/Unsigned Interpretation ▫Two’s Complement Addition/Subtraction Character Storage

16 Number Systems A written number is meaningful only with respect to a base To tell the assembler which base we use: ▫Hexadecimal 25 is written as 25h ▫Octal 25 is written as 25o or 25q ▫Binary 1010 is written as 1010b ▫Decimal 1010 is written as 1010 or 1010d You are supposed to know how to convert from one base to another.