166
12/9/13 Intr oducti on to Computer Sy stems -- TATA Consul tancy Serv i ces Pv t. Ltd. https://aspire.tcs.com/aspire/cour ses/i ntroduction to computer sy stems/index.html 1/2 Courses Course Objective The Objective of this course is to have an insight that what is a computer, how it works in collaboration with another computer or various devices that connect to it using wires or without them. This collaboration of variou s physically and geog raphic ally distant computers s erv es as the medium for communication, information shar ing and processing. This collaboration of computers forms a computing environment.This course also explains the  ba sic s of system software and the different programs associated with system software like ass emblers,comp ilers, loaders, linkers and interpreter. Course Content 1. Introduction to Computer Techn ology i. What is a Computer ii. Components in a Computer System iii. Computer Language 2. Computer Organization and Architecture i. Organization of a small Computer a. Central Process ing Unit (CPU)  b. Input and Output Devi ces c. Memory Unit ii. Bus iii. Addressing Mode 3. Systems Software i. Assembler Introduction to Computer Systems

Introduction to Computer Systems - Ilpintcs.blogspot.in

Embed Size (px)

Citation preview

Page 1: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 1/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/index.html 1/2

Courses

Course Objective

The Objective of this course is to have an insight that what is acomputer, how it works in collaboration with another computer or variousdevices that connect to it using wires or without them. This collaboration ofvarious physically and geographically distant computers serves as the mediumfor communication, information sharing and processing. This collaboration ofcomputers forms a computing environment.This course also explains the

 basics of system software and the different programs associated with system

software like assemblers,compilers, loaders, linkers and interpreter.

Course Content

1. Introduction to Computer Technology

i. What is a Computer

ii. Components in a Computer System

iii. Computer Language

2. Computer Organization and Architecture

i. Organization of a small Computer

a. Central Processing Unit (CPU)

 b. Input and Output Devices

c. Memory Unit

ii. Bus

iii. Addressing Mode

3. Systems Software

i. Assembler

Introduction to Computer

Systems

Page 2: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 2/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/index.html 2/2

ii. Assembly language

iii. Loaders and Linkers

iv. Compilers

v. Interpreters

4. Introduction To Operating Systems

i. Basic Resources Managed By Operating System

a. Basics Of Memory Management

 b. Process Management

c. File Management

d. Device Management

ii. Resource Sharing Management

5. Computing Environments

i. Mainframe Computing Environment

ii. Networks

iii. Internet

iv. Websites

Courses

Page 3: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 3/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.1_introduction.html 1/2

Course Contents | Prev : Next

1. Introduction

Computers have become an indispensable part of our daily life.Be it connecting with our friends, shopping, gaming, booking tickets, gettingthe score updates, listening music, watching movies as well as live TVprograms and so on (refer Figure 1.1,1.2,1.3 and 1.4). Computers have madeour life not only easier but more interesting also. It is an advantage to us thatwe are living in the period of such technological revolutions. So let us exploreWhat Computer Technology actually is and how it works.

Figure 1.1 : Connecting with friends, shopping, gaming

Figure 1.2 : Booking Tickets, Getting Score updates, listening music

Introduction to Computer Systems

Introduction to Computer

Technology

Page 4: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 4/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.1_introduction.html 2/2

Figure 1.3 : Watch Movies

Figure 1.4 : Live news and TV programs

Course Contents | Prev : Next

Page 5: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 5/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.2_what-is-a-computer_1.html 1/2

Course Contents | Prev : Next

Figure 1.5 : Difference Engine

1.1 What is a Computer

A computer is a machine that executes a set of arithmetic orlogical instructions. The sequence of these instructions can be changed toperform a variety of operations and get various outputs.

For example, it can perform arithmetic instructions (instructionsused for calculations) like Add, Multiply, Subtract or Divide. It can calculateand store 2 + 3 =5 as result in the memory.

Logical instructions have some conditions that evaluate to eithertrue or false (called boolean values). Based on these conditions they derive aresult. For example, We want to calculate the grade of a student based on thetotal marks as follows: If total marks is greater than 180 then Grade of Studentshould be A. Else if total marks is between 150 to 180 then Grade of Studentshould be B. Otherwise (that is both the previous conditions evaluated to false)the Grade of the Student will be C. So, if Tom has his total marks as 175 thenhis grade will be B as the second logical condition evaluates to true in this case.

Simply put, We can describe computer as an electronic devicewhich takes some input like your name and birth date and displays your age.Also it can remember your name and greet you the next time you start it.Hence it uses information to calculate results. Also it stores and remembersinformation.

For example,if you have entered nameas Tom and birth date as1st January 1995 and ifthe current year is 2013,the computer will displaythe result as WelcomeTom. Your age is 18 years.

Theevolution of ComputerTechnology has been aninteresting journey and starts with its pioneer Charles Babbage.

Charles Babbage ,the father of computer, designed the first

Introduction to Computer Systems

Introduction to Computer

Technology

Page 6: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 6/166

Page 7: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 7/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.2_what-is-a-computer_2.html 1/2

Course Contents | Prev : Next

Figure 1.6: Harvard Mark -I :An electro-

mechanical computer

1.1 What is a Computer

HarvardMark-I (refer Figure 1. 6)computer was built as apartnership betweenHarvard and IBM in 1944.It was the firstprogrammable digital

computer made in theU.S.

But it wasnot a purely electroniccomputer. The Mark-Icomputer was constructed out of switches, clutches, relays and rotating shafts.

The machine weighed 5 tons, contained 500 miles of wire, was 51

feet long and 8 feet tall, and had a 50 ft rotating shaft, turned by a 5horsepower electric motor.

The first completely electronic computer is well known as ENIAC(Electronic Numerical Integrator And Calculator - refer Figure 1.9 on nextpage) and was developed by University of Pennsylvania in 1946. This wasfollowed by many evolutions and then came Apple I Computer (referFigure 1.7)in 1976, which could be setup as a Do It Yourself Kit.

Figure 1.7: Apple I Home Computer

Introduction to Computer Systems

Introduction to Computer

Technology

Page 8: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 8/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.2_what-is-a-computer_2.html 2/2

Figure 1.8 : Integrated Circuit

The computers that we use today is a transformation which was aresult of the invention of the microprocessor. A microprocessor (uP) is acomputer that is fabricated on an integrated circuit (IC - refer Glossary).

It is a single integrated circuit that is sufficiently complex enoughto perform the processing part of the information processing cycle (that is thearithmetic and logical calculations discussed above in section 2.1. whereconsidering information like marks, we have derived the grade of a student. ).In other words, it must have enough circuitry to process data, performcalculations, and facilitate interface with memory, input, output and storagedevices(Refer section 2.2 for more details on Input, Output and Storagedevices).

A microprocessor can perform calculation at a super speed withaccuracy. For example,the following calculation is performed really fastproducing accurate results.

147369852 * 58937.42 * 698532.47 * 65893.6598=399788222207794191356873.69597904

Course Contents | Prev : Next

Page 9: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 9/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.2_what-is-a-computer_3.html 1/2

Course Contents | Prev : Next

Few of the latest use of computer technology can be listed as below. (Refer glossary for

details)

  Digital Signature verification

  Natural Language Speech to Text

  Augmented Reality

  Cloud Computing

  Phablets

  Omnidirectional Imaging

  Social Networking

1.1 What is a Computer

Computers had been around for 20 years before the first microprocessor was developed byIntel (one of the leading companies that manufactures hardware) in 1971. The micro in the namemicroprocessor refers to the small physical size. Intel did not invent the electronic computer. But theywere the first to succeed in designing an entire computer on a single chip (IC).

Thus Intel 4004, the first microprocessor (uP) came into existence. The 4004 consisted of2300 transistors and was clocked at 108 kHz (108,000 times per second). Compare this to the 42 milliontransistors and the 2 GHz clock rate ( 2,000,000,000 times per second) used in a Pentium 4. Pioneer 10spacecraft, the man-made object farthest from the earth has Intel's 4004 chips.

Intel followed the 4004 with the 8008 and 8080.The Intel Pentium 4 used in today's PCs isstill compatible with the Intel 8088 used in IBM's first PC.

In 1993 Apple released its first tablet computer named Newton Message Pad 100 and theniPad in 2010 followed by a series of tablets (refer Figure 1. 9)and we still have more innovations on theway.

The evolution of computer has changed it from that of the size of a room to the one that fitsin your palm with multiple times more computational ability and speed.

Figure 1.9: Evolution from ENIAC to Desktop Computer to Laptop and Tablet

Introduction to Computer Systems

Introduction to Computer Technology

Page 10: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 10/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.2_what-is-a-computer_3.html 2/2

Course Contents | Prev : Next

Page 11: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 11/166

Page 12: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 12/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.3_components-in-a-computer-system_1.html 2/2

VI. Motherboard

i. Central Processing Unit

ii. RAM

iii. Ports

VII. Expansion cards

Out of the components listed above, We will focus our discussionon the following parts of hardware:

I. Mouse

II. Keyboard

III. Monitor

IV. Memory Device

V. Central Processing Unit

Figure 1.10: Hardware Components

Course Contents | Prev : Next

Page 13: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 13/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.3_components-in-a-computer-system_2.html 1/2

Course Contents | Prev : Next

  Click: Point to the item, then tap (press and release) the leftmouse button. Like you click links on a website

  Double-click: Here, point to the item and press the left mouse

 button twice in rapid succession.

  Right-click: Point to the item, then tap the right mouse button.

  Drag: Point to an item, then hold down the left mouse button asyou move the mouse. Then release the left mouse button to drop

the item.

  Right-drag: Point to an item, then hold down the right mouse

 button as you move the mouse. Then release the right mouse

 button to drop the item.

Figure 1.11: Mouse

1.2.1.1 Mouse

A Mouse is an input device and probably has at least two buttonson it. The left button is called the primary mouse button, the right button iscalled the secondary mouse button or just the right mouse button. There can

 be a small wheel called Scroller between the two mouse buttons. The mousecan be used as follows:

Introduction to Computer Systems

Introduction to Computer

Technology

Page 14: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 14/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.3_components-in-a-computer-system_2.html 2/2

Course Contents | Prev : Next

Page 15: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 15/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.3_components-in-a-computer-system_3.html 1/2

Course Contents | Prev : Next

  The function keys have some definite function depending on the

application or program that you are using on your computer.

There are twelve function keys from F1 to F12. F1 can always be

used to display help for your current application, F2 can be used

to change name of any file, F3 can be used to search any text or

file on the computer. Similarly each function key can be used to

perform a specific action.

  The direction keys or Arrow keys can be used to move the typing

cursor (the blinking short vertical line on monitor that indicates

the position of text insertion) at desired location.

  The numeric keys can be used to enter numbers if we have

pressed the Num-Lock key which can be indicated by the light

on Lock Key indicators. Otherwise, the Numeric keys behave as

direction keys and allows you to change your cursor location.

  Ctrl and Alt keys are generally used in combination with other

keys to perform some specific task that is, you can press all

these combination keys together to produce a single input.

  Shift Key is also a special key which can be used to change the

lower case letter to upper case and vice-versa while typing. It is

also used to display the parenthesis (), the question mark (?) ,

the exclamation point (!), and the colon(:). Also, it helps in

displaying other special characters like @,$,# that are present on

the horizontal numeric keypad.

  Tab key allows you to move the cursor by a fixed number of

spaces. It is helpful if you want to write something in a tabulated

form. It can also be used to move to the next input field while

1.2.1.2 Keyboard

A Keyboard is an input device and is usually used when we needto type some text input or fill a form. Various keys are explained below.

Introduction to Computer Systems

Introduction to Computer

Technology

Page 16: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 16/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.3_components-in-a-computer-system_3.html 2/2

filling a form.

  Caps Lock Key sets an input mode in which typed letters are

uppercase(in capital letters) by default . The keyboard remains

in caps lock mode until the key is pressed again. It can be useful

when you are typing a heading or filling a form which requires

only capital letters.

  Enter Key causes a form, or any other computer operation to

perform its default function. This is typically an alternative to

pressing an OK button. It can also be used to move to next line

starting position while typing.

  Esc (Escape) key can be used to cancel a task or to go back to a

previous task.

Figure 1.12: Keyboard

Course Contents | Prev : Next

Page 17: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 17/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.3_components-in-a-computer-system_4.html 1/1

Course Contents | Prev : Next

1.2.1.3 Monitor

Also called VDU (Visual Display Unit), the Monitor is theprimary output device. It looks like a Television and has the similar purpose ofdisplaying videos or output of programs. Monitors are built using technologieslike Cathode Ray Tube (CRT monitors- refer Glossary) and Thin FilmTransistor Liquid Crystal Display (TFT- LCD monitors - refer Glossary) . Wenow generally have these monitors or screens made of TFT-LCD.

Figure 1.13: Computer Monitor

Course Contents | Prev : Next

Introduction to Computer Systems

Introduction to Computer

Technology

Page 18: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 18/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.3_components-in-a-computer-system_5.html 1/2

Course Contents | Prev : Next

These are the devices which store the information.

The term primary memory is used for the information in physicalsystems which functions at high-speed. For example, it is capable ofperforming complex calculations and displaying the results at the same time.

Secondary memory devices are physical devices for program anddata storage which are slow to access but offer higher memory capacity.

Primary memory stored on secondary memory is called virtualmemory.

RAM (refer Figure 1. 14, Glossary), and Computer cache (referGlossary)are examples of Primary memory storage. Magnetic tapes, Compact

Disks (CDs), Digital Versatile Disks(DVDs - refer Figure 1. 15) are all examplesof Secondary Memory Storage.

The memory is organized into memory cells each storing one binary bit (0 or 1). The memory cells are grouped into words of fixed length, forexample 1, 2, 4, 8, 16, 32, 64 or 128 bit. Each word in the memory can beaccessed by a binary address (refer Glossary)of N bit, making it possible tostore 2 raised by N words.

Figure 1.14: RAM Storage Device

1.2.1.4 Memory Devices

Introduction to Computer Systems

Introduction to Computer

Technology

Page 19: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 19/166

Page 20: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 20/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.3_components-in-a-computer-system_6.html 1/2

Course Contents | Prev : Next

Figure 1. 16 : Dual Core Processor

1.2.1.5 Central Processing Unit

The CentralProcessing Unit (CPU) orthe computer processorperforms calculations,processes information,stores data in memory

and controls the flow ofdata. The conventionalprocessors are small insize and have all thecircuits integrated on a single chip. Because of its small size, the processor isalso known as microprocessor. It is also called the Brain of computer.

  A minimal hypothetical microprocessor might only include an

arithmetic logic unit (ALU) and a control logic section.

  The ALU performs mathematical operations such as addition of

two numbers, and logical operations such as AND or OR (refer

Glossary). Each operation of the ALU sets one or more flags in a

status register ( a small memory within the CPU), which

indicates the result of the last operation.

  The control logic section retrieves instruction codes from

memory, and initiates the sequence of operations that the ALUrequires to carry out the instruction. It may happen that a single

operation code affects many registers (refer Glossary) at the

same time. It is like executing a flow chart (refer Glossary) and

depending on the condition encountered in the flow chart an

appropriate decision will be taken and the flow will jump to

some other operation to be triggered in the ALU.

  Garrett AiResearch's Central Air Data Computer (CADC) (1968),Texas Instruments (TI) TMS 1000 (1971 September), and Intel's

