0% found this document useful (0 votes)
3 views74 pages

Chapter 5 System-Software

Chapter 5 discusses system software, focusing on operating systems and utility software. It outlines the essential functions of an operating system, such as managing hardware, processes, memory, and security, as well as the importance of utility software for system maintenance. Additionally, it explains the role of program libraries and dynamic link libraries in software development.

Uploaded by

Keerthi Mohan
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views74 pages

Chapter 5 System-Software

Chapter 5 discusses system software, focusing on operating systems and utility software. It outlines the essential functions of an operating system, such as managing hardware, processes, memory, and security, as well as the importance of utility software for system maintenance. Additionally, it explains the role of program libraries and dynamic link libraries in software development.

Uploaded by

Keerthi Mohan
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Chapter 5: System Software

5.1 Operating System

5.2 Language Translators

25/10/2021 By: Noureddine Tadjerout 1


Lesson Objectives: 5.1 Operating System
Explain why a computer system requires an Operating System (OS)
Explain the key management tasks carried out by the Operating System:
Including memory management, file management, security management, hardware
management (input / output / peripherals), process management.

Show understanding of the need for typical utility software provided with an Operating
System:
Including disk formatter, virus checker, defragmentation software, disk contents
analysis/disk repair software, file compression, back-up software.
Show understanding of program libraries: Including:

• software under development is often constructed using existing code from program
libraries
• the benefits to the developer of software constructed using library files, including
Dynamic Link Library (DLL) files.
25/10/2021 By: Noureddine Tadjerout 2
5.1 Operating System
Watch the video for the Operating System
[Link]

25/10/2021 By: Noureddine Tadjerout 3


5.1 Operating System

25/10/2021 By: Noureddine Tadjerout 4


5.1 Operating System
An operating system is a collection (or suite) of programs that manages and controls the
computer. Operating systems have many functions:

•controlling hardware components


•providing a platform for software to run on
•providing a user interface
•managing processes
•managing the computer's memory
•managing input and output devices
•managing applications
•managing security

Example operating systems include:

•Microsoft Windows
•Apple OS X
•Linux
•Android
•IOS

25/10/2021 By: Noureddine Tadjerout 5


5.1 Operating System
1) Operating System:
Most people use computers because they want to use application software(such as word
processing, internet browsing) however these applications only work inside of an operating
system environment. The operating system is the software that controls, manages and run all of
the applications on the computer.

The functions of an operating system include:

1-Loading a software interface for the user to interact with (usually a GUI or CLI)
2-Managing hardware resources such as memory and devices
3-User management
4-authentication & security
5-File management

When a user is using a computer they are either interacting directly with the operating system
( e.g. logging in to the computer) or via an application (e.g. saving a word processing document)
25/10/2021 By: Noureddine Tadjerout 6
5.1 Operating System
Processor management
Multitasking means to be able to run more than one program simultaneously. These
programs perform processes. In the past, computers with CLIs were unable to
multitask - the operating systems of the day only allowed one program to run at a
time.

Modern operating systems are multitasking in that they allow several programs to run
side-by-side. It is not uncommon for a user to be streaming music while entering text
into a word processor, or streaming a video while making a backup of files.

Multitasking is possible only if:

-the operating system can support multitasking


-the computer has enough memory to hold more than one program in primary at
the memory same time

25/10/2021 By: Noureddine Tadjerout 7


5.1 Operating System
Multitasking
Most general use systems (e.g. desktops, laptops, tablets) allow multitasking, where
most than one program is open at one time.

Advantages
Allows a combination of active and passive user interaction, e.g.:
Type up a word processing document while listening to music.
Editing images while burning files to an optical device (DVD / CD)
Allows rapid switching between applications which can make the use more efficient.

Disadvantages
Multiple open applications can slow down the computer, making it harder to use.
Requires more physical resources (CPU power / memory) so uses more battery.
Can offer unwanted distractions from the task at hand.

25/10/2021 By: Noureddine Tadjerout 8


