Chapter 6: An Introduction to System Software and Virtual Machines

Similar documents
Chapter 6. An Introduction to System Software and Virtual Machines. INVITATION TO Computer Science

A Review of Chapter 5 and. CSc 2010 Spring 2012 Instructor: Qian Hu

OPERATING SYSTEMS. SYSTEM SOFTWARE IB DP Computer science Standard Level ICS3U. SYSTEM SOFTWARE IB DP Computer science Standard Level ICS3U

Level 2: The Hardware World Chapters 4 and 5 (topics of other cs courses)

Chapter 1: Introduction

Introduction to Computer Systems and Operating Systems

Operating Systems CS3502 Spring 2018

Module 1: Introduction

An Introduction to System Software and Virtual Machines

Chapter 5: Computer Systems Organization. Invitation to Computer Science, C++ Version, Third Edition

Chapter 5: Computer Systems Organization

1. Operating System Concepts

Introduction to Operating System

OPERATING SYSTEMS. Prescribed Text Book Operating System Principles, Seventh Edition By Abraham Silberschatz, Peter Baer Galvin and Greg Gagne

Module 1: Introduction. What is an Operating System?

Contents. Today's Topic: Introduction to Operating Systems

Computers in Engineering COMP 208. Computer Structure. Computer Architecture. Computer Structure Michael A. Hawker

CS370 Operating Systems

Introduction to Computer Science. Homework 1

Copyright 2000 N. AYDIN. All rights reserved. 1

Chapter 03: Computer Arithmetic. Lesson 09: Arithmetic using floating point numbers

Chapter 2 Operating-System Structures


Introduction to MiniSim A Simple von Neumann Machine

CPS221 Lecture: Operating System Protection

Operating Systems Overview. Chapter 2

Problems and Solutions to the January 1994 Core Examination

Computer-System Architecture (cont.) Symmetrically Constructed Clusters (cont.) Advantages: 1. Greater computational power by running applications

Some popular Operating Systems include Linux Operating System, Windows Operating System, VMS, OS/400, AIX, z/os, etc.

UNIT 2. OPERATING SYSTEM STRUCTURES

Little Man Computer. Copyright 2019 Peter Roberts

CPS221 Lecture: Operating System Functions

1 The Simpletron Assembly Language

B. V. Patel Institute of Business Management, Computer &Information Technology, UTU

CSc33200: Operating Systems, CS-CCNY, Fall 2003 Jinzhong Niu December 10, Review

The First Operating System Was Human

Overview of Operating Systems

Introduction. Operating Systems. Introduction. Introduction. Introduction

B. the address of the data is supplied by the users C. there is no need for an address i.e. the data is used as an address

OPERATING SYSTEMS UNIT - 1

Unit 2 : Computer and Operating System Structure

AKU-EB May Examination 2017

IBPS SO Examination 2013 IT Officer Professional Knowledge Question Paper

2.2 THE MARIE Instruction Set Architecture

OPERATING SYSTEMS. P. PRAVEEN Asst.Prof, CSE

Topics: Early systems and OS overview Skim Chapters 1-2 of SGG Read Chapter 1 of USP CS 3733 Operating Systems

Subject Name:Operating system. Subject Code:10EC35. Prepared By:Remya Ramesan and Kala H.S. Department:ECE. Date:

Lecture 2 - Fundamental Concepts

What is the Race Condition? And what is its solution? What is a critical section? And what is the critical section problem?

Process Management And Synchronization

1.1 Introduction. Fig.1.1 Abstract view of the components of a computer system.

Memory Management. Frédéric Haziza Spring Department of Computer Systems Uppsala University

CPU ARCHITECTURE. QUESTION 1 Explain how the width of the data bus and system clock speed affect the performance of a computer system.

SaM. 1. Introduction. 2. Stack Machine

Topics. Hardware and Software. Introduction. Main Memory. The CPU 9/21/2014. Introduction to Computers and Programming

Introduction to System Programming

Model answer of AS-4159 Operating System B.tech fifth Semester Information technology

Module 1: Introduction

When Deadlock Happens