4004 (1971 November) are the three projects that delivered a

microprocessor at about the same time.

Introduction to Computer Systems

Introduction to Computer

Technology

Page 21: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 21/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.3_components-in-a-computer-system_6.html 2/2

  We also have multi-core processors that have a single chip

containing more than one microprocessor. This effectively

multiplies the processor's potential performance by the number

of cores (the independent actual central processing units).

  The first dual-core processors (microprocessors having two

separate microprocessors on single Integrated Chip -refer

Figure 1. 16 ) for personal computer were announced in 2005.

  As of 2013, dual-core and quad-core processors (microprocessors

having four separate microprocessors on single Integrated Chip)

are widely used in home PCs and laptops while six, eight, ten,

twelve, and sixteen-core processors are common in the

professional and enterprise markets with workstations and

servers (refer Glossary).

Course Contents | Prev : Next

Page 22: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 22/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.3_components-in-a-computer-system_7.html 1/1

Course Contents | Prev : Next

1.2.2 Software

Software is the non-material part of computer like data,programs, protocols, etc. It is a non-physical component that runs on yourcomputer and can be changed by a set of programmed instructions.

For example you watch a movie on a DVD using the DVD drive inyour computer. Here the DVD and DVD drive are both hardware, but the

program in your computer that you use to watch this movie is called software.Thus as movie is stored on a DVD, similarly there is a program like MediaPlayer stored on your computer to watch that movie. The application that youare currently using to read this text is also a software.

Software can be categorized into three types as follows:

  System Software

  Utility Software

  Application Software

Course Contents | Prev : Next

Introduction to Computer Systems

Introduction to Computer

Technology

Page 23: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 23/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.3_components-in-a-computer-system_8.html 1/3

Course Contents | Prev : Next

1.2.2.1 System Software

It is the software used to manage and control the hardwarecomponents and which allow interaction between the hardware and the othertypes of software (refer Figure 1. 17). The most obvious type of systemsoftware is the computer's operating system. We will see Operating System indetail.

All the programs and software run on computer using the main software – TheOperating System. Some popular modern operating systems are Android, iOS,Unix, Linux, Mac OS X, Microsoft Windows and IBM z/OS (refer Figure 1. 18).

Figure 1.17 : System Software- Operating System Layer

Figure 1.18 : System Software- Operating Systems

Operating system has various categories as listed below:

Introduction to Computer Systems

Introduction to Computer

Technology

Page 24: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 24/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.3_components-in-a-computer-system_8.html 2/3

  Real-time : Real-time operating systems often use specialized

scheduling algorithms (refer Glossary). The main objective of

real-time operating systems is their quick and predictable

response to events. Their design is called event-driven or time-

sharing design. An event-driven design system switches

 between tasks based on their priorities or external events while

time-sharing operating systems switch tasks based on clock

interrupts.

  Multi-user : A multi-user operating system allows multiple users

to access a computer system at the same time. Time-sharing

systems or Internet servers are examples of multi-user systems

as they enable multiple-user access to a computer through the

sharing of time.

  Multi-tasking : A multi-tasking operating system allows more

than one program to run at a given time. Multi-tasking can be of

two types: pre-emptive and co-operative.

  Pre-emptive multitasking is the act of temporarily

interrupting a task being carried out by a computer

system, with the intention of resuming the task at a later

time. Unix-like operating systems such as Solaris andLinux support pre-emptive multitasking. For example, you

are talking on a land line phone to someone and the door

 bell rings. In this case you would keep the phone caller on

hold and visit the person on door and then come back and

continue with the telephone call. It shows here that the

ringing of the door bell was a task having higher priority

for which you could suspend the current normal priority

phone call.

  Cooperative multitasking is achieved by relying on each

process to give time to the other processes in a defined

manner. 16-bit versions of Microsoft Windows (Microsoft

Windows 1.0 to 3.0 and 9x versions which still support

the older windows versions. These systems usually hang

or stop responding in case one running program does not

cooperate to yield the processor to some other program)used cooperative multi-tasking. Mac OS versions before

to OS X used to support cooperative multitasking.

Page 25: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 25/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.3_components-in-a-computer-system_8.html 3/3

  Single-tasking : A Single Tasking system has only one running

program (refer Glossary).The Palm OS for Palm handheld

computers is an example of a single-user and single-task

operating system.

  Distributed : A distributed operating system manages a group of

independent computers and makes them appear to be a single

computer. The networked computers working as a group in

cooperation, make a distributed system.

  Embedded : Embedded operating systems are designed to be

used in embedded computer systems. These are designed to

operate on machines like PDAs with less autonomy. They

operate with a limited number of resources, are very compact

and extremely efficient by design. Minix 3 and Windows CE areexamples of embedded operating systems.

Course Contents | Prev : Next

Page 26: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 26/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.3_components-in-a-computer-system_9.html 1/1

Course Contents | Prev : Next

1.2.2.2 Utility Software

It is software such as anti-virus software like Norton and McAfee,or Microsoft Security Essentials which help to maintain and protect thecomputer system but may not directly interface with the hardware. Utilitieslike Winzip help to combine and compress data files so that they occupy lessmemory and can be easily sent in mails.

1.2.2.3 Applications Software

Also known as apps, these are designed to allow the user of thesystem complete a specific task or set of tasks. Apps include programs likeweb browsers, games and office software. They are usually the reason you

 bought the computer system in the first place. Refer Figure 1. 19.

Figure 1.19: Application Software

Course Contents | Prev : Next

Introduction to Computer Systems

Introduction to Computer

Technology

Page 27: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 27/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.3_components-in-a-computer-system_10.html 1/2

Course Contents | Prev : Next

1.2.3 Firmware

It is the combination of persistent memory (long term orpermanent storage which is preserved even when the power supply isunavailable), program code and the data stored in it.

  It is software stored in hardware.

  Examples include embedded systems like traffic lights andremote control.

  Let us understand firmware using remote control. When you

open a remote control you see a set of circuits which along with

the body of the remote control constitutes the hardware part.

Now you can move or switch channels using the remote control

or you can put a child lock for the same. Also you can use the

swap button on the remote control to go back to the previousviewed channel. So the remote control is able to remember that

which is the most recent channel you viewed or your color

preferences. This part constitutes the software and data, stored

in your remote control.

  Changing the firmware of a device may rarely or never be done

during its lifetime. Some firmware memory devices are

permanently installed and cannot be changed at all. Devices likeprinters, scanners, cameras and USB drives have firmware

stored internally.

Introduction to Computer Systems

Introduction to Computer

Technology

Page 28: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 28/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.3_components-in-a-computer-system_10.html 2/2

Figure 1.20 : Firmware

Course Contents | Prev : Next

Page 29: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 29/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.4_computer-language.html 1/2

Course Contents | Prev : Next

1.3 Computer Language

The term computer language includes a wide variety of languagesused to communicate with computers (refer Figure 1. 21). Programminglanguages are a subset of computer languages. For example, HTML is amarkup language (refer Glossary) and a computer language, but it is notconsidered a programming language.

Machine code is a computer language. It is a sequence of binary

digits (binary digits contain only 0 and 1) which instructs the computer to dothe required task. It can technically be used for programming (as for AltairBASIC), but a sequence of binary numbers can not be considered as aprogramming language.

Programing language is a convention based set of instructionsthat you execute on the machine to store or manipulate any information or toperform any logical operation.

Programing languages can be further categorized as follows:

  Low Level Programing Languages : These languages are very

close to the hardware. They can be directly converted to

machine code without any intermediate steps and hence have

faster execution. For example : Assembly language. C language

can be used for low level programing as it can directly interface

with memory, hardware and the CPU. It can also be used to

create Operating Systems, and because of its user-friendly

programing features, it can be considered as Middle Level

Language also.

  High Level Programing Languages : They provide a very high

level of abstraction from the detail of memory management, and

may go through two stages of processing before they can be

understood and executed by the computer. These stages arecalled Compilation and Interpretation (refer Glossary). They are

easier and have more user-friendly programing features. For

example : java, c++,c#.

Introduction to Computer Systems

Introduction to Computer

Technology

Page 30: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 30/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.4_computer-language.html 2/2

  Scripting Languages : These languages are directly interpreted or

executed by other programs or on-the fly and have a relatively

simple syntax, easy to pick up and program in. They are called

scripting languages because they are used to write scripts or

programs that automate the execution of tasks which could

alternatively be executed one-by-one by a human operator.Scripting languages are very useful for web-based programing.

For example : javascript, perl.

Figure 1.21 : Computer Languages

Course Contents | Prev : Next

Page 31: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 31/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.5_summary.html 1/2

Course Contents | Prev : Next

Summary

A Computer is a machine that executes a set of arithmetic orlogical instructions and usually provides a visual output. It has evolved fromCharles Babbage's Difference Engine design to the modern day Laptops andTablets.

The different Components of a Computer are :

  Hardware – The tangible or physical parts of the computer.

  Mouse – the device used for pointing the

target or double clicking a folder to open it.

  Keyboard – the primary input device with all

alphabets and numbers on it.

  Screen – the primary output device which is

like the TV screen.

  Memory devices store all the information and

data.

  Microprocessor or Central Processing Unit -

the electronic brain of computer responsible

for all computation logic.

  Software – It is the non-tangible part of computer like programs

and applications.

  System Software - It is a the main software on

the computer which enables execution of

other programs and software. For example -

Operating system.

  Utility Software - Used as an add on or

protection of computer from virus attacks.

Introduction to Computer Systems

Introduction to Computer

Technology

Page 32: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 32/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.5_summary.html 2/2

For example - Anti-virus software.

  Application Software – Apps help in

performing any task on the computer. For

example - Web browser internet use.

  Firmware – The embedded systems that store software and datainside the hardware as the hardware's inseparable part.

Course Contents | Prev : Next

Page 33: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 33/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.6_glossary.html 1/4

Course Contents | Prev : Next

Glossary

Term used Description

And – OR

logical

operators

If we have two expressions expr1, expr2 then logical AND

will always check that if both expressions are true only then

the logical result will be true. Also if expr1 is false then expr2

is not checked at all and result becomes false whereas in

case of logical OR even if either of expressions is true, theresult will be true and only if both expressions are false, the

result will be false

Augmented

Reality

Augmented Reality (AR) is a direct or indirect live view of a

physical real-world environment whose elements are

augmented by computer-generated sensory input like sound,

graphics or video.

Binary AddressIt is a memory address that is represented in the form of a

 binary number (i.e. 0 or 1).

Cache

A cache is a component that transparently stores data so

that future requests for that data can be served in a faster

way. The data stored within a cache are the values that have been computed earlier or duplicates of original values that

are stored elsewhere.

Cathode Ray

Tube

The cathode ray tube (CRT) is a vacuum tube containing a

source of electrons or electron emitter and a fluorescent

screen used to view images. In television sets and computer

monitors, the front area of the tube is repetitively scanned

systematically in a fixed pattern called a raster. Images areproduced by controlling the intensity of the three electron

 beams (red, green, and blue).

Introduction to Computer Systems

Introduction to Computer

Technology

Page 34: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 34/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.6_glossary.html 2/4

Cloud

Computing

Cloud computing is the use of computing resources

(hardware and software) that are delivered as a service over

a network (typically the Internet).

Compilation

A computer process that converts the human readable form

of code written in any programing language into machine

code that is the form that can be understood by the

computer.

Digital

Signature

Verification

It is a mathematical scheme or program for checking the

authenticity of an electronically generated signature. It is

especially used in cases of financial transactions where any

forgery or tampering is very important to be detected.

Expansion

Cards

It is a printed circuit board and can be inserted into an

electrical connector or expansion slot on the motherboard of

a computer. The primary purpose of an expansion card is to

provide or expand on features not offered by the

motherboard.

Flow Chart

A flowchart is a type of diagram that represents an

algorithm or process. It shows the steps as boxes of various

shapes, and connects them with arrows in a certain order.

This representation gives a step-by-step solution to a given

problem. Process operations are represented in the boxes

and arrows connecting them represent the control flow.

Flowcharts are used for analyzing, designing, documenting

as well as managing a process.

Integrated

Circuit

An integrated circuit is an electronic circuit designed to

perform some function in which the electronic components

(i.e. resistors, transistors, diodes, capacitors, etc.) are

miniaturized into a small silicon (a material found in quartz

rocks) chip, and are interconnected through tiny aluminum

strands. Integrated circuits are also referred to asmicrochips or IC chips.

An interpreter is a computer program that executes

Page 35: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 35/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.6_glossary.html 3/4

Interpretation

instructions written in a programming language. It uses one

of the following strategies for program execution:

Execute the source code directly

Translate source code into some efficient intermediate

representation and immediately execute this

Explicitly execute stored precompiled code generated by a

compiler

Markup

Language

A markup language is a combination of words and symbols

which give instructions on how a document should appear.

For example, <i> tag may be used to indicate that words are

written in italics.</i>

Natural

Language

Speech to Text

Natural language processing (NLP) is a field of computer

science and linguistics concerned with the interactions

 between computers and human (natural) languages. It

enables computers to derive meaning and textual

representation from a given sound clip of human speech. It

can then use this text for further processing like in case of a

phone it can dial a spoken number, or search on internet for

the name of restaurant you specified as voice input.

Omnidirectional

Imaging

An omnidirectional imaging apparatus obtains images over

an entire hemispherical field and uses a mapping matrix to

define a relationship between pixels in a user-defined

perspective or panoramic viewing window and pixel

locations on the original omnidirectional image. This allows

the computation of non-distorted images in real-time. For

example - panorama photography in some latest mobilephones.

Phablet

It is an informal term for consumer touch-screen devices

with screens that are between five to seven inches. These

devices have the combined capabilities of a smart phone and

mini tablet. It may also incorporate a stylus. A phablet is

usually larger than smartphones, but smaller than tablet or

mini-tablet.

A program is a sequence of instructions written to perform a

Page 36: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 36/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module1/session1.6_glossary.html 4/4

Program specified task with a computer.

RAM

Random-access memory (RAM) is a type of computer data

storage. It allows stored data to be accessed quickly in any

random order.

Scheduling

Algorithms

Scheduling algorithms are the steps by which various

computer processes or data flows are given access to system

resources like processor time and input/output channels.

ServerA server is a computer dedicated to run one or more services

(as a host), to serve the needs of the users of other

computers on a network.

Social

Networking

Social networking is an online service or site that focuses on

facilitating the building of social relations among people

who may share interests, hobbies, activities, backgrounds,

or real-life connections. It is now extensively used for

promoting various business and supporting causes.

Thin Film

Transistor

Liquid Crystal

Display

A liquid-crystal display (LCD) is a flat panel display that

uses the light modulating properties of liquid crystals. A

thin-film transistor (TFT) used in LCD monitors is a special

kind of transistor made by depositing thin films of a

semiconductor active layer over glass.

Workstation

A workstation is a computer designed for technical,

scientific or clerical applications. It is intended primarily to

 be used by one person at a time and is usually connected

with other computers.

Course Contents | Prev : Next

Page 37: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 37/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.1_introduction.html 1/1

Course Contents | Prev : Next

2. Introduction

Computer Technology after its evolution, has made incredibleimprovement. In early stage of evolution, the computers were not able to storedata, the size of the computer was a very huge one with very lesscomputational power.