5.1 Operating System
Memory management
Computer memory must be managed to ensure that:
- more than one program can run at the same time
- more than one document can be opened at the same time
One method of memory management is known as paging. Memory is broken up into fixed-size
blocks, known as pages.

Different operating systems allocate their own size to pages. For example, memory pages in
modern operating systems are typically 4 kilobytes (KB) in size.

When a program is run, it is loaded into memory. The operating system determines how much
memory the program requires, and allocates enough pages to hold it and its documents. When
the program is closed, the allocated pages are freed up for use by other programs.
The pages a program occupies may or may not be contiguous, but this does not matter. The
operating system knows what each page occupies and fetches the data held in them when
needed.

25/10/2021 By: Noureddine Tadjerout 9


5.1 Operating System
Memory management
Consider this example. Program A requires two pages. It is allocated pages 0 and 1. Program B
requires three pages. It is allocated pages 2, 3 and 4.

25/10/2021 By: Noureddine Tadjerout 10


5.1 Operating System
Memory management
Program A now closes, and Program C now runs. Program C requires three pages. Pages 0 and 1
are now free, so Program C is allocated pages 0, 1 and 5.

25/10/2021 By: Noureddine Tadjerout 11


5.1 Operating System
Input/output devices management
Input and output devices, which are also known as peripherals, are hardware devices
connected to a computer, such as a screen, printer, keyboard or camera.

To operate a peripheral, the operating system uses a program called a device driver.
Device drivers contain instructions on how to control a device. Each connected device
has its own driver.

Using device drivers brings two advantages:

any device can be used with the operating system, as long as a driver is available for it
drivers can be updated, usually to give better performance or to remove a bug

25/10/2021 By: Noureddine Tadjerout 12


5.1 Operating System
Applications management

Application programs and hardware can communicate through an interface provided by the
operating system. This is known as the application programs interface (API).

The applications manager allocates memory space and determines time needed by a processor
for an application to run

25/10/2021 By: Noureddine Tadjerout 13


5.1 Operating System

25/10/2021 By: Noureddine Tadjerout 14


5.1 Operating System

25/10/2021 By: Noureddine Tadjerout 15


5.1 Operating System

25/10/2021 By: Noureddine Tadjerout 16


5.1 Operating System

25/10/2021 By: Noureddine Tadjerout 17


5.1 Operating System
Security management

Operating systems also manage security. They allow:

- individual users to be created and deleted


- access levels to be given to users, such as administrator rights or standard user rights
- auditing (keeping a log) of files a user creates, accesses, edits and deletes

25/10/2021 By: Noureddine Tadjerout 18


5.1 Operating System
File management:
File management is one of the basic and important features of operating system. Operating
system is used to manage files of computer system. All the files with different extensions are
managed by operating system.

A file is collection of specific information stored in the memory of computer system. File
management is defined as the process of manipulating files in computer system, it
management includes the process of creating, modifying and deleting the files.

The following are some of the tasks performed by file management of operating system of
any computer system:
- It helps to create new files in computer system and placing them at the specific locations.
- It helps in easily and quickly locating these files in computer system.
- It makes the process of sharing of the files among different users very easy and user friendly.
-
It helps to stores the files in separate folders known as directories. These directories help users
to search file quickly or to manage the files according to their types or uses.
It helps the user to modify the data of files or to modify the name of the file in the directories.
25/10/2021 By: Noureddine Tadjerout 19
5.1 Operating System
2)-Utility Software
Utility software helps maintain the system. Utility software includes:
- encryption software
- defragmentation software
- data compression software
- backup software
- virus checker
- disk formatter
- disk contents analysis
- disk repair software

1- encryption software:
Encryption software disguises the contents of files so they can only be understood by authorized
users. The software uses a complex algorithm to scramble the content so that it appears to be
gibberish. Only authorized users can unscramble the content.
The software can encrypt specified files, or the whole of the hard disk on which the files are
stored.
You can read more about encryption by clicking the link below:
[Link]
5.1 Operating System
Watch the video for Utility Software and Models
[Link]