OPERATING SYSTEMS. Prescribed Text Book. Operating System Principles, Seventh Edition. Abraham Silberschatz, Peter Baer Galvin and Greg Gagne

Operating Systems Fundamentals. What is an Operating System? Focus. Computer System Components. Chapter 1: Introduction

General Objectives: To understand the process management in operating system. Specific Objectives: At the end of the unit you should be able to:

Introduction. What is an Operating System? A Modern Computer System. Computer System Components. What is an Operating System?

More Programming Constructs -- Introduction

The Slide does not contain all the information and cannot be treated as a study material for Operating System. Please refer the text book for exams.

Contemporary Multilevel Machines

OPERATING SYSTEMS. Systems with Multi-programming. CS 3502 Spring Chapter 4

Part I Overview Chapter 1: Introduction

Resource Sharing & Management

Advanced Diploma in Computer Science (907) Computer Systems Architecture

Process-1 requests the tape unit, waits. In this chapter, we shall analyze deadlocks with the following assumptions:

CHAPTER-1: INTRODUCTION TO OPERATING SYSTEM:

Main Memory (Part I)

MARK SCHEME for the October/November 2012 series 9691 COMPUTING. 9691/33 Paper 3 (Written Paper), maximum raw mark 90

System Call. Preview. System Call. System Call. System Call 9/7/2018

Performance of Various Levels of Storage. Movement between levels of storage hierarchy can be explicit or implicit

C++ Programming Language Lecture 1 Introduction

LAB B Translating Code to Assembly

Chapter 3: Operating-System Structures

Chapter 2: Operating-System Structures

Introduction. CS3026 Operating Systems Lecture 01

OPERATING SYSTEMS OVERVIEW

Introduction to Operating System. Dr. Aarti Singh Professor MMICT&BM MMU

CS370 Operating Systems

Computer Science and Engineering 331. Midterm Examination #1. Fall Name: Solutions S.S.#:

What are some common categories of system calls? What are common ways of structuring an OS? What are the principles behind OS design and

HANDOUTS/ NOTES/ STUDY MATERIAL. Jagannath Institute of Management Sciences Lajpat Nagar OPERATING SYSTEM

OPERATING SYSTEM. Functions of Operating System:

General Objective:To understand the basic memory management of operating system. Specific Objectives: At the end of the unit you should be able to:

Learning objectives. Computer principles The characteristics of contemporary processors, input, output and storage devices

Wednesday, February 4, Chapter 4

Chapter 2: Operating-System Structures

0 Introduction: Computer systems and program development

Interprocess Communication By: Kaushik Vaghani

CSc 10200! Introduction to Computing. Lecture 1 Edgardo Molina Fall 2013 City College of New York

Chapter 8: Deadlocks. The Deadlock Problem

The Deadlock Problem. Chapter 8: Deadlocks. Bridge Crossing Example. System Model. Deadlock Characterization. Resource-Allocation Graph

Year 12 Computer Science Learning Cycle 2 Overview

Computer Organization & Assembly Language Programming

Operating System: an Overview. Lucia Dwi Krisnawati, MA

Transcription:

Objectives Chapter 6: An Introduction to System Software and Virtual Machines Invitation to Computer Science, C++ Version, Third Edition In this chapter, you will learn about: System software Assemblers and assembly language Operating systems Invitation to Computer Science, C++ Version, Third Edition 2 Introduction Introduction (continued) Von Neumann computer Naked machine Hardware without any helpful user-oriented features Extremely difficult for a human to work with An interface between the user and the hardware is needed to make a Von Neumann computer usable Tasks of the interface Hide details of the underlying hardware from the user Present information in a way that does not require in-depth knowledge of the internal structure of the system Invitation to Computer Science, C++ Version, Third Edition 3 Invitation to Computer Science, C++ Version, Third Edition 4 Introduction (continued) System Software: The Virtual Machine Tasks of the interface (continued) Allow easy user access to the available resources Prevent accidental or intentional damage to hardware, programs, and data System software Acts as an intermediary between users and hardware Creates a virtual environment for the user that hides the actual computer architecture Virtual machine (or virtual environment) Set of services and resources created by the system software and seen by the user Invitation to Computer Science, C++ Version, Third Edition 5 Invitation to Computer Science, C++ Version, Third Edition 6 1