Now a days, a personal computer has more computational power,more main memory, more disk storage, smaller in size and is available in

affordable cost. The advances in the technology brought a rapid rate ofimprovement in building computers and innovation in computer design.

Course Contents | Prev : Next

Introduction to Computer Systems

Computer Organization and

Architecture

Page 38: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 38/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.1_organization_of_a_small_computer.html 1/1

Course Contents | Prev : Next

2.1 Organization of a Small Computer

The model of a computer consists of four basic units, shown infollowing figure (Figure 2.1). The basic units are :

I. Central Processing Unit (CPU)

II. Input and Output Devices

III. Memory Unit

Figure 2.1 : Basic unit of a Computer

Course Contents | Prev : Next

Introduction to Computer Systems

Computer Organization and

Architecture

Page 39: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 39/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.2_central_processing_unit_1.html 1/1

Course Contents | Prev : Next

2.1.1 Central Processing Unit (CPU)

Central processing unit is also known as a brain of computer. It isa hardware in a computer that carries out the instructions of a computerprogram by performing the logical, arithmetical and input/output operationsof the system.

CPU consist of three basic blocks (refer Figure 2.2):

a. Arithmetic Logical Unit

 b. Control Unit

c. Registers

Figure 2.2 : Central Processing Unit

Course Contents | Prev : Next

Introduction to Computer Systems

Computer Organization and

Architecture

Page 40: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 40/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.2_central_processing_unit_alu_1.html 1/2

Course Contents | Prev : Next

2.1.1 Central Processing Unit (CPU)

a. Arithmetic Logic Unit (ALU)

ALU performs mathematical,logical and decision operations in acomputer. After the processing is done by the ALU, the result is sent to thecomputer memory.

In some computer processors, ALU is divided into two distinct parts:

i. Arithmetic Unit

ii. Logical Unit

i. Arithmetic Unit(AU)

Arithmetic Unit performs arithmetic operations.

I. Addition(C=A + B)

II. Subtraction(C=A - B)

III. Multiplication(C = A * B)

IV. Division(C = A / B)

  The ALU has got two input parameters named as A and B and

one output storage parameter, named as C.

  It perform the operation as: C = A op B (where op stands for

operand which can be either of the given operations)

The input data are stored in parameters A and B, and accordingto the operation specified, the ALU perform the operation and put the result inparameter C.

Introduction to Computer Systems

Computer Organization and

Architecture

Page 41: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 41/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.2_central_processing_unit_alu_1.html 2/2

Course Contents | Prev : Next

Page 42: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 42/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.3_central_processing_unit_alu_3.html 1/2

Course Contents | Prev : Next

2.1.1 Central Processing Unit (CPU)

ii. Logical Unit(LU)

Logical Unit performs the logical operations. ALU is having threelogical operands:

I. AND

II. OR

III. NOT

I. AND

The AND operator is represented by '&' and performs logicalconjunction on two Boolean expressions.

  If both expressions are True, then the 'AND' returns True.

  If either or both expressions are False, then 'AND' returns False.

As shown in the given table (Figure 2.3) : C = A & B

A B C

0 0 0

0 1 0

1 0 0

1 1 1

Figure 2.3 : Logical Unit - AND

where 0 – means false and 1 – means true.C will be 0 when either of the value is 0 which is false.C will be 1 when both the values are 1 which is true.

Introduction to Computer Systems

Computer Organization and

Architecture

Page 43: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 43/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.3_central_processing_unit_alu_3.html 2/2

Course Contents | Prev : Next

Page 44: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 44/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.3_central_processing_unit_alu_5.html 1/1

Course Contents | Prev : Next

2.1.1 Central Processing Unit (CPU)

II. OR

The OR operator represented by '|' performs logical disjunctionon two Boolean expressions.

  If either expression is True, 'Or' returns True.

  If neither expression is True, 'Or' returns False.

As shown in the given table (Figure 2.4) : C = A | B

A B C

0 0 0

0 1 1

1 0 1

1 1 1

Figure 2.4 : Logical Unit - OR

where 0 – means false and 1 – means true.C will be 0 when both the values are 0 which means false.

C will be 1 when either of the value is 1 which means true.

Course Contents | Prev : Next

Introduction to Computer Systems

Computer Organization and

Architecture

Page 45: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 45/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.3_central_processing_unit_alu_6.html 1/1

Course Contents | Prev : Next

2.1.1 Central Processing Unit (CPU)

III. NOT

The NOT operator is represented by '!' and performs the NOToperation on a single operand.

  It checks the status of a current operand and reverses the valueof a resultant operand.

  If the value of an operand is true then it is reversed to false.

  If the value of an operand is false then it is reversed to true.

As shown in the given table (Figure 2.5) : B = !A

A B

0 1

1 0

Figure 2.5 : Logical Unit - NOT 

where 0 – represents false and 1 – represents true.

B will be 1 if A is 0 i.e. true.B will be 0 if A is 1 i.e. false.

Course Contents | Prev : Next

Introduction to Computer Systems

Computer Organization and

Architecture

Page 46: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 46/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.4_central_processing_unit_cu.html 1/1

Course Contents | Prev : Next

2.1.1 Central Processing Unit (CPU)

b. Control Unit(CU)

The Control Unit extract instructions from memory, decodes andexecutes them, and then sends the necessary signals to the ALU to perform theoperations required.

It is a circuitry that directs operations within the computer's processor

 by directing the input and output of a computer system. The processor then controlshow the rest of the computer operates (giving directions to the other parts andsystems). It works by gathering input through a series of commands it receives frominstructions in a running programs and then outputs those commands into controlsignals that the computer and other hardware attached to the computer carry out.The control unit basically controls the operations inside the CPU and "directingtraffic" in a sense.

Figure 2.6 : Working of Control Unit

The control unit fetches instruction from main memory then decodesthose instructions into commands. ALU then executes those commands and it storesthe result in main memory (As shown in Figure 2.6).

Course Contents | Prev : Next

Introduction to Computer Systems

Computer Organization and

Architecture

Page 47: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 47/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.4_central_processing_unit_reg_1.html 1/2

Course Contents | Prev : Next

2.1.1 Central Processing Unit (CPU)

c. Registers

Registers are contained within the central processing unit,andholds the data involved in the computation being performed. The size of theregister determines the processing capabilities of the CPU. The amount ofinformation that can be held in a register at a time for processing is known asRegister S ize. The larger the register size, the faster is the speed of processing.

Registers are the fastest and most costliest storage units in acomputer. Computer instructions are stored in consecutive memory locationsand are executed sequentially one at a time.

The control unit reads an instruction from a specific address inmemory and executes it. Then it continues by reading the next instruction insequence and executes it. In this type of instruction sequencing, a counter isneeded to calculate the address of the next instruction after execution of thecurrent instruction.

It is necessary to provide a register in the control unit for storingthe instruction code after it is read from memory. The computer needsprocessor registers(refer to Glossary) for manipulating data and a register forholding a memory address.

Registers Performs following operations:-

  Fetch - The Fetch Operation is used  for taking the instructions

given by the user.

  Decode - The Decode Operation is used for interpreting the

meaning of the instructions fetched by registers. Decoding

instructions means the CPU will find out which operation is to

 be performed on the instructions.

  Execute - The Execute Operation is performed by the CPU and

the results produced by the CPU are then stored into the

Introduction to Computer Systems

Computer Organization and

Architecture

Page 48: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 48/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.4_central_processing_unit_reg_1.html 2/2

memory and after that they are displayed on the user screen.

Course Contents | Prev : Next

Page 49: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 49/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.4_central_processing_unit_reg_2.html 1/2

Course Contents | Prev : Next

2.1.1 Central Processing Unit (CPU)

In given table (Figure 2.7), registers are listed in table with a briefdescription of their function and the number of bits that they contain.

  The capacity of memory unit is 4096 words and each word

contains 16 bits.

  12 bits instruction word are needed to specify the address of an

operand.

  This leaves 3 bits for operation part of the instruction and bit to

specify a direct or indirect address.

  The data register (DR) holds the operand read from memory.

  The accumulator register (AC) is a general purpose processingregister.

  The instructions read from memory are placed in the instruction

Register

Symbol

Number of

BitsRegister Name Function

DR 16 Data Register Holds memory operandAR 12 Address Register Holds address for memory

AC 16 Accumulator Processor Register

IR 16Instruction

RegisterHolds instruction code

PC 12 Program CounterHolds address for

instruction

TR 16Temporary

Register Holds temporary data

INPR 8 Input Register Holds input character

OUTR 8 Output Register Holds output character

Figure 2.7 : Register Details

Introduction to Computer Systems

Computer Organization and

Architecture

Page 50: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 50/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.4_central_processing_unit_reg_2.html 2/2

register (IR).

  The temporary register (TR) is used for holding temporary data

during the processing.

  The input register (INPR) receives an 8-bit character from an

input device.

  The output register (OUTR) holds an 8-bit character for an

output device.

  A program counter (PC) is a register in a computer processor

that contains the address of the instruction being executed at

current point of time. As each instruction is fetched, the

program counter increases its stored value by 1 and points to

the next instruction in sequence. When the computer is reset or

restarts, the program counter normally reverts to 0.

  An address register (AR) is a high-speed circuit that holds the

addresses of data to be processed or of the next instruction to be

executed.

Course Contents | Prev : Next

Page 51: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 51/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.5_input_unit.html 1/2

Course Contents | Prev : Next

2.1.2 Input and Output Devices

Input and Output devices can be of three types

a. Input Unit/Devices

An input device is a hardware device that sends data to thecomputer.

  Without input device, a computer would only be a display device

and would not allow users to interact with it.

  With the help of input device, data from outside can be supplied

to the computer.

  Program or data is read into main storage using input device or

secondary storage under the control of CPU.

Figure 2.8 : Input Unit

Following are some of input devices:

  Keyboard

  Mouse, touchpad or any other pointing device

  Barcode reader

  Keyboard

  Biometrics (e.g. fingerprint scanner)

Introduction to Computer Systems

Computer Organization and

Architecture

Page 52: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 52/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.5_input_unit.html 2/2

  Digital camera and Digital Camcorder

  Touch screen

  Webcam

The drives such as a CD-ROM, DVD are capable of sendinginformation to computer, but they are not input devices. These devices areconsidered as storage devices.

Course Contents | Prev : Next

Page 53: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 53/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.5_output_unit.html 1/1

Course Contents | Prev : Next

2.1.2 Input and Output Devices

b. Output Unit/Devices

Any information that has been processed and comes from acomputer is considered as an output.

  When someone views the output, they're viewing it on an output

device such as a computer monitor or a hard copy print out.

  The figure (Figure 2.9), is an example of output being sent from

the computer to a printer.

Figure 2.9 : Output Unit

  The computer results are provided to the user with the help of

output unit, the results can also be stored in storage device

permanently for future use.

  Output data from main storage is sent to output device under the

control of CPU output instructions.

  Example of output devices:

  Printer

  Monitor etc.

Course Contents | Prev : Next

Introduction to Computer Systems

Computer Organization and

Architecture

Page 54: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 54/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.6_input_output_devices.html 1/2

Course Contents | Prev : Next

2.1.2 Input and Output Devices

c. Input/Output Devices

Also referred to as a IO device, is a hardware device that acceptsinputted information and also has the capability to output that information.Examples of input/output devices are

  Floppy diskette drive(Figure 2.10)

  CD-ROM drives(Figure 2.11)

  Modem(Figure 2.12)

  USB thumb drives etc.(Figure 2.13)

Figure 2.10 : Floppy diskette

Figure 2.11 : CD-ROM

Figure 2.12 : Modem

Introduction to Computer Systems

Computer Organization and

Architecture

Page 55: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 55/166

Page 56: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 56/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.7_memory_1.html 1/2

Course Contents | Prev : Next

2.1.3 Memory

Memory unit is an essential component in any computer, neededto store the data and program. CPU works with information stored in memoryunit. It is also termed as primary memory or main memory.

A very small computer with a limited application may be able tofulfill its intended task without the need of additional storage capacity. Most

general purpose computer is run more efficiently if it is equipped withadditional storage beyond the capacity of main memory.

There is just not enough in one memory unit to accommodate allthe programs used in typical computer, users accumulate and continue toaccumulate large amounts of data processing software. There, it is moreeconomical to use low cost storage devices to serve as a backup for storing theinformation that CPU is not using currently.

The unit that communicates directly with CPU is called the mainmemory. The most common memory device used are magnetic disks and tapes,used for storing large data files, system programs and other backupinformation. Only data currently needed by the processor reside in mainmemory. Rest of the information is stored in auxiliary memory and transferredto main memory when required.There are following types of Memories:

a. Main memoryi. RAM (Random Access Memory)

ii. ROM (Read Only Memory)

 b. Auxiliary Memory

i. Magnetic Disks

ii. Magnetic tapes etc.

Introduction to Computer Systems

Computer Organization and

Architecture

Page 57: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 57/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.7_memory_1.html 2/2

Course Contents | Prev : Next

Page 58: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 58/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.7_memory_2.html 1/1

Course Contents | Prev : Next

2.1.3 Memory

a. Main Memory

The main memory is central storage unit in a computer system. Itis used to store programs and data being used during computer operation.Following comes under Main Memory:

  RAM (Random Access Memory):

RAM, also known as Volatile memory that loses its contents

when the computer or hardware device loses power.

  ROM(Read Only Memory):

ROM is used for storing programs that are permanently in a

computer and for tables of constants that do not change its

value once the production of computer is completed.

Course Contents | Prev : Next

Introduction to Computer Systems

Computer Organization and

Architecture

Page 59: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 59/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.7_memory_3.html 1/2

Course Contents | Prev : Next

2.1.3 Memory

b. Auxiliary Memory

An Auxiliary Memory, also known as high-speed memory bank isused in mainframes and supercomputers(refer to Glossary). The majordifference between main memory and auxiliary memory is that CPU directlyaccess the main memory but the auxiliary memory is not accessed by the CPUdirectly. For this the data is first transferred from auxiliary memory to mainmemory and then from main memory the data is transferred to the CPU forfurther processing.

The most commonly used auxiliary memory devices in thecomputer systems are magnetic disks and magnetic tapes.There are following auxiliary memories:

  Magnetic Disk

  A magnetic disk is a circular plate made up

of metal or plastic coated with magnetized

material.

  Both the sides of disk are used and several

disks may be stacked on one spindle with

read/write heads available on each surface.

  Bits are stored on magnetized surface in

spots along concentric circles called tracks.

  Tracks are divided into sections called

sectors.

  Disk that are attached and cannot removed

 by occasional user are called Hard disk.

  A disk drive with the removable disks are

called a floppy disks.

Introduction to Computer Systems

Computer Organization and

Architecture

Page 60: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 60/166

Page 61: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 61/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.8_bus_1.html 1/2

Course Contents | Prev : Next

2.2 Bus

A bus enables a computer processor to communicate with thememory or a video card.

  The processor, main memory and Input/Output devices can be

interconnected through common data communication lines

which are termed as a common bus, as shown in Figure 2.10.

  The primary function of common bus is to provide a

communication path between devices for transfer of data.

  The bus include control lines needed to support interrupts and

arbitration.

Basically, all computers utilize two types of bus:

