Process.

Slides:



Advertisements
Similar presentations
Register In computer architecture, a processor register is a small amount of storage available on the CPU whose contents can be accessed more quickly than.
Advertisements

There are two types of addressing schemes:
MICROPROCESSORS TWO TYPES OF MODELS ARE USED :  PROGRAMMER’S MODEL :- THIS MODEL SHOWS FEATURES, SUCH AS INTERNAL REGISTERS, ADDRESS,DATA & CONTROL BUSES.
CEN 226: Computer Organization & Assembly Language :CSC 225 (Lec#3) By Dr. Syed Noman.
Process Description and Control Module 1.0. Major Requirements of an Operating System Interleave the execution of several processes to maximize processor.
Using Two Queues. Using Multiple Queues Suspended Processes Processor is faster than I/O so all processes could be waiting for I/O Processor is faster.
Riyadh Philanthropic Society For Science Prince Sultan College For Woman Dept. of Computer & Information Sciences CS 251 Introduction to Computer Organization.
The 8086 Microprocessor The 8086, announced in 1978, was the first 16-bit microprocessor introduced by Intel Corporation 8086 is 16-bit MPU. Externally.
An Introduction to 8086 Microprocessor.
Chapter 4 Processes. Process: what is it? A program in execution A program in execution usually usually Can also have suspended or waiting processes Can.
Types of Registers (8086 Microprocessor Based)
Process by Dr. Amin Danial Asham. References Operating System Concepts ABRAHAM SILBERSCHATZ, PETER BAER GALVIN, and GREG GAGNE.
Module R3 Process Scheduling. Module R3 involves the creation of a simple “Round Robin” dispatcher. The successful completion of this module will require.
Silberschatz, Galvin and Gagne ©2009 Operating System Concepts – 8 th Edition, Chapter 3: Process-Concept.
University of Sargodha, Lahore Campus Prepared by Ali Saeed.
MODULE 5 INTEL TODAY WE ARE GOING TO DISCUSS ABOUT, FEATURES OF 8086 LOGICAL PIN DIAGRAM INTERNAL ARCHITECTURE REGISTERS AND FLAGS OPERATING MODES.
Chapter 3: Processes. 3.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts Chapter 3: Processes Process Concept Process Scheduling Operations.
Process Control Management Prepared by: Dhason Operating Systems.
1 x86 Programming Model Microprocessor Computer Architectures Lab Components of any Computer System Control – logic that controls fetching/execution of.
Computer Organization & Assembly Language University of Sargodha, Lahore Campus Prepared by Ali Saeed.
BITS Pilani Pilani Campus Pawan Sharma Lecture / ES C263 INSTR/CS/EEE F241 Microprocessor Programming and Interfacing.
I NTEL 8086 M icroprocessor بسم الله الرحمن الرحيم 1.
ΜComputer Structure μProcessor Memory Bus System I/O Ports.
Chapter 12 Processor Structure and Function. Central Processing Unit CPU architecture, Register organization, Instruction formats and addressing modes(Intel.
Multiprogramming. Readings r Chapter 2.1 of the textbook.
Processes and threads.
Instruction set Architecture
Format of Assembly language
Process Management Process Concept Why only the global variables?
Operating Systems (CS 340 D)
UNIT Architecture M.Brindha AP/EIE
Introduction to 8086 Microprocessor
Lecture Topics: 11/1 Processes Process Management
8086 MICROPROCESSOR ARCHITECTURE & SEGMENTATION
8086 Microprocessor.
Computer Organization & Assembly Language Chapter 3
COURSE OUTCOMES OF MICROPROCESSOR AND PROGRAMMING
Chapter 3: Processes.
ADDRESSING MODES.
Intro to Processes CSSE 332 Operating Systems
Intel 8086 MICROPROCESSOR Architecture.
Basic Microprocessor Architecture
ADDRESSING MODES.
University of Gujrat Department of Computer Science
Intel 8088 (8086) Microprocessor Structure
Operating Systems (CS 340 D)
Defining Types of data expression Dn [name] expression Dn [name]
Symbolic Instruction and Addressing
Introduction to Assembly Language
BIC 10503: COMPUTER ARCHITECTURE
Intel 8088 (8086) Microprocessor Structure
8086 Registers Module M14.2 Sections 9.2, 10.1.
CS-401 Computer Architecture & Assembly Language Programming
Morgan Kaufmann Publishers Computer Organization and Assembly Language
Symbolic Instruction and Addressing
CS 301 Fall 2002 Computer Organization
Process & its States Lecture 5.
Process Description and Control
Symbolic Instruction and Addressing
Processes Hank Levy 1.
Processes and Process Management
Computer Architecture CST 250
Unit-I 80386DX Architecture
Chapter 6 –Symbolic Instruction and Addressing
Processes Hank Levy 1.
Intel 8086.
Chapter 3: Processes Process Concept Process Scheduling
Chapter 8: Instruction Set 8086 CPU Architecture
8086 microprocessior PIN OUT DIAGRAM OF  Power supply and frequency signals  It uses 5V DC supply at V CC pin 40, and uses ground at V SS pin.
Microprocessor Lecture 7 (8086 Registers).
Presentation transcript:

Process

Program A program by itself is not a process. It is a static entity made up of program statement. Program contains the instructions to be executed by processor. A program takes a space at single place in memory and continues to stay there. A program does not perform any action by itself.

Process A process is a program in execution. The execution of a process must progress in a sequential fashion. A process is a dynamic entity. Definition of process is following: A process is defined as an entity which represents the basic unit of work to be implemented in the system.

Components of process are following. 1 Object Program Code to be executed. 2 Data Data to be used for executing the program. 3 Resources While executing the program, it may require some resources. 4 Status Verifies the status of the process execution. A process can run to completion only when all requested resources have been allocated to the process.

Process Control Block, PCB Each process is represented in the operating system by a process control block PCB also called a task control block. PCB is the data structure used by the operating system. Operating system groups all information that needs about particular process. PCB contains many pieces of information associated with a specific process which are described below. 1 Pointer Pointer points to another process control block. Pointer is used for maintaining the scheduling list. 2 Process State Process state may be new, ready, running, waiting and so on. 3 Program Counter Program Counter indicates the address of the next instruction to be executed for this process.

4 CPU registers CPU registers include general purpose register, stack pointers and accumulators etc. number of register and type of register totally depends upon the computer architecture. 5 Memory management information This information may include the value of base and limit registers, the page tables, or the segment tables depending on the memory system used by the operating system.This information is useful for deallocating the memory when the process terminates. 6 Accounting information This information includes the amount of CPU and real time used, time limits, job or process numbers, etc. General Purpose Registers. ... For example, when a program is interrupted its state, ie: the value of the registers such as the program counter, instruction register or memory address register - may be saved into the general purpose registers, ready for recall when the program is ready to start again. A stack pointer is a small register that stores the address of the last program request in a stack. A stack is a specialized buffer which stores data from the top down. As new requests come in, they "push down" the older ones.

Process control block includes CPU scheduling, I/O resource management, file management information etc.. The PCB serves as the repository for any information which can vary from process to process. Loader/linker sets flags and registers when a process is created. If that process get suspended, the contents of the registers are saved on a stack and the pointer to the particular stack frame is stored in the PCB. By this technique, the hardware state can be restored so that the process can be scheduled to run again.

Two State Process Model Two state process model refers to running and non-running states which are described below. 1 Running When new process is created by Operating System that process enters into the system as in the running state. 2 Not Running Processes that are not running are kept in queue, waiting for their turn to execute. Each entry in the queue is a pointer to a particular process. Queue is implemented by using linked list. Use of dispatcher is as follows. When a process is interrupted, that process is transferred in the waiting queue. If the process has completed or aborted, the process is discarded. In either case, the dispatcher then selects a process from the queue to execute.

Five States Process Model As a process executes, it changes state. The state of a process is defined as the current activity of the process. Process can have one of the following five states at a time. 1 New The process is being created. 2 Ready The process is waiting to be assigned to a processor. Ready processes are waiting to have the processor allocated to them by the operating system so that they can run. 3 Running Process instructions are being executed i. e. The process that is currently being executed. 4 Waiting The process is waiting for some event to occur such as the completion of an I/O operation. 5 Terminated The process has finished execution.

Thanks

General purpose registers in 8086 microprocessor

1. AX – This is the accumulator 1.AX – This is the accumulator. It is of 16 bits and is divided into two 8-bit registers AH and AL to also perform 8-bit instructions. It is generally used for arithmetical and logical instructions but in 8086 microprocessor it is not mandatory to have accumulator as the destination operand. Example: ADD AX, AX (AX = AX + AX) BX – This is the base register. It is of 16 bits and is divided into two 8-bit registers BH and BL to also perform 8-bit instructions. It is used to store the value of the offset. MOV BL, [500] (BL = 500H)

3. CX – This is the counter register 3. CX – This is the counter register. It is of 16 bits and is divided into two 8-bit registers CH and CL to also perform 8-bit instructions. It is used in looping and rotation. Example: MOV CX, 0005 LOOP 4. DX – This is the data register. It is of 16 bits and is divided into two 8-bit registers DH and DL to also perform 8-bit instructions. It is used in multiplication an input/output port addressing. Example: MUL BX (DX, AX = AX * BX) 5. SP – This is the stack pointer. It is of 16 bits. It points to the topmost item of the stack. If the stack is empty the stack pointer will be (FFFE)H. It’s offset address relative to stack segment. 6. BP – This is the base pointer. It is of 16 bits. It is primary used in accessing parameters passed by the stack. It’s offset address relative to stack segment. 7. SI – This is the source index register. It is of 16 bits. It is used in the pointer addressing of data and as a source in some string related operations. It’s offset is relative to data segment. 8. DI – This is the destination index register. It is of 16 bits. It is used in the pointer addressing of data and as a destination in some string related operations. It’s offset is relative to extra segment.