Types of System Software Figure 6.1 The Role of System Software System software is a collection of many different programs Operating system Controls the overall operation of the computer Communicates with the user Determines what the user wants Activates system programs, applications packages, or user programs to carry out user requests Invitation to Computer Science, C++ Version, Third Edition 7 Invitation to Computer Science, C++ Version, Third Edition 8 Types of System Software (continued) User interface Graphical user interface (GUI) provides graphical control of the capabilities and services of the computer Language services Assemblers, compilers, and interpreters Figure 6.2 Types of System Software Allow you to write programs in a high-level, useroriented language, and then execute them Invitation to Computer Science, C++ Version, Third Edition 9 Invitation to Computer Science, C++ Version, Third Edition 10 Types of System Software (continued) Types of System Software (continued) Memory managers Allocate and retrieve memory space Information managers Handle the organization, storage, and retrieval of information on mass storage devices I/O systems Allow the use of different types of input and output devices Scheduler Keeps a list of programs ready to run and selects the one that will execute next Utilities Collections of library routines that provide services either to user or other system routines Invitation to Computer Science, C++ Version, Third Edition 11 Invitation to Computer Science, C++ Version, Third Edition 12 2

Assemblers and Assembly Language: Assembly Language Machine language Uses binary Allows only numeric memory addresses Difficult to change Difficult to create data Assembly Language (continued) Assembly languages Designed to overcome shortcomings of machine languages Create a more productive, user-oriented environment Earlier termed second-generation languages Now viewed as low-level programming languages Invitation to Computer Science, C++ Version, Third Edition 13 Invitation to Computer Science, C++ Version, Third Edition 14 Assembly Language (continued) Source program An assembly language program Object program A machine language program Assembler Figure 6.3 The Continuum of Programming Languages Translates a source program into a corresponding object program Invitation to Computer Science, C++ Version, Third Edition 15 Invitation to Computer Science, C++ Version, Third Edition 16 Assembly Language (continued) Advantages of writing in assembly language rather than machine language Use of symbolic operation codes rather than numeric (binary) ones Use of symbolic memory addresses rather than numeric (binary) ones Figure 6.4 The Translation/Loading/Execution Process Pseudo-operations that provide useful useroriented services such as data generation Invitation to Computer Science, C++ Version, Third Edition 17 Invitation to Computer Science, C++ Version, Third Edition 18 3

Examples of Assembly Language Algorithmic operations Set the value of i to 1 (line 2). : Add 1 to the value of i (line 7). Figure 6.6 Structure of a Typical Assembly Language Program Invitation to Computer Science, C++ Version, Third Edition 19 Invitation to Computer Science, C++ Version, Third Edition 20 Examples of Assembly Language Assembly language translation LOAD ONE --Put a 1 into register R. STORE I --Store the constant 1 into i. : INCREMENT I --Add 1 to memory location i. : I:.DATA 0 --The index value. Initially it is 0. ONE:.DATA 1 --The constant 1. Examples of Assembly Language Arithmetic expression A = B + C 7 (Assume that B and C have already been assigned values) Invitation to Computer Science, C++ Version, Third Edition 21 Invitation to Computer Science, C++ Version, Third Edition 22 Examples of Assembly Language Assembly language translation LOAD B --Put the value B into register R. ADD C --R now holds the sum (B + C). SUBTRACT SEVEN --R now holds the expression (B + C - 7). STORE A --Store the result into A. : --These data should be placed after the HALT. A:.DATA 0 B:.DATA 0 C:.DATA 0 SEVEN:.DATA 7 --The constant 7. Examples of Assembly Language Problem Read in a sequence of non-negative numbers, one number at a time, and compute a running sum When you encounter a negative number, print out the sum of the non-negative values and stop Invitation to Computer Science, C++ Version, Third Edition 23 Invitation to Computer Science, C++ Version, Third Edition 24 4