I. Internal Bus : also known as local bus,enables a

communication between internal components such as a

computer video card and memory.

II. External Bus : also known as expansion bus, communicates

with external components such as a USB or SCSI

device(refer to Glossary).

The bus lines which are used to transfer data are grouped into three categories:

I. Data Bus

II. Address Bus

Introduction to Computer Systems

Computer Organization and

Architecture

Page 62: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 62/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.8_bus_1.html 2/2

III. Control Bus

Course Contents | Prev : Next

Page 63: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 63/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.8_bus_2.html 1/2

Course Contents | Prev : Next

2.2 Bus

  Data Bus

  Data bus is a computer subsystem that allows

transferring of data from one component to another on a

motherboard, or between two computers.

  This includes transferring data to and from the memory,

or from the central processing unit (CPU) to other

components.

  Address Bus

  An address bus is used to specify a physical address.

  When a processor or Direct memory access (DMA)enabled device needs to read or write to a memory

location, it specifies that memory location on the address

 bus.

  Control Bus

  A control bus is a part of a computer bus, used by CPUs

for communicating with other devices within thecomputer.

  It carries commands from the CPU and returns status

signals received from the devices.

Introduction to Computer Systems

Computer Organization and

Architecture

Page 64: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 64/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.8_bus_2.html 2/2

Figure 2.14 : Working of Bus

Course Contents | Prev : Next

Page 65: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 65/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.9_addressing_mode.html 1/1

Course Contents | Prev : Next

2.3 Addressing Modes

Addressing modes are the ways how the address of anobject/operand is being accessed.

  In other words, 'The strategy to identify WHERE the operand is

located.'

  In computer architecture every tasks user attempts to perform is

converted into an instruction(i.e Machine codes) and that

instruction consists of some operands to work on it .

Ex: Consider this machine code ADD A , B here ADD is opcode and A,B areoperands. This means add A and B and store the result in A. Here A and Brefers to some locations where the numbers are actually stored. This a kind ofindirect addressing mode.

There are several types of addressing modes present. Eachaddressing mode has a unique formula to locate the operand.Some of them are mentioned below :

I. Immediate Addressing Mode (Refer to glossary for detail).

II. Direct Addressing Mode (Refer to glossary for detail).

III. Indirect Addressing Mode (Refer to glossary for detail)

Course Contents | Prev : Next

Introduction to Computer Systems

Computer Organization and

Architecture

Page 66: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 66/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.11_summary.html 1/2

Course Contents | Prev : Next

Summary

In given document, we have presented a brief overview ofComputer organization and architecture.

  Computer Architecture  - refer to the relationship between

different hardware component of a computer system.

  Computer Organization - refer to how operational attributes are

linked together to realized the architecture specifications.

We have covered basic units of a computer:

  Central Processing Unit (CPU)  - Controls the operation of the

computer and performs its data processing functions.

  Arithmetic Logic Unit (ALU)  - It performs

computer’s data processing functions.

  Control Unit(CU)  - It performs computer’s

data processing functions.

  Registers  - Registers provides internal

storage to the CPU.

  Input Unit/Devices - They provide input to the CPU.

  Output Unit/Devices  - They provide output from CPU to the

user.

  Memory Unit  - Memory Unit is needed to store the data and

program.

  Bus - It consists of set of wires that allow data to be passed back

and forth.

Introduction to Computer Systems

Computer Organization and

Architecture

Page 67: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 67/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.11_summary.html 2/2

  Addressing Mode  - Addressing modes are the ways how the

address of an object/operand is being accessed.

Course Contents | Prev : Next

Page 68: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 68/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.10_glossary_1.html 1/2

Course Contents | Prev : Next

Glossary

  Byte - A byte is a unit of measurement used to measure data. 1

 byte contains 8 binary bits, or a series of eight zeros and ones.

So, each byte can be used to represent 2^8 or 256 different

values.

  Processor Registers - A processor register is a local storage spaceon a processor that holds data that is being processed by CPU.

They generally occupy the top-most position in the memory

hierarchy and provide high-speed storage space and fast access

to data. A register may include the address of memory location

instead of the real data itself.

  Immediate Addressing Mode - In immediate addressing, the

instruction contains the value to be used. In many cases, aninstruction requires a constant quantity and a bit pattern which

will never change no matter when or how often the instruction is

executed. This mode of bit pattern is called the immediate

addressing mode. In the given Figure 2.15, the op-word for

instruction includes a group of bits which identifies this mode of

addressing. Since the instruction is located in program memory

the constant is itself in program memory.

In Immediate addressing mode, the instruction does notexplicitly state the location of operand, rather, it explicitly states

the operand itself. This addressing mode is  used when a

particular constant value is to be fixed within a program itself.

The value is found in memory “immediately” after the

instruction code word that may never change at any time.

Introduction to Computer Systems

Computer Organization and

Architecture

Page 69: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 69/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.10_glossary_1.html 2/2

Figure 2.15 : Immediate Addressing Mode

Course Contents | Prev : Next

Page 70: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 70/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.10_glossary_2.html 1/3

Course Contents | Prev : Next

Glossary

  Direct Addressing Mode  - In direct addressing, the instruction

tells where the value can be found, but the value itself is out in

the memory. Here the instruction explicitly states the location of

an operand or destination that is either in memory or in a

processor register.

There are two sub-classification of direct addressing mode-

  Absolute Addressing - The mode is referred

to as Absolute addressing, when the location

is in memory.

  Register Direct Addressing  - The mode is

referred to as Register Direct Addressing,

when the location is a processor register.

In Figure 2.16 , the instruction specifies the address of the

operand.

In Figure 2.17, the instruction specifies the register containing

the operand.

Figure 2.16 : Absolute Addressing

Introduction to Computer Systems

Computer Organization and

Architecture

Page 71: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 71/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.10_glossary_2.html 2/3

Figure 2.17 : Register Direct Addressing

  Indirect Addressing Mode  - Indirect addressing uses addressregister to point at the location of the operand in memory, that

is, the address of an operand is obtained indirectly via an

address register. In the Indirect Addressing Mode the

instruction tells the processor neither the address of the

operand nor the operand itself. The instruction may either state

explicitly the address of a location in a memory or the name of a

processor register.

In the given Figure 2.18, the op-word for the instruction includesa group of bits which identifies this mode of addressing and the

indirect address is specified in one or more additional post-

words. Indirect Addressing is used when a program operates

upon different data values under different circumstances.

Page 72: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 72/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.10_glossary_2.html 3/3

Figure 2.18 : Indirect Addressing Mode

Course Contents | Prev : Next

Page 73: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 73/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.10_glossary_3.html 1/2

Course Contents | Prev : Next

  SCSI device  - A SCSI device is connected to the SCSI (Small

Computer System Interface). The SCSI device functions on its

own and uses the SCSI interface to communicate with the rest of

the computer. Figure 2.19 and Figure 2.20 are example of SCSI

devices.

Figure 2.19 : SCSI Device

Figure 2.20 : SCSI Device

  Mainframes - A Mainframe computer is very large and powerful

computer, dedicated to lengthy and complex calculations.

Mainframe is also referred as the hub of a system, capable of

supporting hundreds or even thousands of users

simultaneously. A mainframe is an ultra high-performance

computer made for processor-intensive and high-volume

computing. They are used for scientific purposes and large businesses.

Supercomputers  - A supercomputer is a high performance

Glossary

Introduction to Computer Systems

Computer Organization and

Architecture

Page 74: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 74/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module2/session2.10_glossary_3.html 2/2

computing machine. It is the fastest type of computer having

extremely fast processing speeds. Supercomputers are very

costly and are used for specialized applications, where immense

amounts of mathematical calculations are required. For

example, animated graphics, nuclear energy research, weather

forecasting and petroleum exploration works on supercomputer.

The major difference between a supercomputer and amainframe is that a supercomputer uses its power in executing

few programs as fast as possible, whereas a mainframe uses its

power to execute many programs concurrently.

Course Contents | Prev : Next

Page 75: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 75/166

12/9/13 Introduction to Computer Systems

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module3/session3.1_introduction.html 1/2

Course Contents | Prev : Next

3. Introduction

System software refers to the files and programs that makes up the computer'soperating system. System files consist of libraries of functions, system services, drivers forprinters, other hardware, system preferences and various configuration files.

System Software consist of the following programs:

  Assemblers

  Compilers

  File Management Tools

  System Utilities

  Debuggers

The system software is installed on the computer when the operating system isinstalled. The software can be updated by running programs such as "Windows Update" forWindows or "Software Update" for Mac OS X. Application programs are used by end user,whereas system software is not meant to be run by the end user. For example, while Web browser

like Internet Explorer are used by users every day, they don't have to use an assembler program(unless the user is a computer programmer).

System software runs at the most basic level of the computer and hence it is called"low-level" software.User interface is generated by the system software and allows the operatingsystem to interact with the hardware.

System software is the interface between the computer hardware and the applicationsoftware.

Introduction to Computer Systems

Systems Software

Page 76: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 76/166

12/9/13 Introduction to Computer Systems

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module3/session3.1_introduction.html 2/2

Figure 3.1 : System Software

Course Contents | Prev : Next

Page 77: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 77/166

12/9/13 Introduction to Computer Systems

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module3/session3.2_assembler.html 1/2

Course Contents | Prev : Next

3.1 Assembler

An assembler is a program that converts basic computerinstructions into a pattern of bits. These bits are used by computer's processorto perform its basic operations. Some people call these instructions asassembler language and others use the term assembly language. This is how itworks:

Most computers come with a specified set of very basic

instructions that corresponds to the basic machine operations that thecomputer can perform. For example, a "Load" instruction moves a string of bitsfrom a location in the processor's memory to a special holding place called aregister. In computer architecture, a processor register is a small amount ofstorage available on the CPU and the contents of register can be accessed morequickly. Most of the modern computer architectures operate on the principle ofshifting data from main memory into registers, operate on the data and thenmove the result back into main memory. Assuming the processor has at leasteight numbered registers, the following instruction would move the value

(string of bits of a certain length) at memory location 2000 into the holdingplace called register 8:

L 8,2000

  The programmer can write a program using a sequence of

assembler instructions.

  These assembler instructions, which is also known as the sourcecode or source program, is then specified to the assembler

program when it is started.

  Each program statement in the source program is taken by the

assembler program and a corresponding bit stream or pattern (a

series of 0's and 1's of a given length) is generated.

  The output of the assembler program is called the object code or

object program relative to the input source program. The object

program consisting of a sequence of 0's and 1's is also known as

machine code.

Introduction to Computer Systems

Systems Software

Page 78: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 78/166

12/9/13 Introduction to Computer Systems

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module3/session3.2_assembler.html 2/2

  This object program can be run (or executed) whenever required.

Figure 3.2 : Assembler

Course Contents | Prev : Next

Page 79: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 79/166

12/9/13 Introduction to Computer Systems

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module3/session3.3_assembly-language_1.html 1/2

Course Contents | Prev : Next

3.2 Assembly Language

The native language of the computer is assembly language . Theprocessor of the computer understands machine code (consisting of ones andzeroes). In order to write the machine code program, it has to be first written inassembly language and then an assembler is used to convert the assemblylanguage program to machine code.

Assembly language program consists of mnemonic codes which

are easy to remember as they are similar to words in the english language. Itconsists of mnemonic codes for each of the different machine code instructionsthat the machine understands. A mnemonic is an abbreviation of the actualinstruction. It is a programming code that is easy to remember because thecodes resemble the original words, for example, ADD for addition and SUB forsubtraction. Examples of assembly language program:

MOV EAX,2 ; set eax register to 2(eax = 2)

SHL EAX,4 : shift left value in the register

MOV ECX,16 ; set ecx register to 16

SUB EAX,EBX ; substracts ecx from eax

An assembler converts this set of instructions into a series ofones and zeros, also known as a executable program, that the machine canunderstand.

  Assembly language can be optimized extremely well as it is

extremely low level language. Therefore assembly language is

used in application which require utmost performance.

  Assembly language can be used for communication with the

machine at the hardware level and hence it is often used for

writing device drivers.

  Another advantage of assembly language is the size of the

Advantages of Assembly language

Introduction to Computer Systems

Systems Software

Page 80: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 80/166

12/9/13 Introduction to Computer Systems

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module3/session3.3_assembly-language_1.html 2/2

resulting programs. Since conversion from a higher level by a

compiler is not required, the resulting programs can be

exceedingly small.

Course Contents | Prev : Next

Page 81: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 81/166

12/9/13 Introduction to Computer Systems

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module3/session3.3_assembly-language_2.html 1/2

Course Contents | Prev : Next

3.2 Assembly Language

3.2.1 Assembly Language Programming

The assembler is a program which converts the assemblylanguage source program into a format that can be run on the processor. Themachine code instruction containing binary or hex value is replaced by amnemonic.

Example

Binary Hex Mnemonic Description

1001111 4F CLRA Clears the A accumulator

110110 36 PSHA Saves A accumulator on stack

1001101 4D TSTA Tests A accumulator for 0

Figure 3.3 : Assembly Language Programming

Advantages of using mnemonics are:

  Mnemonics are easy to understand than hex or binary values.

  Its less likely to make an error.

  Mnemonics are easy to remember.

Assembly language statements are written one on each line. Amachine code program consists of a sequence of assembly languagestatements in which each statement contains a mnemonic. A line of anassembly language program can contain the following four fields:

i. Label

ii. Opcode

iii. Operand

Introduction to Computer Systems

Systems Software

Page 82: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 82/166

12/9/13 Introduction to Computer Systems

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module3/session3.3_assembly-language_2.html 2/2

iv. Comments

The label field is optional. A label is an identifier or a text. Labelsare used in programs to reduce reliance upon programmers rememberingwhere data or code is located.A label is used to refer to the following:

  Memory location

  A data value

  The address of a program or a sub-routine or a portion of code.

Course Contents | Prev : Next

Page 83: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 83/166

12/9/13 Introduction to Computer Systems

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module3/session3.3_assembly-language_3.html 1/2

Course Contents | Prev : Next

3.2 Assembly Language

3.2.1 Assembly Language Programming

The maximum length of a label differs for different type ofassemblers. Some assemblers accept up to 32 characters long, others only fourcharacters. When a label is declared, it is suffixed by a colon, and begins with avalid character (A..Z). Consider the following example.

LOOP: LDAA #24H

Here, the label LOOP is equal to the address of the instructionLDAA #24H. The label can be used as a reference in a program, as shown

 below

 JMP LOOP

When the above instruction is executed, the processor will execute

the instruction associated with the label LOOP, i.e.LDAA #24H. When a label isreferenced later in a program, it is referenced without the colon suffix.

An advantage of using labels is that inserting or re-arrangingcode statements do not require re-working actual machine instructions. It onlyrequires a simple re-assembly. In hand-coding, changes can take hours toperform.

The opcode field consists of a mnemonic. Opcode is the operation

code, ie, a machine code instruction. Opcode may also have additionalinformation in the form of operands Operands are separated from the opcode

 by using a space.

Operands consists of additional information or data that theopcode requires. Operands are used to specify

  Constants or labels

  Immediate data

  Data present in another accumulator or register

Introduction to Computer Systems

Systems Software

Page 84: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 84/166

12/9/13 Introduction to Computer Systems

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module3/session3.3_assembly-language_3.html 2/2

  An address

