slide 1 standard grade computing studies systems software

15
Standard Grade Computing Studies Slide 1 Systems Software

Upload: leslie-alexander

Post on 28-Dec-2015

216 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Slide 1 Standard Grade Computing Studies Systems Software

Standard Grade Computing StudiesSlide 1

Systems Software

Page 2: Slide 1 Standard Grade Computing Studies Systems Software

Standard Grade Computing StudiesSlide 2

Systems Software

We communicate with each other using a language called

English. We can give and receive instructions which we

understand. However, we would not understand the same

instructions if they were given in Russian.

Similarly, we cannot give instructions to the computer in

English because the computer’s own language is called

Machine Code. It consists of only two numbers: 1 and 0.

Page 3: Slide 1 Standard Grade Computing Studies Systems Software

Standard Grade Computing StudiesSlide 3

In the early days of computing, the programmer had to use machine code to write the instructions for the computer to follow. This was very difficult to learn, and easy to make mistakes. - Machine Code is an example of a low level language (LLL).

Special programming languages have now been developed. This makes it easier to program the computer in everyday language. These are called high level languages (HLLs). eg. Comal, BASIC, Pascal, Visual Basic.

A program written in a high level language must be changed into machine code so that the computer can understand it. This is called translation.

Page 4: Slide 1 Standard Grade Computing Studies Systems Software

Standard Grade Computing StudiesSlide 4

Program

A list of instructions which tell the CPU what to do

High Level Languages

BASIC (Beginner’s All-purpose Symbolic Instruction Code)

COMALFORTRANPASCALC ++PROLOGSMALLTALKVISUAL BASIC

Page 5: Slide 1 Standard Grade Computing Studies Systems Software

Standard Grade Computing StudiesSlide 5

Common features of High Level languages:

1. HLL programs are easier to read, write and fix because they are in a language close to English.

2. Programs must be translated into machine code before they can be run.

3. Because a HLL program has to be translated it runs more slowly than a similar program written

in machine code.

4. HLLs are problem oriented.

5. HLLs are easy to change so that they can run on different types of computer.

Page 6: Slide 1 Standard Grade Computing Studies Systems Software

Standard Grade Computing StudiesSlide 6

The systems software is a collection of programs that help the computer hardware to work properly. This includes:

• Translator Programs

• Operating System

• Filing System

We will be looking at Translator Programs in the next section

Page 7: Slide 1 Standard Grade Computing Studies Systems Software

Standard Grade Computing StudiesSlide 7

Translator Programs

The only thing a computer understands is Machine Code. Everything else which goes on in a computer must be changed into Machine Code so that the computer can understand it.

A translator program changes HLL program instructions into machine code.

There are two types of translator programs:

• Interpreters

• Compilers

Page 8: Slide 1 Standard Grade Computing Studies Systems Software

Standard Grade Computing StudiesSlide 8

Program Translation MachineCode

Source

Code

Object

Code

The basic principle of all translation programs is:

Page 9: Slide 1 Standard Grade Computing Studies Systems Software

Standard Grade Computing StudiesSlide 9

(i) Interpreters

Single Instruction

Translation Machine Code

Source Code

Object CodeReport

Errors

Execute&

Discard

Next Instruction

Page 10: Slide 1 Standard Grade Computing Studies Systems Software

Standard Grade Computing StudiesSlide 10

Advantages(i) Translates each line of the program as it is run.(ii) Reports errors after each line. This is a great help

when learning to write programs since errors can be detected and corrected immediately.(Good for beginners)

Disadvantage(i) Since each line of code is translated into machine

code each time the program is run, an interpreted program is slower to run than a compiled program.

ITranslate a HLL into Machine Code, one instruction at a time.

Page 11: Slide 1 Standard Grade Computing Studies Systems Software

Standard Grade Computing StudiesSlide 11

(ii) Compilers

HLL Program

Translation Machine Code

Source Code

Object Code

Save as File

ExecuteReport Errors

Page 12: Slide 1 Standard Grade Computing Studies Systems Software

Standard Grade Computing StudiesSlide 12

Advantages(i) The translation process only takes place once.

Machine code is stored as a file and used when needed.

(ii) Compiled programs run faster than interpreted programs.

Disadvantage(i) Errors are not reported until the whole of the

program has been translated. After correction the program has to be translated again. (Bad for beginners)

Translates a HLL program into Machine Code, all in one go.

Page 13: Slide 1 Standard Grade Computing Studies Systems Software

Standard Grade Computing StudiesSlide 13

Best of both worlds:

Use an interpreter to detect errors and debug program in the development stage.

Once the program works, use a compiler to translate the program into machine code and store it as a file. Use

the machine code file to run the program.

Page 14: Slide 1 Standard Grade Computing Studies Systems Software

Standard Grade Computing StudiesSlide 14

High LevelLanguageto machine

code

Translationtakes placeonly once

Translatesone

instructionat a time

Errormessage

onscreen

Errormessageat end

Difficultto learn

Fast Can saveobjectcode

Interpreter X X X X X

Compiler X X X

Summary of Translators

Page 15: Slide 1 Standard Grade Computing Studies Systems Software

Standard Grade Computing StudiesSlide 15

Software Portability

This is the ability to run a program on several different computer systems without altering it.

LLL programs are hardware specific and are not portable.HLL programs are usually portable.

Portability is important to:• Software companies.• Organisations who own many different computer

systems.