Figure 6.7 Algorithm to Compute the Sum of Numbers Figure 6.8 Assembly Language Program to Compute the Sum of Nonnegative Numbers Invitation to Computer Science, C++ Version, Third Edition 25 Invitation to Computer Science, C++ Version, Third Edition 26 Translation and Loading Translation and Loading (continued) Before a source program can be run, an assembler and a loader must be invoked Assembler Translates a symbolic assembly language program into machine language Loader Reads instructions from the object file and stores them into memory for execution Assembler tasks Convert symbolic op codes to binary Convert symbolic addresses to binary Perform assembler services requested by the pseudo-ops Put translated instructions into a file for future use Invitation to Computer Science, C++ Version, Third Edition 27 Invitation to Computer Science, C++ Version, Third Edition 28 Operating Systems System commands Carry out services such as translate a program, load a program, run a program Types of system commands Lines of text typed at a terminal Menu items displayed on a screen and selected with a mouse and a button: point-and-click Examined by the operating system Functions of an Operating System Five most important responsibilities of the operating system User interface management Program scheduling and activation Control of access to system and files Efficient resource allocation Deadlock detection and error detection Invitation to Computer Science, C++ Version, Third Edition 29 Invitation to Computer Science, C++ Version, Third Edition 30 5

The User Interface Operating system Waits for a user command If command is legal, activates and schedules the appropriate software package User interfaces Text-oriented Graphical Figure 6.15 User Interface Responsibility of the Operating System Invitation to Computer Science, C++ Version, Third Edition 31 Invitation to Computer Science, C++ Version, Third Edition 32 System Security And Protection Efficient Allocation Of Resources The operating system must prevent Non-authorized people from using the computer User names and passwords Legitimate users from accessing data or programs they are not authorized to access Authorization lists The operating system ensures that Multiple tasks of the computer may be underway at one time Processor is constantly busy Keeps a queue of programs that are ready to run Whenever processor is idle, picks a job from the queue and assigns it to the processor Invitation to Computer Science, C++ Version, Third Edition 33 Invitation to Computer Science, C++ Version, Third Edition 34 The Safe Use Of Resources Deadlock Two processes are each holding a resource the other needs Neither process will ever progress The operating system must handle deadlocks Deadlock prevention Deadlock recovery Historical Overview of Operating Systems Development First generation of system software (roughly 1945 1955) No operating systems Assemblers and loaders were almost the only system software provided Invitation to Computer Science, C++ Version, Third Edition 35 Invitation to Computer Science, C++ Version, Third Edition 36 6

Historical Overview of Operating Systems Development (continued) Second generation of system software (1955 1965) Batch operating systems Ran collections of input programs one after the other Included a command language Figure 6.18 Operation of a Batch Computer System Invitation to Computer Science, C++ Version, Third Edition 37 Invitation to Computer Science, C++ Version, Third Edition 38 Historical Overview of Operating Systems Development (continued) Third-generation operating systems (1965 1985) Multiprogrammed operating systems Permitted multiple user programs to run at once Historical Overview of Operating Systems Development (continued) Fourth-generation operating systems (1985 present) Network operating systems Virtual environment treats resources physically residing on the computer in the same way as resources available through the computer s network Invitation to Computer Science, C++ Version, Third Edition 39 Invitation to Computer Science, C++ Version, Third Edition 40 The Future Operating systems will continue to evolve Possible characteristics of fifth-generation systems Multimedia user interfaces Parallel processing systems Figure 6.22 The Virtual Environment Created by a Network Operating System Completely distributed computing environments Invitation to Computer Science, C++ Version, Third Edition 41 Invitation to Computer Science, C++ Version, Third Edition 42 7

Figure 6.23 Structure of a Distributed System Invitation to Computer Science, C++ Version, Third Edition 43 Figure 6.24 Some of the Major Advances in Operating Systems Development Invitation to Computer Science, C++ Version, Third Edition 44 Summary System software acts as an intermediary between the users and the hardware Assembly language creates a more productive, user-oriented environment than machine language An assembler translates an assembly language program into a machine language program Summary Responsibilities of the operating system User interface management Program scheduling and activation Control of access to system and files Efficient resource allocation Deadlock detection and error detection Invitation to Computer Science, C++ Version, Third Edition 45 Invitation to Computer Science, C++ Version, Third Edition 46 8