Examples of operands

LDAA 0100H ; two byte operand

LDAA LOOP ; label operand

LDAA #1 ; immediate operand(i.e constant value as operand)

The comment field is optional, and is used by the programmer toexplain how the coded program works. The comments are prefixed by a semi-colon. Comments are ignored by the assembler when the instructions aregenerated from the source file.

Course Contents | Prev : Next

Page 85: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 85/166

12/9/13 Introduction to Computer Systems

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module3/session3.4_loaders-and-linkers.html 1/2

Course Contents | Prev : Next

3.3 Loaders and Linkers

In a computer operating system , a loader is a component thatlocates a program (which can be an application or a part of the operatingsystem itself) in an offline storage (for eg. hard disk ), loads it into mainstorage (also called random access memory ), and gives that program controlof the computer (i.e. allows it to execute its instructions).

A program that is loaded may itself contain components that are

not initially loaded into main storage, but are loaded if and when their logic isrequired. In a multitasking operating system, a program that is known as adispatcher juggles the computer processor's time among different tasks andcalls the loader when a program associated with a task is not already in themain storage. (Program here, means a binary file that is the result of aprogramming language compilation or linkage editing or some other programpreparation process.)

A linker, also known as link editor is a computer program that

takes one or more object files generated by a compiler and combines them intoa single executable program.

Computer programs comprise several parts or modules ,but allthese parts/modules need not be contained within a single object file. In suchcase they refer to each other by means of symbols. An object file can have threekinds of symbols:

  Defined symbols, which is called by other modules

  Undefined symbols, which call the other modules  where the

symbols are defined.

  Local symbols which are used internally within the object file to

facilitate relocation.

For most compilers, each object file is the result of compiling oneinput source code file. If a program comprises multiple object files, then thelinker combines these files into a unified executable program by resolving thesymbols as it goes along.

Introduction to Computer Systems

Systems Software

Page 86: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 86/166

12/9/13 Introduction to Computer Systems

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module3/session3.4_loaders-and-linkers.html 2/2

Linkers can take objects from a collection called a runtimelibrary. A runtime library is a collection of objects files which will containmachine code for any external function used by the program file used by thelinker. This machine code is copied by the linker into the final executableoutput. Some linkers do not include the entire library in the output, they onlyinclude the symbols that are referenced from other object files or libraries. Thelibraries exist for diverse purposes. The system libraries are usually linked in

 by default.

The linker also arranges the objects in a program's address space.This involves relocating code that assumes a specific base address to another

 base address. Since a compiler seldom knows where an object will reside, itassumes a fixed base location (for example, zero). The relocation of machinecode may involve re-targeting of loads,stores and absolute jumps.

The executable output by the linker may need another relocationpass when it is finally loaded into memory (just before the execution). Thisrelocation pass is usually omitted on hardware offering virtual memory inwhich every program is put into its own address space, and so there is noconflict even if all programs load at the same base address. This relocationpass may also be omitted if the executable is a position independentexecutable.

Figure 3.4 : Linker

Course Contents | Prev : Next

Page 87: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 87/166

12/9/13 Introduction to Computer Systems

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module3/session3.5_compilers.html 1/2

Course Contents | Prev : Next

3.4 Compilers

A compiler is a special program that processes statementswritten in a particular programming language and turns them into machinelanguage or code that a computer's processor uses. A programmer writeslanguage statements in a language such as Pascal or C one line at a time usingan editor . The file created contains the source statements or source code . Theprogrammer then runs the appropriate compiler for the language, specifyingthe name of the file that contains the source statements.

When executing (running), the compiler first parses (or analyzes)the language statements syntactically one after the other and then builds theoutput code in one or more successive stages or "passes" and makes sure thatstatements that refer to other statements are referred in the final codecorrectly. The output of the compilation is called object code or sometimes anobject module . The object code is machine code that the processor can execute,one instruction at a time.

The Basic Structure of a Compiler

In the five stages of a compiler, the high level language istranslated to a low level language which is generally closer to that of the targetcomputer. Each stage of the compiler fulfills a single task and has one or moreclassic techniques for implementation. The following are the five stages of acompiler:

  Lexical Analyzer : Analyzes the Source Code,removes "whitespace" and comments,formats it for easy access by creating

tokens, then tags language elements with type information and

 begins to fill the information in the SYMBOL TABLE. The

Symbol Table is a data structure that contains information

about symbols and groups of symbols in the program being

translated.

  Syntactic Analyzer : Analyzes the tokenized code forstructure,groups symbols into syntactic groups,tags groups

with type information.

Introduction to Computer Systems

Systems Software

Page 88: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 88/166

12/9/13 Introduction to Computer Systems

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module3/session3.5_compilers.html 2/2

  Semantic Analyzer : Analyzes the Parsed Code for meaning, fills

in assumed or any missing information and tags the groups

with the meaning.

  Code Generator : Linearizes the qualified Code and produces the

object code.

  Optimizer: Checks the object code to determine whether there are

more efficient means of execution.

Figure 3.5 : Stages of a compiler

Course Contents | Prev : Next

Page 89: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 89/166

12/9/13 Introduction to Computer Systems

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module3/session3.6_interpreters.html 1/2

Course Contents | Prev : Next

3.5 Interpreters

Interpreter is a program that executes instructions written in ahigh-level language. There are two methods to run programs written in a high-level language. The most common method is to compile the program and theother method is to pass the program through an interpreter.

An interpreter translates high-level instructions into anintermediate form and then executes it. In contrast to the above method, a

compiler translates high-level instructions directly into machine language. Thecompiled programs generally run faster than interpreted programs. One of theadvantage of using an interpreter is that it does not need to go through thecompilation stage during which machine instructions are generated. Thisprocess of compilation can be time-consuming if the program is very long. Theinterpreter, on the other hand, immediately execute high-level programs. Henceinterpreters are sometimes used during the development of a program inwhich the programmer wants to add small sections at a time and test themquickly. In addition to this, interpreters are often used in education because

they allow students to program interactively.

Advantages of using interpreter

  Execution is done in a single stage. Compilation stage is not

required.

  Alteration of code is possible during runtime.

  Really useful for debugging the codes.

  Helps in interactive code development.

Interpreter vs Compiler

  The primary difference between a compiler and interpreter is the

way in which a program is executed. The compiler converts the

source code to machine code and then saves it as an object code

 before creating an executable file for the same. The compiled

program is executed directly using the machine code or the

Introduction to Computer Systems

Systems Software

Page 90: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 90/166

12/9/13 Introduction to Computer Systems

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module3/session3.6_interpreters.html 2/2

object code. But an interpreter does not convert the source code

to an object code before execution.

  An interpreter executes the source code line by line and

conversion to native code is performed line by line while

execution is going on (at runtime). Hence the run time required

for an interpreted program will be high compared to a compiledprogram.

  Even though the run time required for interpreted program is

more, the execution using an interpreter has its own advantages.

For example interpreted programs can modify themselves at

runtime by adding or changing functions. Compiled program

has to be recompiled fully even for the small modifications done

in the program. But in the case of an interpreter there is no suchproblem (only the modified section needs to be recompiled).

(Refer Fig 3.6)

Figure 3.6 : Compiler vs Interpreter

Course Contents | Prev : Next

Page 91: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 91/166

Page 92: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 92/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.1_introduction_1.html 1/1

Course Contents | Prev : Next

4. Introduction

Operating system is a collection of programs. It is a software thatsupports a computer's basic functions. It acts as an interface betweenapplications and computer hardware as shown below in the figure 4.1.Examples of operating systems are Windows, Linux, MacOS, etc.

Figure 4.1 : OS Position

Operating system also does the task of managing computerhardware. Operating system manage hardware by creating a uniform set offunctions or operations that can be performed on various classes of devices(for instance read x bytes at address y from hard drive of any type, where x isthe number of bytes read). These general functions rely on a layer of driversthat provide specific means to carry out operations on specific hardware.Drivers usually are provided by the manufacturers, but the OS must alsoprovide a way to load and use drivers. OS must detect the device and select anappropriate driver if several are available.

Course Contents | Prev : Next

Introduction to Computer Systems

Introduction to Operating System

Page 93: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 93/166

Page 94: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 94/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.1_introduction_2.html 2/2

Course Contents | Prev : Next

Page 95: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 95/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_1.html 1/1

Course Contents | Prev : Next

Following are the basic resources that are managed by operatingsystem:

  Memory space (Memory management)

  CPU time (Process management)

  Disk space (File system management)

  Input-output device (Device management)

4.1 Basic Resources Managed By Operating System

4.1.a Basics Of Memory Management

Any program needs to be loaded in memory (RAM) before it canactually execute. Random Access Memory (RAM) is a type of computermemory that can be accessed randomly, i.e. any byte of memory can beaccessed without touching or traversing through the preceding bytes. RAMthese days is available with various storage capabilities (256MB, 512MB, 1GB,2GB, 4GB, 6GB and 8GB sizes).

Memory management deals with managing computer's primarymemory. It decides the amount of memory to be allocated to a particular

program. It also keeps track of free or unallocated as well as allocated memory.Memory management applies only to RAM.

The sole motto of memory management to be done by operatingsystem is how best to utilize the available memory. In this process we shouldtry to minimize fragmentation.

Course Contents | Prev : Next

Introduction to Computer Systems

Introduction to Operating System

Page 96: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 96/166

Page 97: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 97/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_3.html 1/2

Course Contents | Prev : Next

i. Fragmentation

Internal Fragmentation

Internal fragmentation is the space wasted inside theallocated memory block because of the restriction on allowed sizes ofallocated blocks. Allocated memory can be slightly larger than

requested memory. The size difference is the memory internal topartition but would not be used. Internal fragmentation is difficult toreclaim. Design change is the best way to remove internalfragmentation. For example, in dynamic memory allocation, memorypools cut internal fragmentation by spreading the space overhead over alarger number of objects.

External Fragmentation

External fragmentation happens when a dynamic memoryallocation algorithm allocates some memory and a small piece is leftover which cannot be used effectively. The amount of usable memoryreduces drastically, if too much external fragmentation occurs. The totalmemory space available is enough to satisfy a request but is notcontiguous and so, is wasted. Here the jargon 'external' is used to depictthat the storage that is further unusable is outside the allocated regions.

For example, consider a situation wherein a programallocates three continuous blocks of memory and then frees the middleone. The memory allocator can use this free block of memory for futureallocations. However, this free block cannot be used for allocation if thememory to be allocated is larger in size than the free block. Externalfragmentation also occurs in file systems as many files of different sizesare created, size changed and deleted. The effect is even worse if a filewhich is divided into many small pieces is deleted, because this leavesalmost equal small regions of free space.

Data Fragmentation

Introduction to Computer Systems

Introduction to Operating System

Page 98: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 98/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_3.html 2/2

Data fragmentation occurs when a collection of data inmemory is broken up into many pieces that are not close enough. It istypically the result of attempting to insert a large object into storagethat has already suffered external fragmentation.

Course Contents | Prev : Next

Page 99: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 99/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_4.html 1/1

Course Contents | Prev : Next

ii. Memory Management Techniques

  Single Contiguous Allocation

  Partitioned Memory Management Scheme (Refer Glossary for

scheme definition)

  Paged Memory Management

  Segmented Memory Management

Figure 4.3 : Single Contiguous Allocation

4.1.a Basics Of Memory Management

Single Contiguous Allocation

Single

Contiguous Allocation isthe simplest form ofmemory management. Inthis type of memorymanagement, all memory(with an exception ofsmall portion reserved forrunning the operatingsystem) is available for a

single program to run. Soonly one program isloaded in all available memory and so generally the rest of memory is wasted.Simplest example of this type of memory management is MS-DOS. Advantageof single contiguous memory allocation is, it supports fast sequential anddirect access. Provides good performance and the number of disk seek requiredis minimal. Disadvantage of single contiguous memory allocation isfragmentation.

Course Contents | Prev : Next

Introduction to Computer Systems

Introduction to Operating System

Page 100: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 100/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_5.html 1/2

Course Contents | Prev : Next

ii. Memory Management Techniques

Partitioned Memory Management Scheme

This type of memory management divides primary memory intomultiple memory partitions, usually contiguous areas of memory. Memorymanagement here consists of allocating a partition to a job or program when itstarts and unallocating it, when job or program ends. A typical scenario of

partitioned memory management is depicted in the figure 4.4 below. This typeof memory management also needs some hardware support.

The figure 4.4 below shows multiple memory partitions. Eachpartition runs a process (Refer Glossary). Process 1, Process 2, etc. are theprocesses allocated to a particular partition in memory. Once the process iscompleted, partition gets empty. A is the base register address. Base registercontains the lowest memory address a process may refer to. We can get lengthof a partition from Bounds register. Bounds register stores upper and lower

 bounds on addresses in a time sharing environment. Time sharingenvironment refers to concurrent use of computer by more than one user –users share the computer’s time. Time sharing is the term used synonymouslywith multi-user.

Introduction to Computer Systems

Introduction to Operating System

Page 101: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 101/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_5.html 2/2

Figure 4.4 : Partitioned Memory Management

Course Contents | Prev : Next

Page 102: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 102/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_6.html 1/1

Course Contents | Prev : Next

Partitioned memory management is further divided in to 2 types ofpartitioning schemes:

  Fixed memory partitioning (Static partitioning)

Main memory is divided into a number of static partitionswhen a computer system starts. A process may be loaded into apartition of equal or greater size. Advantage of such type of partitioningis that it is simple to implement and has a little operating systemoverhead. Disadvantages are inefficient use of memory due to internalfragmentation. Also maximum number of active processes is fixed.

  Variable memory partitioning (Dynamic partitioning)

Such partitions are created dynamically so that eachprocess is loaded into a partition of exactly the same size as thatprocess. Advantage of such type of partitioning is that there is nointernal fragmentation. Also main memory is used more efficiently.Disadvantage is inefficient use of processor due to the need forcompaction to counter external fragmentation.

For further details on types of partitioning please refer below link:

http://www.csbdu.in/econtent/Operating System/unit3.pdf

Course Contents | Prev : Next

ii. Memory Management Techniques

Introduction to Computer Systems

Introduction to Operating System

Page 103: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 103/166

Page 104: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 104/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_7.html 2/2

Figure 4.5 : Paged Memory Management

Course Contents | Prev : Next

Page 105: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 105/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_8.html 1/2

Course Contents | Prev : Next

ii. Memory Management Techniques

Segmented Memory Management

Segmented memory means, the division of computer's primarymemory into segments or sections as shown in figure 4.6. In this type ofmemory management, there is reference to a memory location that includes avalue . This value identifies a segment and an offset within that segment. We

may create different segments for different program modules, or for differenttypes of memory usage such as code and data segments. Certain memorysegments may even be shared between programs. Segmented memory does notprovide user's program with a linear and contiguous (or continuous) addressspace. Linear address space is a memory addressing scheme used inprocessors where the whole memory can be accessed using a single addressthat fits in a single address or instruction.

Segments are areas of memory that usually correspond to a

logical grouping of information such as code procedure or a data array (ReferGlossary). Segmentation allows better access protection than other memorymanagement schemes because memory references are relative to a specificsegment and hardware will not permit the application to reference memory notdefined for that segment. It is possible to implement segmentation with orwithout paging.

Segmentation With Paging has the following advantages:

1. Paging eliminates external fragmentation. As a result it provides

efficient use of main memory.

2. Segmentation which is visible to the programmer, includes strength of

paging. It has the ability to handle growing data structures,

support for sharing, and modularity, and protection.

To combine fragmentation and paging, a user's address space is broken into a number of segments. Each of these segments in turn is brokeninto fixed-size pages. If size of a segment is less than a page in length, then the

Introduction to Computer Systems

Introduction to Operating System

Page 106: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 106/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_8.html 2/2

segment occupies just one page.

Figure 4.6 : Segmented Memory Management

Course Contents | Prev : Next

Page 107: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 107/166

Page 108: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 108/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_9.html 2/2

Some of them are foreground processes while others are the backgroundprocesses. Foreground processes interact with a user and perform work forusers. In multiprocessing environment, the process that accepts input from thekeyboard or other input device at a particular point in time is at times calledthe foreground process. This means that any process that actively interactswith user is a foreground process. Background processes are the processeswhich are not associated with a particular user, but instead have some specificfunction to be performed. For example email notification is an example of

 background processes. System clock displayed at the bottom right corner ofstatus bar in windows is another example of background process.

Course Contents | Prev : Next

Page 109: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 109/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_10.html 1/2

Course Contents | Prev : Next

Some of the common reasons for process termination are:

  User logs off

  A service request to terminate is executed by process

  Error and fault conditions

  Normal completion

  Time limit exceeded

  Memory unavailable

  I/O failure

  Fatal error, etc.

Figure 4.7 on next page contains great deal of information.

  Let us consider a running process 'P' that issues an input-output

request  The process blocks.

  Thereafter, at certain point of time later, a

disk interrupt occurs and the driver detects

that P's request is satisfied.

  P is unblocked, i.e. the state of process P is

changed from blocked to ready.

  Later, at some point of time, the operating

system looks for a ready job to run and picks

4.1.b Process Management

Introduction to Computer Systems

Introduction to Operating System

Page 110: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 110/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_10.html 2/2

the process/job P from the queue.

  A preemptive scheduler in figure 4.7 below has the dotted line

'Preempt'; where as a non- preemptive scheduler doesn't.

  The number of processes change for two arcs namely, create

and terminate.

  Suspend and resume are a part of medium term scheduling

  It is done on a bit longer time scale.

  It involves memory management as well.

  It is also known as two level scheduling.

Course Contents | Prev : Next

Page 111: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 111/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_11.html 1/3

Course Contents | Prev : Next

There are 2 types of scheduling:

1. Preemptive scheduling:

In a computer, tasks are assigned priorities. At times it isnecessary to run a certain task that has high priority before another task(even if the task is in running state). Therefore, the running task isinterrupted for some time, put to either blocked or suspended state andresumed later, when the priority task has finished its execution. Thisprocess is called preemptive scheduling.

2. Non preemptive scheduling:

In non-preemptive scheduling, a running task executes till itcompletes fully. It cannot be interrupted. That means when a processenters the running state, it cannot be deleted from the scheduler until itfinishes its service time.

4.1.b Process Management

Introduction to Computer Systems

Introduction to Operating System

Page 112: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 112/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_11.html 2/3

Figure 4.7 : Process Management

The figure 4.7 above shows various states of a process. Initiallythe process is created. Once created, it goes to the ready state. Ready state

means the process is ready to execute. It has been loaded into the mainmemory and is waiting for execution on a CPU. There can be many readyprocesses waiting for execution at a given point of time. A queue of processeswhich are ready to execute gets created in memory. One of the processes fromthat queue is picked up for execution and its state gets changed to running. Arunning process can be blocked. Blocked state means a process is blocked onsome event.

A process may be blocked due to various reasons such as when a

particular process has exhausted, the CPU time allocated to it, it is waiting foran event to occur. Blocked process can either move to ready state or can moveto suspended state. In systems that support virtual memory, a process may beswapped out, that is, it would be removed from main memory and would beplaced in virtual memory by the mid-term scheduler. This is called suspendedstate of a process. From here the process may be swapped back in to the readystate. Such state is called ready suspended state. Process that are blocked mayalso be swapped out. Such a state of process where a process is both swappedout and blocked is called blocked suspended state. Suspended processes can

 be sent back to ready state only once they are released. This cycle continues tilla process finishes its execution i.e. terminated. A process may be terminatedfrom the running state by completing its execution or can be killed explicitly. Ineither of these cases, we say that the process is terminated.

Page 113: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 113/166

Page 114: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 114/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_12.html 1/2

Course Contents | Prev : Next

4.1 Basic Resources Managed By Operating System

4.1.c File System Management

Computer contains numerous files. They need to be organized ina proper way so that we can keep track of those files. File retrieval should beeasier as well as faster. File system management helps us achieve this.

File system manager is used by the operating system to do filesystem management. File system manager organizes and keeps track of all thefiles and directories on secondary storage media.

Figure 4.8 : File System Management

Figure 4.8 above shows a typical hierarchical file systemstructure. Operating system keeps track of following tasks for providingefficient file management:

  It is able to identify numerous files by giving unique names to

them.

  It maintains a list to keep track of exact file location.

Introduction to Computer Systems

Introduction to Operating System

Page 115: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 115/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_12.html 2/2

  Provide fast and simple algorithms to write and read files in co-

operation with device manager.

  Grant and deny access rights on files to programs and users.

  Allocate and de-allocate files so that files can be processed in co-

operation with process manager.

  Provide programs and users with simple commands for

handling files.

Course Contents | Prev : Next

Page 116: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 116/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_13.html 1/3

Course Contents | Prev : Next

On storage medium, file gets saved in blocks or sectors. To accessthese files, file manager and device manager works together. The devicemanager knows where to find each sector on disk, but only file manager has alist telling in what sectors either file is stored. This list is called File AllocationTable (FAT). FAT has been in use under DOS for a long time. Some of its

alterations are still used by Win95 and Win98.

Below are the different ways of allocating files:

  Contiguous file allocation:

In this type of file allocation, at the time of file creation, a

single set of blocks is allocated to a file. Each file is stored contiguouslyin sectors, one sector after another. The advantage is that the FileAllocation Table has a single entry for each file, indicating the startsector, the length, and the name. Moreover, it is also easy to get a single

 block because its address can be easily calculated. The disadvantagemay be that it can be difficult to get a sufficiently large block ofcontiguous blocks. Contiguous file allocation is now a days only used fortapes and recordable CDs.

  Non-contiguous file allocation:

With this type of allocation, all blocks of a file can bedistributed all over the storage medium. The File Allocation Table (FAT)lists not only all files, but also has an entry for each sector the fileoccupies. As all information is stored in the FAT, and there is noassumption on the distribution of the file, this method of allocation, attimes, is also known as FAT.

The advantage is that it is very easy to get a single block, because each block has its entry in the FAT. Also, it is a very simpleallocation method where no overhead is produced and no search method

4.1.c File System Management

Introduction to Computer Systems

Introduction to Operating System

Page 117: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 117/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_13.html 2/3

for free blocks is needed. The disadvantage is that FAT can grow to anenormous size, which can slow down the system. Compaction would beneeded time to time. This type of file allocation is used for diskallocation in MS-DOS.

  Chained allocation:

With chained file allocation only the first block of file getsan entry in the FAT. A block has sectors in it. Of these, the first sectorhas got data as well as a pointer at its end that points to the next sectorto be accessed after it (or indicates that it was the last). That means eachsector (if it is not a last sector) has got a pointer at its end pointing to thenext sector that should be accessed. The advantage again is that the FAThas a single entry for each file, indicating position of the first sector and

file name. There is no need to store the files contiguously.

The disadvantage of chained allocation is that it takesmuch time to retrieve a single block because that information is neitherstored anywhere nor can it be calculated. If we want to access aparticular sector, all preceding sectors have to be read in order one afteranother. This way, the information about location of the next block isidentified. Unix i-node is an example of this type of allocation. i-nodesare data structures (Refer Glossary) of a file system used to store all the

important properties of each file: owner's group id and user id, accesspermission on that file, size of the file and more. Unix i-node is anoperating system which has i-nodes as its data structure.

  Indexed allocation:

With indexed file allocation also only the first block of filegets an entry in the FAT. In the first sector, no data is stored. It has only

pointers to where the file is on storage medium. That is why the first block is known as the index block. It just contains the pointers or indexto file location on a storage medium. Here also the FAT will only containa single entry for each file, indicating file name and position of the firstsector. It is easy to retrieve a single block because the information aboutits location is stored in the first block.

The disadvantage of indexed allocation is that for each filean additional sector is needed to keep track of the location of a file. A

very small file also always occupies at least two blocks, where as thedata could have easily fit in one block. This results in secondary storagespace wastage. Indexed allocation is implemented in all UNIX systems.It is reliable as well as fast. Also, now-a-days, the wastage of storage

Page 118: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 118/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_13.html 3/3

space does not matter much.

The main concern of file system management is to provide astrategy that lets the FAT not to grow too large and that makes it possible toretrieve a special sector of file such that the storage space is not wasted much.

Course Contents | Prev : Next

Page 119: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 119/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_14.html 1/2

Course Contents | Prev : Next

4.1 Basic Resources Managed By Operating System

4.1.d Device Management

Operating system also deals with device management, speciallyinput and output devices. In a multi-user system, there are shared devices likeprinter, scanner, etc. Management of these devices by sending themappropriate commands is the major task of operating system.

A software routine which knows how to deal with each device iscalled a “driver” and operating system requires drivers for the peripheralsattached to computer. When a new peripheral is added, device driver isinstalled in to the operating system.

Operating system also deals with the access time of these devices.It helps make the device access fast and in the most efficient way possible.

Major concern of operating system in device management is toprevent dead lock situation.

Dead Lock

Figure 4.9 : Dead Lock

Introduction to Computer Systems

Introduction to Operating System

Page 120: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 120/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.2_resources-managed-by-OS_14.html 2/2

OS helps in dealing with dead lock situation up to a certainextent. Below are some of the strategies for dealing with deadlock:

  Ostrich algorithm, i.e. ignoring the problem altogether. Ostrichalgorithm is a strategy of ignoring potential problems on the

 basis that they may be exceedingly rare. Ostrich algorithm

assumes that ignoring the problem would be more cost-effective

as compared to allowing the problem to occur and then attempt

for its prevention. It may occur very infrequently. This can be

followed if cost of detection/prevention is not worth the time and

cost spent.

  Detection and Recovery.

  Avoiding deadlock by careful resource allocation.

  Prevention of deadlock by structurally negating one of the four

necessary conditions.

Above diagram depicts a typical dead lock situation, that seriallyused devices can have. Dead lock is a situation where each set of processes iswaiting for an event that only other process in the set can cause.

For example, in the above diagram, Process Task 1 requests amutex or lock on object which is already held by Process Task 2. In turn,Process Task 2 needs a resource to complete its process which is already held

 by Process Task 1. So neither of the processes are releasing their resources ormutex and waiting for another process to release a mutex so that they can get itto complete its pending task. This situation would cause an indefinite wait forprocesses leading to a situation known as dead lock.

Mutex is the short form for Mutual Exclusion Object. A mutex is alogical unit. It is a program object that allows multiple program threads toshare the same resource, but not simultaneously. File access is an example ofmutex. A mutex with unique name is created when the program starts. Mutexmust be locked by a thread that needs the resource. When data is no longerneeded, the mutex is set to unlock.

Course Contents | Prev : Next

Page 121: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 121/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.3_resource-sharing-management_1.html 1/1

Course Contents | Prev : Next

4.2 Resource Sharing Management

The primary task of operating system as discussed above is tokeep track of resources like memory, CPU utilization, storage device , and inputoutput devices, to grant resource requests, to mediate conflicting requestsfrom different programs, etc.

4.2.1 Multiplexing

Multiplexing is a method by which multiple analog datasignals/digital data streams are combined into one signal over a sharedmedium. Multiplexing is used to share an expensive resource and thus helpreduce the cost.

Communication channel is used for transmission of amultiplexed signal. This channel may be a physical transmission medium.Multiplexing basically works on the principle of division of signals. It dividesthe capacity of the high level communication channel into several low levellogical channels. Each of these low level logical channel maps to each messagesignal or data stream to be transferred. A reverse of this process is known asdemultiplexing. Demultiplexing can extract the original channels or signals onthe receiver side.

A device that performs the task of multiplexing is called amultiplexer (MUX), and a device that performs the task of demultiplexing isknown as a demultiplexer (DEMUX).

Course Contents | Prev : Next

Introduction to Computer Systems

Introduction to Operating System

Page 122: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 122/166

Page 123: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 123/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module4/session4.4_glossary.html 1/1

Course Contents | Prev : Next

Glossary

Term

usedDescription

Scheme Scheme in document refers to techniques.

Process Job or a program that executes in memory.

Data

array

Array means an ordered list of items. When data is

arranged in an ordered way, it is called data array.

Data

structure

Data structure is a particular way of storing and

organizing data in a computer so that it can be usedefficiently.

Course Contents | Prev : Next

Introduction to Computer Systems

Introduction to Computer

Technology

Page 124: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 124/166

12/9/13 Introduction To Computer Systems TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.1_introduction.html 1/1

Course Contents | Prev : Next

5. Introduction

Computing Environment is a collection of computers, software,and networks that support the processing and exchange of electronicinformation. It can collaborate across various software installed on differentmachines at different physical and geographical locations as well, such anenvironment is called Distributed Computing Environment. Figure 5. 1 showshow different computers are connected with each other globally, also they can be connected with different devices like cell phones.

Critical applications (refer glossary) and bulk data processingrequire computer environments which can guarantee high reliability andstability. Most such large scale,high end commercial system architectures (referglossary) are referred as Mainframes.

Figure 5.1 : Computing Environments

Course Contents | Prev : Next

Introduction to Computer Systems

Computing Environments

Page 125: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 125/166

12/9/13 Introduction To Computer Systems TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.2_mainframe-computing-environment_1.html 1/2

Course Contents | Prev : Next

5.1 Mainframe Computing Environment

It usually refers to one or more very big computer(s) capable ofsupporting a large number of simultaneous users and doing bulk calculationsand data processing. It is usually used for extensive operations like EnterpriseResource Planning (refer glossary) or transaction processing. The Mainframeenvironment (Refer Figure 5. 2) is expensive and ensures very high level ofsecurity and reliability supporting massive throughput (refer glossary) . Forexample consider banking applications like calculating balance of multiple

customers who are doing their transaction simultaneously from differentlocations. Also generating account statements for all customers at the end ofevery month. These are all bulk operations requiring speed and accuracy.Mainframes have come a long way from the ENIAC (Electronic NumericalIntegrator And Calculator) developed in 1942 to today's IBM z series ofmainframes which are used in organizations like National Aeronautics andSpace Administration (NASA).

Software for mainframes are written in following languages:

  COmmon Business-Oriented Language (COBOL)

  Job Control Language (JCL)

Figure 5.2: Mainframe Computing Environment

Introduction to Computer Systems

Computing Environments

Page 126: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 126/166

Page 127: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 127/166

12/9/13 Introduction To Computer Systems TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.2_mainframe-computing-environment_2.html 1/2

Course Contents | Prev : Next

5.1 Mainframe Computing Environment

5.1.1 Storing Data on a Mainframe