25/10/2021 By: Noureddine Tadjerout 21


5.1 Operating System
2)-Utility Software
2- Defragmentation Software:
[Link]

25/10/2021 By: Noureddine Tadjerout 22


5.1 Operating System
2)-Utility Software
2- Defragmentation Software:
When a file is stored on a hard disk it is actually stored not as a whole file, but as a series of
segments. Sometimes the segments run together in sequence (see File 1) and sometimes the
segments are split up over a disk (see File 3). This is known as fragmentation

25/10/2021 By: Noureddine Tadjerout 23


5.1 Operating System
2)-Utility Software
2- Defragmentation Software:
Over time, more and more files become fragmented, as do individual files. A fragmented disk
takes longer to read from and write to, making a computer run slower.

25/10/2021 By: Noureddine Tadjerout 24


5.1 Operating System
2)-Utility Software
2- Defragmentation Software:
Defragmentation software takes the fragmented files and rearranges the segments so that they
run contiguously. This decreases read/write time, thereby speeding up computer performance.

25/10/2021 By: Noureddine Tadjerout 25


5.1 Operating System
2)-Utility Software
3- Data Compression Software:
Compression software reduces the size of a file stored on secondary storage.

Smaller files are easier to transmit across a network as they require fewer packets to be sent.
Their reduced size also means more files can be stored in any given area of storage.

You can read more about compression by clicking the link below :

[Link]

25/10/2021 By: Noureddine Tadjerout 26


5.1 Operating System
2)-Utility Software
4- Backup Software:
Data can be lost accidentally, or deliberately. A user may accidentally delete or overwrite a file,
or a hard disk may fail, preventing access to any files stored on it. A hacker or malicious user
may deliberately delete or overwrite data.

To prevent data loss, regular copies of the data should be made. A copy of data is known as a
backup. Backups can contain a copy of all files on a computer, or just ones specified by a user.

Network managers make regular backups of all files on a network using backup software.
The software automatically makes a backup at a scheduled time of day, usually during the
evening when the network is quiet. Backups are usually made to a high capacity secondary
storage device, or to the cloud.

25/10/2021 By: Noureddine Tadjerout 27


5.1 Operating System
2)-Utility Software
4- Backup Software:
If data loss occurs, data can be retrieved from the backup. The software allows all backed-up
files to be retrieved or just specified files.

Two types of backup are possible:


- full backup
- incremental backup

A full backup involves making a copy of every file on the computer or network. They can require
a lot of storage space and can be time consuming to make.

Incremental backups take a copy of any new files created since the last backup, or of any files
that have been edited, such as user documents.

Most network managers make an initial full backup and then switch to daily incremental
backups. This way all data is backed up and daily backups are small and less time-consuming.
25/10/2021 By: Noureddine Tadjerout 28
5.1 Operating System
2)-Utility Software
4- Virus Checker:
Antivirus software, or antivirus software (abbreviated to AV software), also known as anti-
malware, is a computer program used to prevent, detect, and remove malware.

Antivirus is a kind of software used to prevent, scan, detect and delete viruses from a computer.
Once installed, most antivirus software runs automatically in the background to provide real-
time protection against virus attacks.

Comprehensive virus protection programs help protect your files and hardware from malware
such as worms, Trojan horses and spyware, and may also offer additional protection such as
customizable firewalls and website blocking.

25/10/2021 By: Noureddine Tadjerout 29


5.1 Operating System
2)-Utility Software
5- Disk formatter:
Disk formatting is the process of preparing a data storage device such as a hard disk drive, solid-
state drive, floppy disk or USB flash drive for initial use. In some cases, the formatting operation
may also create one or more new file systems.

6- Disk contents analysis:


A disk analyzer is a piece of software that checks drives for space and usage and explores files
and folders visually, simplifying file cleanup and optimization ( mean the action of making the
best or most effective use of a situation or resources).

7- disk repair software:


Disk Utility can check for and fix errors related to the formatting and directory structure of a
Mac storage device. Disk Utility can fix certain disk problems—for example, multiple apps quit
unexpectedly, a file is corrupted, an external device doesn't work properly, or your computer
won't start up.