On computers data is stored in the form of binary bits that is, 0sand 1s . Characters like A..Z are formed with 8 bits called as Bytes. When wepress a key on the keyboard eight bits get emitted from the cable. All the keysare represented with an unique combination of binary numbers that is 0s and1s. As we use 8 bits to store a single character, 2^8 = 256 different type of

patterns can be stored. On Mainframes, we use a unique 8-bit pattern to storeeach character. This representation of characters and data in mainframe isreferred as Extended Binary Coded Decimal Interchange Code (that isEBCDIC). Here, every character uses storage of one byte in memory.

For example, in EBCDIC,

The number 1 is represented as 1111 0001.

The number 2 is represented as 1111 0010.

5.1.2 Mainframe Datasets

On a mainframe the information is stored in datasets (files -referglossary ). Each dataset should have an unique name of maximum 44characters long in this format:

XXXXXXXX.XXXXXXXX.XXXXXXXX (For example,AGY0232.CUSTOMER.DATA)

Following points should be considered while creating mainframedatasets.

  A dataset name consists of segments or qualifiers.

  Each qualifier has maximum eight characters and are separated by a period(.).

  The qualifier or segment should start with a capital letter

Introduction to Computer Systems

Computing Environments

Page 128: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 128/166

12/9/13 Introduction To Computer Systems TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.2_mainframe-computing-environment_2.html 2/2

(alphabet).

  The operating system looks into the segments to keep a track of

groups of datasets. The first segment of the dataset name is its

High-level Qualifier (HLQ).

  Datasets should have meaningful names. For example,Customers data should be stored in a file named

CUSTOMER.DATA. Here customer and data are the two

segments or qualifiers of your dataset name.

To access or log-in to Mainframes, we need a TSO (refer glossary)USER-ID, which is similar to user-id that we use to login to a windowsmachine.

Suppose your TSO-id is AGY0232. So give the High-level qualifierAGY0232 to all your datasets . This way you can identify the datasets belongingto you.

For example, name your Customer dataset asAGY0232.CUSTOMER.DATA.

Mainframes have Security software products like RACF(

Resource Access Control Facility) which control access to datasets. Forexample, you may want to grant read-only access to the fileAGY0232.CUSTOMER.DATA to other users. This will prevent other users frommaking any changes to your dataset.

Course Contents | Prev : Next

Page 129: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 129/166

12/9/13 Introduction To Computer Systems TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.2_mainframe-computing-environment_3.html 1/3

Course Contents | Prev : Next

5.1 Mainframe Computing Environment

5.1.3 Mainframe Programing

High level language like COBOL is used for Mainframeprograming. There are online mainframe compilers available as well assoftware like Hercules can be installed on any Operating System to simulate amainframe environment.

IBM's MVS Operating system(Multiple Virtual Storage (referglossary) ) up to release 3.8j(released in the year 1981) is also available. IBMprovides a pre-configured starter system in which you can do some coding todescribe the configuration to be installed. This is called System Generation(Sysgen) that is, the process of setting up or installing an operating system onthe mainframe.

We can code COBOL-Programs and run them using a Job (JCL – Job Control Language) on a Mainframe-Computer using its TSO User-id for agiven time. Refer Figure 5. 3 for the basic skeleton of a COBOL Program. ACOBOL program is written in structures called divisions. Divisions in turn canhave many sections. Sections can have many paragraphs.

The Mainframe terminal has 80 columns on a line for coding. Thearea from columns 8 to 11 is called Area A. The area between columns 12 to 72is called Area B. Refer Figure 5. 4 for a sample program to display a messageHello World.

A COBOL program has following divisions :

  IDENTIFICATION DIVISION – This division records useful

information like author name or date when the program was

created. It should at least have the program name or ID.

  ENVIRONMENT DIVISION - This division tells the computer

about the other resources that the program will interact with

(that is, its environment) such as printers, disk drives, other files

etc.

Introduction to Computer Systems

Computing Environments

Page 130: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 130/166

12/9/13 Introduction To Computer Systems TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.2_mainframe-computing-environment_3.html 2/3

For example, SOURCE-COMPUTER. IBM PC.

This information tells the configuration of the computer on

which the program will execute.

  DATA DIVISION – This division defines the names that the

program will use to refer to the data that it manipulates.

For example, USER-NAME PIC A(15)The PIC ( or the Picture clause ) states that the data stored in

this USER-NAME will be of type alphabets only and a maximum

of 15 characters (like Tom or John) can be stored in USER-

NAME.

  PROCEDURE DIVISION – It is the starting-point of the COBOL-

Program. The programing instructions must be written inside

this PROCEDURE DIVISION. In PROCEDURE DIVISION we canwrite instructions one-after-the other. The Mainframe executes

these instructions one-by-one and step-by-step sequentially. The

last-instruction must be STOP RUN to stop running the COBOL

Program.

Figure 5.3 : COBOL Program Skeleton

Figure 5.4 : COBOL Program

Page 131: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 131/166

12/9/13 Introduction To Computer Systems TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.2_mainframe-computing-environment_3.html 3/3

Course Contents | Prev : Next

Page 132: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 132/166

Page 133: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 133/166

12/9/13 Introduction To Computer Systems TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.3_networks_1.html 2/2

known as Ethernet. Ethernet uses various standards and media to enablecommunication between computer devices.

Wireless LAN technology connects computer devices without theuse of wires or cables.

These devices use transmission mediums like radio waves orinfrared signals as shown in Figure 5. 5 where a desktop computer, a laptopand a cell phone are all connected using wireless technology.

Figure 5.5 : Computer Network

Course Contents | Prev : Next

Page 134: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 134/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.3_networks_2.html 1/2

Course Contents | Prev : Next

a. Twisted Pair

 b. Coaxial Cable

c. Optic Fiber

5.2 Networks

5.2.1 Wired Technologies

Wired networks are of following types :

a. Twisted Pair

It is the most widely used medium for telecommunication. It ismade of copper wires that are twisted into pairs.

  Ordinary land line telephones are a good example where the wires

consist of two insulated copper wires that are twisted into pairs.

  Computer network cabling (wired Ethernet) consists of 4 pairs of

copper cabling that can be utilized for both voice and data

transmission. This twisting of two wires together helps to

reduce crosstalk (refer glossary) and electromagnetic induction.

  Its transmission speed varies from 2 million to 10 billion bits persecond. The Twisted pair cables are of two types: Unshielded

Twisted Pair (UTP) and Shielded Twisted-Pair (STP).

  The unshielded cables are individually

covered but do not have any wrapping or

layer surrounding the twisted pair, that is

why they are called unshielded.

  The shielded cables are individually coveredand the twisted pair is wrapped in a foil

shielding to help provide a more reliable

data communication. They are preferred

Introduction to Computer Systems

Computing Environments

Page 135: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 135/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.3_networks_2.html 2/2

over unshielded cables based on their

advantage of reduced Electromagnetic

interference (disturbance that affects an

electrical circuit resulting into loss of data).

Figure 5.6: Wired Technology : Ethernet Cable

Course Contents | Prev : Next

Page 136: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 136/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.3_networks_3.html 1/2

Course Contents | Prev : Next

5.2 Networks

5.2.1 Wired Technologies

b. Coaxial cable

It is generally used for cable television, office buildings, and otherwork-sites for local area networks.

  The cables consist of copper or aluminum wire surrounded by an

insulating layer, which in turn is surrounded by a conductive

layer. This insulation helps in minimizing interference and

distortion.

  Its transmission speed is between 200 million bits per second to

more than 500 million bits per second.

c. Optical fiber

It is a glass fiber. It makes use of pulses of light to transmit data.

  Its advantages over metal wires include less transmission loss,

immunity from electromagnetic radiation, and very fast

transmission speed, up to trillions of bits per second.

  Different colors of lights can be used to increase the number of

messages being sent over a fiber optic cable.

Introduction to Computer Systems

Computing Environments

Page 137: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 137/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.3_networks_3.html 2/2

Figure 5. 8: Wired Technology : Optic Fiber

Figure 5.7:Wired Technology: Coaxial Cable

Course Contents | Prev : Next

Page 138: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 138/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.3_networks_4.html 1/2

Course Contents | Prev : Next

5.2 Networks

5.2.2 Wireless technologies

Wireless network refers to computer network that is notconnected by cables of any kind. Wireless networks can be of following types :

  Wireless PAN - Wireless personal area networks (WPANs)

interconnect devices within a relatively small area, generallywithin a person's reach. Bluetooth radio or invisible infrared

light provide a WPAN for connecting a headset to a laptop.

  Wireless LAN - A wireless local area network (WLAN) links two or

more devices over a short distance using a wireless method

providing a connection through an access point for Internet

access. The use of spread-spectrum or OFDM (refer glossary)

technologies may allow users to move around within a localcoverage area, still remaining connected to the network.

  Wireless mesh network - It is made up of radio nodes organized in

a mesh topology (Refer section 2.2.3 Network Topology). Each

node forwards messages on behalf of the other nodes. Mesh

networks can automatically re-route around a node that has lost

power.

  Wireless MAN - Wireless metropolitan area networks are a type of

wireless network that connect many wireless LANs. WiMAX is

an example of Wireless MAN.

  Wireless WAN - Wireless wide area networks are wireless

networks that typically cover large areas, like networking

neighboring towns and cities.

  Cellular network - A cellular network or mobile network is a radionetwork distributed over land areas known as cells. Each cell

has at least one fixed-location transceiver( It is usually installed

on a communication tower and basically has the role of sending

Introduction to Computer Systems

Computing Environments

Page 139: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 139/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.3_networks_4.html 2/2

and receiving signals), known as a cell site or base station. These

cells are joined together to provide radio coverage over a wide

geographic area and enable a large number of portable

transceivers (e.g., mobile phones, tablets) to communicate with

each other.

Course Contents | Prev : Next

Page 140: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 140/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.3_networks_5.html 1/2

Course Contents | Prev : Next

5.2 Networks

5.2.2 Wireless technologies

Following Technologies are used to support the Wireless networkconnections:

  Terrestrial microwave communication – It uses Earth-based

transmitters and receivers resembling satellite dishes (ReferFigure 5.11). Terrestrial microwaves are in the low-gigahertz

range limiting all communications to line-of-sight. The relay

stations are placed approximately 48 km (30 mi) apart.

  Communications satellites - These communicate via microwave

radio waves. These waves are not deflected by the Earth's

atmosphere. These satellites stationed in space typically in

geosynchronous orbit 35,400 km (22,000 mi) above the equator(Refer Figure 5.10) can receive and relay data, voice and TV

signals.

  Spread spectrum (refer glossary) technologies use a high-

frequency radio technology to enable communication between

multiple devices in a limited area.

  Infrared communication can transmit signals for small distances

typically less than 10 meters. It uses line-of-sight propagation

which limits the physical positioning of communicating devices.

Figure 5.9: Wireless Technology - Bluetooth

Introduction to Computer Systems

Computing Environments

Page 141: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 141/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.3_networks_5.html 2/2

Figure 5.10: Wirel ess Technology – Communication Satellites

Figure 5.11: Wireless Technology – Terrestrial Microwave

Course Contents | Prev : Next

Page 142: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 142/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.3_networks_6.html 1/3

Course Contents | Prev : Next

5.2 Networks

5.2.3 Network topology

A network topology is the layout describing how the nodes(allcomputer terminals) of a computer network are interconnected. Commonlayouts are explained as follows:

Bus Network

All nodes are connected to a common cable which is called a Bus.

Advantages

  Implementation is easier.

  Best Topology for small networks.

Disadvantages

  Due to the cable length, the number of nodes that can be connected

is also less.

  It can perform well for a limited number of nodes only.

  If the main cable or the Bus fails, then all the nodes connected to it

also fail to serve.

Star Network

All nodes are connected to a central node or hub. This layoutfound typically in a Wireless LAN, where each client connects to the centralWireless access point.

Advantages

  As it is centralized in nature, it is simple in terms of operation.

  It also keeps each device isolated in the network. It means if one

Introduction to Computer Systems

Computing Environments

Page 143: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 143/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.3_networks_6.html 2/3

node stops working, it does not affect the function of other

nodes.

Disadvantage

  The whole network operation is dependent on the central hub. The

entire network fails if the central hub fails.

Ring Network

Advantage

There is no requirement of a central server as the communication

 between two nodes channelizes through all the intermediate

nodes.

Disadvantages

  Even if a single node of the network fails, it can cause the entire

network to fail.

  Entire network is affected whenever any change or movement is

made for a network node.

Mesh Network

Each node connects with a random number of neighbors suchthat there is at least one traversal from each node to any other. Here each nodehas the responsibility of propagating the data.

Advantage

  This arrangement of the network nodes makes it is possible to

transmit data from one node to many other nodes at the same

time.

Disadvantage

  In an arrangement where each node is connected to every other

node of the network, many of the connections may serve no

major purpose as they behave as redundant connections.

Fully Connected Network

Each node connects with all the other nodes in the network.

Page 144: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 144/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.3_networks_6.html 3/3

Advantages

  A fault in one terminal on the network will not effect other nodes,

as the data has multiple redundancy paths that can be used.

  Data transfer rates can be kept at an acceptable level as whenever

network usage is high the data can be transmitted via differentroute hence reducing network clogging.

Disadvantage

  It requires a large amount of wiring.

Figure 5.12: Network Topology

Course Contents | Prev : Next

Page 145: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 145/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.3_networks_7.html 1/3

Course Contents | Prev : Next

5.2 Networks

5.2.4 Network Programming

Computer network programming involves writing computerprograms that communicate with each other across a computer network. Weneed two separate programs for this. The Client program initiates thecommunication and The server program which waits or listens for thecommunication from client. Both endpoints of the communication flow are

called network sockets. Network programming is also known as socketprogramming.

Network Programing can be implemented using any languagewhich needs to provide following network layer functions. Refer Figure 5.13.

  socket() creates a new socket, identified by an integer number, and

allocates system resources to it.

  bind() is used on the server side to associate a socket with a socket

address structure, that is a specified local port number and IP

address.

  listen() is used on the server side and it causes a bound TCP

socket to enter listening state.

  connect() is used on the client side to assign a free local portnumber to a socket. For TCP socket, it causes an attempt to

establish a new TCP connection.

  accept() is used on the server side to accept a received incoming

attempt to create a new TCP connection from the remote client.

It creates a new socket associated with the socket address pair of

this connection.

  send()-recv(), write()-read() or sendto()-recvfrom() can be used to

send and receive data to/from a remote socket.

Introduction to Computer Systems

Computing Environments

Page 146: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 146/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.3_networks_7.html 2/3

  The methods send() and recv() are used for

sockets using TCP that is Transmission

Control Protocol like HTTP. This

mechanism has error checking and

guarantees no data loss. It is used for all

such applications where you can not allowdata loss like browsing websites.

  The methods sendto() and recvfrom() are used

for sockets using UDP (User Datagram

Protocol like Voice over Internet Protocol or

VOIP used to make phone calls using

internet. This has lower level of security anddoes not guarantee that the data will reach

its destination.)

  close() causes the system to release resources that are allocated to

a socket. The connection is terminated in case of TCP sockets.

  unlink() removes the file names created for the socket. So now the

socket is removed and new socket with same name can becreated when required.