25/10/2021 By: Noureddine Tadjerout 30


5.1 Operating System
3)-Program Libraries
A library is a collection of non-volatile resources used by computer programs, often for software
development. These may include configuration data, documentation, help data, message
templates, pre-written code and subroutines, classes, values or type specification.

Library programs contain code and data that provide services to other programs such as
interface (look and feel), printing, network code and even the graphic engines of computer
games. If you have ever wondered why all Microsoft Office programs have the same look and
feel, that is because they are using the same graphical user interface libraries. For computer
games a developer might not have the time and budget to write a new graphics engine so they
often buy graphical libraries to speed up development, this will allow them to quickly develop a
good looking game that runs on the desired hardware. For example Battlefield 3 and Need for
Speed both use the same Frostbite engine.
Below is an example of how you might import libraries into python:

25/10/2021 By: Noureddine Tadjerout 31


5.1 Operating System
Dynamic link library (DLL):

A dynamic link library (DLL) is a collection of small programs that can be loaded when needed by
larger programs and used at the same time. The small program lets the larger program
communicate with a specific device, such as a printer or scanner.

[Link]
ibrarydll9_5.html

25/10/2021 By: Noureddine Tadjerout 32


5.1 Operating System
Practical Activates
Open the document or the Pdf below:

25/10/2021 By: Noureddine Tadjerout 33


Learning Objective: 5.2 Language Translators
Show understanding of the need for:
• assembler software for the translation of an assembly language program
• a compiler for the translation of a high-level language program
• an interpreter for translation and execution of a high-level language program
Explain the benefits and drawbacks of using either a compiler or interpreter and justify the use
of each

Show awareness that high-level language programs may be partially compiled and partially
interpreted,
such as Java

Describe features found in a typical Integrated Development Environment (IDE)


Including:
• for coding, including context-sensitive prompts
• for initial error detection, including dynamic syntax checks

• for presentation, including prettyprint, expand and collapse code blocks

• for debugging, including single stepping, breakpoints, i.e. variables, expressions, report
34
window
5.2 Language Translators
Watch the video for Translators (Assemblers, Compilers & Interpreters)
[Link]

35
5.2 Language Translators
Assembler Software:
The Assembler is a Software that converts an assembly language code to machine code. It takes
basic Computer commands and converts them into Binary Code that Computer’s Processor can
use to perform its Basic Operations. These instructions are assembler language or assembly
language.
We can also name an assembler as the compiler of assembly language. This is because a
compiler converts the high-level language to machine language. On the other hand, an
assembler is doing the same task but, for assembly language, the name compiler of assembly
language.

What is an Assembly Language?

An assembly language is a low-level language. It gives instructions to the processors for different tasks. It is
specific for any processor. The machine language only consists of 0s and 1s therefore, it is difficult to write a
program in it. On the other hand, the assembly language is close to a machine language but has a simpler
language and code.

36
5.2 Language Translators
Assembler Software:
What is an Assembly Language?
Assembly language is used. It uses opcode for the instructions. An opcode basically gives
information about the particular instruction. The symbolic representation of the opcode
(machine level instruction) is called mnemonics. Programmers use them to remember the
operations in assembly language.

For example ADD A,B

Here, ADD is the mnemonic that tells the processor that it has to perform additional function.
Moreover, A and B are the operands. Also, SUB, MUL, DIVC, etc. are other mnemonics.

37
5.2 Language Translators
Assembler Software:
Types of Assembler
Assemblers generate instruction. On the basis of a number of phases used to convert to
machine code, assemblers have two types:
1. One-Pass Assembler
These assemblers perform the whole conversion of assembly code to machine code in one go.
2. Multi-Pass/Two-Pass Assembler
These assemblers first process the assembly code and store values in the opcode
table and symbol table. And then in the second step, they generate the machine code using
these tables.
a) Pass 1
- Symbol table and opcode tables are defined.
- keep the record of the location counter.
- Also, processes the pseudo instructions.
b) Pass 2
Finally, converts the opcode into the corresponding numeric opcode.
Generates machine code according to values of literals and symbols