Some additional methods that can be used are as follows:

  gethostbyname() and gethostbyaddr() are used to resolve

host/server names and addresses.

  select() is used for one or more of a provided list of sockets to beready to read or ready to write.

  poll() is used to check the socket's state. The whole set of sockets

can be tested to see if we can read or write to any socket or if an

error occurred.

  setsockopt() is used to set the socket option for the given socket.

These options can be like SO_KEEPALIVE (keep the connectionalive by periodic transfer of messages), SO_BROADCAST

(Allows a single message to be sent (broadcasted) to all the

networked clients) , etc.

Page 147: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 147/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.3_networks_7.html 3/3

  getsockopt() gives the current value of a socket option for the

specified socket.

Figure 5.13: Network Programing flow chart

Course Contents | Prev : Next

Page 148: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 148/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.4_internet_1.html 1/2

Course Contents | Prev : Next

5.3 Internet

The Internet is a network connecting computers from across theworld enabling data exchange between them.

Internet consists of independent hosts following the protocols.The World Wide Web is a way of exchanging information over this medium ofinternet.

The system consists of at least two computers connected in sucha way that at any instance of time one acts as a client (requesting data orservice) and the other machine works as a host or server (providing the data orservice).

The Internet can be accessed almost anywhere in many ways.Data cards, mobile phones, hand-held game consoles and cellular routersprovide wireless connection to the Internet.

Figure 5.14: Internet Connection Sharing

Introduction to Computer Systems

Computing Environments

Page 149: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 149/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.4_internet_1.html 2/2

Course Contents | Prev : Next

Page 150: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 150/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.4_internet_2.html 1/2

Course Contents | Prev : Next

5.3.1 Internet Protocols

A protocol is a common means or rules for unrelated objects tocommunicate with each other. A protocol is a description of:

  The messages that are understood by both the communicating

objects.

  The arguments or data that these messages may be supplied with.

  The types of results returned by these messages.

  The information that is preserved despite modifications to the

state of an object.

  Any exceptional situations that needs to be handled during this

communication.

The protocol used for data flow or communication between thenetworks connected in an internet is called Internet Protocol. The Internetprotocol suite is a model architecture that divides methods into a layeredsystem of protocols.

The layers represent the scope or environment in which theirservices operate. (Refer Figure 5.15). The layers are as follows:

  Application Layer - It is the space for the application-specific

networking methods used in software applications like a web

 browser program.

  Transport layer - It connects applications on different hosts via the

network (like client–server model) with appropriate data

exchange methods.

  Internet layer - It enables computers to identify and locate each

5.3 Internet

Introduction to Computer Systems

Computing Environments

Page 151: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 151/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.4_internet_2.html 2/2

other via Internet Protocol (IP) addresses. It connects them to

one another via intermediate (transit) networks. (Refer Figure

5.16).

  Software layer – It is the link layer and provides connectivity

 between hosts on the same local network link, such as a local

area network (LAN) or a dial-up connection.

The model known as TCP/IP, is designed to be independent of theunderlying hardware.

Internet Protocol (IP) is the most prominent component of theInternet model. It provides addressing systems (IP addresses) for computers onthe Internet.

IP Version 4 (IPv4) is the initial version of Internet Protocol. It wasdesigned to address up to approximately 4.3 billion (109) Internet hosts and isstill in dominant use.

A new protocol version IPv6 was developed in the mid-1990s andis currently in growing deployment around the world. It provides vastly largeraddressing capabilities and more efficient routing of Internet traffic.

Figure 5.15: Internet Protocol Layer

Course Contents | Prev : Next

Page 152: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 152/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.4_internet_3.html 1/2

Course Contents | Prev : Next

5.3 Internet

5.3.2 Internet Routing

IP forwarding also known as Internet routing is a process used todetermine the path for your data contained in structures called datagrams orpackets (refer glossary) . The process uses routing information to make decisionsand is designed to send a packet over multiple networks.

Internet Service Providers (ISPs are the organizations that provide

access to internet) connect their customers to those of other ISPs.

At the top of the routing hierarchy are Tier-1 networks held by largetelecommunication companies which exchange traffic directly across to all otherTier-1 networks via agreements such that they don't have to pay each other for thedata transferred every now and then .

Tier-2 networks buy Internet transit from Tier-1 ISP to reach the globalInternet. That is, to reach a remote network, the smaller ISPs have to connect to first

Tier-1 network which in turn may be connected to that remote network. For thisconnectivity they have to pay some amount.

ISPs generally use a single upstream provider for connectivity. Theymay use multihoming (refer glossary) to provide protection from problems withindividual links.

Internet exchange points hold the physical connections betweenmultiple ISPs.

Computers and routers use routing tables (Refer Figure 5.17) to directIP packets among locally networked machines. These tables can be constructedmanually or automatically via DHCP (Dynamic Host Configuration Protocol) for anindividual computer or a routing protocol for routers themselves. In single-homednetworks, a default route usually points up toward an ISP providing transit. Thehigher-level ISPs use the Border Gateway Protocol (refer glossary) to determinepaths to any given range of IP addresses across the complex connections of theglobal Internet.

Introduction to Computer Systems

Computing Environments

Page 153: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 153/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.4_internet_3.html 2/2

Figure 5.16: Network Routing

Figure 5.17: Routing Table

Course Contents | Prev : Next

Page 154: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 154/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.5_introduction-to-websites_1.html 1/2

Course Contents | Prev : Next

5.4 Websites

A website is a set of related web pages containing information in formof text, images, audio, video etc. A website is hosted on one or more web server(s)and can be accessed by internet. World Wide Web (WWW) is the term used to refercollection of all public websites.

A web page is a single document written in plain text. It is formattedusing instructions of Hypertext Markup Language (HTML).

The general features of a website are described as follows:

A protocol is a common means or rules for unrelated objects tocommunicate with each other. A protocol is a description of:

  The home page of a website contains an introduction to that site and

links to other related pages or to other websites.

  A website can be owned by an organization or an individual also.

  Websites may host static content that remains same for all the viewers

or they may host dynamic content that changes as per the visiting

user's preferences.

  To access a website, we need its address. For example, www.tcs.com

  The letters in the website address after the last dot(.) indicates the type

of websites. For example, .com means Commercial Organization, .edu

refers to educational sites, .gov is for government  websites, .jobsmeans job websites, etc.

  A website is accessed using Hypertext Transfer Protocol (HTTP) . It may

also use encryption (HTTP Secure, HTTPS (refer glossary) ) to provide

security and privacy.

  The user's web browser understands the HTML instructions and

displays the page content accordingly.

Introduction to Computer Systems

Computing Environments

Page 155: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 155/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.5_introduction-to-websites_1.html 2/2

Figure 5.18: Websites

Course Contents | Prev : Next

Page 156: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 156/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.5_introduction-to-websites_2.html 1/2

Course Contents | Prev : Next

5.4 Websites

5.4.1 Static website

A static website usually displays the same information (staticinformation) to all visitors. It is similar to a printed brochure.

It provides consistent and standard information for aconsiderable long period.

The website may however receive updates occasionally. Theseupdates are done using a manual process to edit the text, photos and othercontent. This kind of editing requires a software and basic skills to use it.

Static websites can be edited using the following categories ofsoftware:

  Text editors - Here content and HTML markup are manipulateddirectly within the editor program. For example, Notepad,

Notepad++.

  WYSIWYG (refer glossary) offline editors – These provide a GUI

interface. The output is in form of HTML markup generated

automatically by the editor software. For example, Microsoft

FrontPage and Adobe Dreamweaver

  WYSIWYG online editors – These can be used to create online web

pages including widgets, blogs, and other documents containing

images and other media. For example, SnapEditor.

  Template-based editors - These allow quick creation and

uploading of web pages to a web server. A detailed HTML

knowledge is not required. You just need to pick a desired

template from available options and add pictures and text to it

without directly writing or updating HTML code. For example,

RapidWeaver and iWeb.

Introduction to Computer Systems

Computing Environments

Page 157: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 157/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.5_introduction-to-websites_2.html 2/2

Course Contents | Prev : Next

Page 158: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 158/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.5_introduction-to-websites_3.html 1/2

Course Contents | Prev : Next

5.4 Websites

5.4.2 Dynamic Website

A dynamic website has the ability to change or customize itselffrequently and automatically at some specific time interval or based on somecriteria.

Dynamic websites offer dynamism in two aspects : Code and

Content. The dynamic code execution is not visible to the user. The user cansee the dynamic content only.

  Dynamic code - The code is executed on the fly based on some user

event. Scripting languages like Javascript, Ajax are used for this.

A website with dynamic code has following characteristics :

  It recalls all the bits of information from a

database and consolidates them in apredefined format.

  It interacts with users in various ways like

using cookies for finding previous history.

  Direct interaction using form elements and

mouse hovers also reflect the user event and

cause the dynamic code to execute.

  It can display the current state of a interaction

 between users. It can capture information

personalized to the requirements of the user.

  Dynamic content - The web page content keeps on varying based

on some criteria, either predefined rules or variable user input.

  For example, a news website can use apredefined rule which tells it to display all

news articles for today's date and for your

country or location only.

Introduction to Computer Systems

Computing Environments

Page 159: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 159/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.5_introduction-to-websites_3.html 2/2

  Such a website automatically shows the most

current news articles on any given date.

  Consider a retail website which allows a user

to input a search request for the keyword

like Guitar. In response, the content of the

web page will spontaneously change and

will then display a list of Guitar and music

products like CDs (Compact Disks) and

DVDs (Digital Versatile Disk).

Course Contents | Prev : Next

Page 160: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 160/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.6_summary.html 1/3

Course Contents | Prev : Next

Summary

  Computing Environment is a collection of computers, and various

software in a network. All these computers collaborate with

each other for storing,processing and exchanging electronic

information.

  Mainframe computing environment is capable of doing bulk

calculations with very high level of accuracy,security and speed.

  Mainframe programs are written using COBOL and JCL. We need

a TSO (refer glossary) user id to access the time slot on a

mainframe server.

  A computer network joins two or more computing devices so that

they can communicate with each other. Networks can be of two

types that is, wired or wireless.

  Twisted pair, Coaxial cables and Optic fiber technologies are used

to connect a wired network.

  Terrestrial Microwave, Satellites, Spread Spectrum and Infrared

technologies are used to connect various computing devices

without wires.

  Computer networks can have their nodes connected in forms likeBus, Star Ring, Mesh or Fully Connected topology.

  Network or Socket programing can be done using various

programing language and all of them provide the basic methods

for reading and writing to a network and listening for requests

from the client.

  Internet connects computers across the world. It is based onprotocols. Each computer in the internet is identified by an IP

address.

Introduction to Computer Systems

Computing Environments

Page 161: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 161/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.6_summary.html 2/3

  The communication between two computers may be routed

through various networks.

  A Website may be accessed using http protocol from any where on

the internet. It can be of two types : Static and dynamic.

  Static websites are like the profile of a company or product anddoes not change often and displays the same details to all

visitors.

  Dynamic websites change their content as per time and user

preferences like news, e-commerce websites.

  Dynamic code - The code is executed on the fly based on some user

event. Scripting languages like Javascript, Ajax are used for this.A website with dynamic code has following characteristics :

  It recalls all the bits of information from a

database and consolidates them in a

predefined format.

  It interacts with users in various ways like

using cookies for finding previous history.

  Direct interaction using form elements and

mouse hovers also reflect the user event and

cause the dynamic code to execute.

  It can display the current state of a interaction

 between users. It can capture information

personalized to the requirements of the user.

  Dynamic content - The web page content keeps on varying based

on some criteria, either predefined rules or variable user input.

  For example, a news website can use a

predefined rule which tells it to display all

news articles for today's date and for your

country or location only.

  Such a website automatically shows the most

current news articles on any given date.

  Consider a retail website which allows a user

Page 162: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 162/166

12/9/13 Introduction to Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.6_summary.html 3/3

to input a search request for the keyword

like Guitar. In response, the content of the

web page will spontaneously change and

will then display a list of Guitar and music

products like CDs (Compact Disks) and

DVDs (Digital Versatile Disk).

Course Contents | Prev : Next

Page 163: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 163/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.7_glossary.html 1/4

Course Contents | Prev : Next

Glossary

Term used Description

Border

Gateway

Protocol

It is an exterior gateway routing protocol that enables groups of

routers (called autonomous systems) to share routing

information such that efficient and loop-free routes are

established. It is used within and between Internet ServiceProviders (ISPs).

Bridge

A Bridge is a box with ports (usually two) to connect LAN

segments or similar networks within a limited geographic area.

It examines the data passing through it and can recognize where

it came from, and forwards it to the connected LAN.

Critical

Applications

Applications that are highly secure and accurate. For example

Banking applications as they deal with monetary transactions

or Applications involved in controlling Air Traffic or guiding

satellites.

Crosstalk

Crosstalk (XT) is any phenomenon by which a signal

transmitted on one circuit or channel of a transmission systemcreates an undesired effect in another circuit or channel. For

example pieces of speech or signaling tones leaking from other

people's connections in a telephone call.

Datagram

A datagram is a basic transfer unit associated with a network

service. It does not guarantee the delivery, arrival time, and

order of arrival. It can be compared to a postal mail delivery

service where the user provides the destination address but

receives neither any guarantee of delivery nor any confirmation

upon successful delivery.

Introduction to Computer Systems

Computing Environments

Page 164: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 164/166

12/9/13 Introduction To Computer Systems -- TATA Consultancy Services Pvt. Ltd.

https://aspire.tcs.com/aspire/courses/introduction_to_computer_systems/module5/session5.7_glossary.html 2/4

Encryption

Encryption is the process of encoding messages (or

information) in such a way that eavesdroppers or hackers

cannot read it, but authorized parties can. The communicating

parties must usually agree on a symmetric secret key before

they wish to communicate. The plain text message can then be

coded by using the key and an algorithm. Once received it can

 be decoded using the same key and converted to readable plaintext.

Enterprise

Resource

Planning

ERP (Enterprise Resource Planning) facilitates the information

exchange between all business functions inside an organization.

ERP systems have following characteristics:

A common database is used to support all applications.

The whole application has a consistent look and feel.

Easy modular installation of the system.

Ethernet

Xerox Corporation in cooperation with DEC and Intel in 1976

developed Ethernet as an architecture for Local Area Network

(LAN). It uses either bus or star topology and its version

100Base-T supports data transfer rates greater than 100 Mbps.

Files

Computer or Digital files are same as paper documents stored

in computer memory. A computer file stores information and is

always available for computer programs whenever required.

Gateway

A Gateway links two different types of networks. Also, it

usually involves converting to and from different protocols. For

example, it can convert a TCP/IP protocol based informationinto a NetWare IPX based information.

Large

scale,high

end

commercial

systemarchitectures

These are the computers having their architecture defined by

redundant internal engineering, extensive input-output

facilities, very high reliability, high security, strict backward

compatibility, high hardware and computational utilization

rates to support massive throughput. These computers are themost expensive and technically sophisticated and run without

any interruptions for long time period.

Page 165: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 165/166

Page 166: Introduction to Computer Systems - Ilpintcs.blogspot.in

8/18/2019 Introduction to Computer Systems - Ilpintcs.blogspot.in

http://slidepdf.com/reader/full/introduction-to-computer-systems-ilpintcsblogspotin 166/166