38
5.2 Language Translators
Assembler Software:
Some Important Terms:
Opcode table: They store the value of mnemonics and their corresponding numeric values.

Symbol table: They store the value of programming language symbols used by the programmer,
and their corresponding numeric values.

Location Counter: It stores the address of the location where the current instruction will be
stored.

39
5.2 Language Translators
Assembler Software:
Watch the video for Assembly language Symbol Table AS/A level Exam PPQ W17 QP 12
[Link]

40
5.2 Language Translators
Compilers and interpreters:
Watch this video below for Interpreters and Compilers
[Link]

41
5.2 Language Translators
Differences between Interpreter and Compiler:

42
5.2 Language Translators
Integrated Development Environment (IDE):
An integrated development environment (IDE) is a software application that provides comprehensive
facilities to computer programmers for software development. An IDE normally consists of at least a source
code editor, build automation tools and a debugger. Some IDEs, such as NetBeans and Eclipse, contain the
necessary compiler, interpreter.

1- Prettyprinting:
Prettyprint refers to the presentation of the program code typed into an editor. For example,
the Python IDLE (see Figure 8.02) automatically colour-codes keywords, built-in function
calls, comments, strings and the identifier in a function header. In addition, indentation is
automatic.

43
5.2 Language Translators
Integrated Development Environment (IDE):
Context-sensitive prompts
This feature displays hints (or a choice of keywords) and available identifiers that might be
appropriate at the current insertion point of the program code. Figure 8.03 shows an example
of the Visual Studio editor responding to text typed in by the programmer.

44
5.2 Language Translators
Integrated Development Environment (IDE):
Dynamic syntax checks
When a line has been typed, some editors perform syntax checks and alert the programmer
to errors. Figure 8.04 shows an example of the Visual Studio editor responding to a syntax error.

45
5.2 Language Translators
Integrated Development Environment (IDE):
Expanding and collapsing code blocks
The blue underline shows that there is a syntax error. As you move the mouse pointer over
different parts of the line of code, the editor will display explanations. When working on
program code consisting of many lines of code, it saves excessive scrolling if you can collapse
blocks of statements. Figure below shows the Visual Studio editor window with the procedures
collapsed, so the programmer can see the global variable declarations and the main program
body. The procedure headings are still visible to help the programmer supply the correct
arguments when calling one of these procedures from the main program.

46
5.2 Language Translators
Integrated Development Environment (IDE):
Debugging
An IDE often contains features to help with debugging.
If a Debugger feature has been switched on it is possible to select a breakpoint. When the
program starts running it will stop when it reaches the breakpoint. The program can then be
stepped through, one instruction at a time. Figure 8.05 shows the windows presented to the
user in the Python IDLE when this feature is being used.

47
AS/A Level Exam Question 1

48
AS/A Level Exam Answer 1

49
AS/A Level Exam Question 2

50
AS/A Level Exam Answer 2

51
AS/A Level Exam Question 3

52
AS/A Level Exam Answer 3

53
AS/A Level Exam Question 4

54
AS/A Level Exam Answer 4

55
AS/A Level Exam Question 5

56
AS/A Level Exam Answer 5

57
AS/A Level Exam Question 6

58
AS/A Level Exam Answer 6

59
AS/A Level Exam Question 7

60
AS/A Level Exam Question 7

61
AS/A Level Exam Answer 7

62
AS/A Level Exam Question 8

63
AS/A Level Exam Question 8

64
AS/A Level Exam Answer 8

65
AS/A Level Exam Answer 8

66
AS/A Level Exam Question 9

67
AS/A Level Exam Question 9

68
AS/A Level Exam Question 9

69
AS/A Level Exam Answer 9

70
AS/A Level Exam Answer 9

71
AS/A Level Exam Question 10

72
AS/A Level Exam Question 10

73
AS/A Level Exam Answer 10

74

You might also like