1.2.1/1.2.2-Software/ software development- CS

0.0(0)
studied byStudied by 2 people
0.0(0)
full-widthCall Kai
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/43

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

44 Terms

1
New cards

System vs application software

  • system software manages and is required to run hardware and applications (OS, utility, translators, library programs)

  • application software are programs used by the user (can be either open or closed/proprietary source- which can be off-the-shelf or bespoke)

2
New cards

What is an OS?

Operating system- system software that acts as an interface between the user and computer by controlling hardware

3
New cards

Function of API

application programming interface- a set of code libraries offered by the OS for programmers to write applications

4
New cards

What does the OS manage?

memory, resource/process (scheduling), files (editing/moving), input/output devices (device drivers), interrupt, utility software, user interface (UI), peripheral management (sending I/O data to a buffer to free cpu resources)

5
New cards

Describe memory management

paging- main memory is split into even sections (pages) - separate addresses +non-contiguous

segmentation- main memory split into logical-sized sections (segments) fitting the flow of the program

virtual memory- swapping sections of memory between main memory and the allocated space in secondary storage for virtual memory, which frees up space in main memory

6
New cards

issues that can be caused by virtual memory

disk thrashing- the computer freezes due to sections of memory being swapped too quickly (occurs more frequently as more virtual memory is used)

7
New cards

Describe interruption

interrupts are signals from computer software/hardware/clock that a process requires attention by the processor. These are stored in an interrupt register in a certain priority queue depending on their importance. The OS then decides how to allocate processor time depending on the ISR (interrupt service routine)

8
New cards

Examples of interrupts

  • Input/output device sending request signal

  • power failure

  • clock interrupt (for multitasking)

9
New cards

describe how the Interrupt Service Routine is called

  • interrupt register checked at the end of an FDE cycle

  • if the process in the interrupt register is of higher priority than the current one, the contents of the registers is sent to the stack

  • the appropriate ISR routine is loaded into RAM

  • a flag is set to signal the beginning of the interrupt cycle

  • after the ISR finished, the flag is reset and the interrupt register is checked for higher priority processes before the original process is reloaded

10
New cards

function of scheduling

An algorithm that divides processor time between current programs (jobs) being run, which are either pre-emptive (programs start/stop) or non pre-emptive (once started, runs until completion). This helps process jobs in the least possible time and fairly.

  • maximise throughput

  • ensure fairness between users (equal waiting time)

  • keep hardware resources busy

11
New cards

Types of scheduling algorithms

  • round robin (an equal section of processor time- time slice, based on a timer- is given to each program until it has finished & leaves the queue)

  • first come first served (first programs to enter the queue are the first completed)

  • multilevel feedback queues (multiple queues for differing priority jobs)

  • shortest job first (jobs are ordered based on time to complete, with the shortest done first to completion)

  • shortest remaining time (jobs are ordered in time remaining until completion, with shortest jobs done first)

12
New cards

Which scheduling algorithms are pre-emptive

round robin, multilevel feedback queues, shortest remaining time

13
New cards

which scheduling algorithms are non pre-emptive

first come first served, shortest job first

14
New cards

issues from shortest job first and shortest remaining time algorithms

Can lead to processor starvation (a process does not receive enough processor time to complete e.g. if it has a long completion time). User also has to decide how long the job will take

15
New cards

Which algorithms do not consider job priority

first come first served, round robin

16
New cards

types of operating systems

  • distributed (OS runs across multiple computers= load spread between multiple processors)

  • embedded (within another device with limited range of tasks)

  • multi-tasking (nearly simultaneous completion of tasks using time slicing)

  • multi-user (multiple users use one computer, so scheduling algorithm is needed else processor starvation may occur)

  • real time (performs all tasks in a guaranteed time frame e.g. in time-critical computer systems)

  • mobile OS

17
New cards

Process of starting up a computer

  • PC points to the BIOS in ROM

  • Checks are done to hardware +CPU

  • OS loaded into RAM via bootstrap

18
New cards

BIOS checks

  • POST (power on self test)- checks all hardware are correctly connected/functional

  • checking CPU clock, memory and processor work

  • testing for external memory devices connected to computer

19
New cards

Function of device drivers

Allow the processor to communicate with hardware- they are specific to the computer’s architecture

20
New cards

describe virtual computers

a theoretical computer (software that acts as a computer system +hardware). It provides an environment with a translator for intermediate code to run/test programs

21
New cards

Evaluate virtual computers

  • saves time/money on devices

  • less efficient at running intermediate code

22
New cards

Describe intermediate code

Code that is halfway between machine code and object code (independent of computer architecture but has slower execution)

23
New cards

difference between application and system software

  • application software helps person end-user tasks (specific task) and requires system software to run

  • system software allows the computer to run smoothly/ communication with hardware. It is a platform for applications to run on

24
New cards

What are utilities software

A type of system software that allows for consistent, high performance. Each utility software has a specific function maintaining the OS

25
New cards

Examples of utility software

  • compression (of larger files, usually to transmit across the internet)

  • disk defragmentation (ordering files contiguously to improve processor performance)

  • virus checker (detecting/removing threats in hard disk) + antivirus

  • automatic updating (keeps OS up to date= less threats)

  • backup (of specific files as copies)

  • file management (managing/organising data storage)

26
New cards

what is source code?

Object (programmer) code written before compiling it into machine code

27
New cards

2 types of source code

Open source and closed source

28
New cards

Evaluate open source code

Open source code is freely distributed without license along with the source code

  • can be modified/improved/sold

  • users can offer technical support

  • less security (may not be developed in controlled environment)

  • technical support may be wrong/incorrect

29
New cards

Evaluate closed source code

Closed source code requires the user to have a licence to access it (owner has copyright license)

  • regular, well-tested updates

  • software company gives technical support

  • high level of security

  • restriction of users who can use software at once

  • users cannot modify/improve code

30
New cards

Define translators

programs that convert high level source code to low-level machine code

31
New cards

Describe compilers

  • translate machine code all at once (first into intermediate code called bytecode) after error checks

  • if any changes are made to the source code the whole code must be recompiled

  • longer initial compilation process

  • the object/machine code is hardware-specific

  • the bytecode is platform independent, and can be translated by a virtual machine

32
New cards

name the stages of compilation process

  • lexical analysis

  • syntax analysis

  • code generation

  • code optimisation

33
New cards

describe lexical analysis

  • whitespace and comments (only necessary to humans) are removed

  • for keywords/operators (lexemes), tokens (computer-recognisable unique symbols) are made

  • lexemes and tokens are sorted into a symbol table (contains lexeme, its kind e.g. keyword, its type e.g. real, and run-time address e.g. entity’s address in program)

  • the symbol table is organised as a hash table

34
New cards

describe syntax analysis

  • tokens are grouped (into phrases) and are compared against syntax/grammar rules of the programming language (parsing)

  • any parts that do not fit with the rules are flagged as syntax errors and put in a list of errors

  • an abstract syntax tree of the source code is made

  • semantic analysis (on logic) is also done

35
New cards

describe code generation

  • the abstract syntax tree of the source code is used to generate machine code

36
New cards

describe code optimisation

  • searches through the code to find where it can be made more efficient (to reduce binary footprint as much as possible)

  • e.g. removing redundancies, grouping/replacing repeated code with efficient code

37
New cards

describe interpreters

  • first check for syntax errors, then translate source code line by line, spotting for errors on the way

  • slower than running compiled code

  • good for testing/debugging code

  • can be executed on a variety of devices as long as they have the translator

38
New cards

describe assembly code

  • One level up from machine code

  • the instructions used are dependent on the instruction set of the processor

39
New cards

function of libraries

pre-compiled and tested programs that can be linked, loaded and used by other programmers via static or dynamic linking

  • they can be reused and are error-free

40
New cards

function of linkers

Software that combines libraries and code into a single executable file

Static linkers are included in object/machine code when it is compiled to be used by the CPU= increased binary footprint but no longer needs to be installed

Dynamic linkers load the library in when the machine code is being used by the CPU= smaller binary footprint

41
New cards

function of loaders

They retrieve the executable file from secondary storage into main memory alongside the library files

If done statically, it is loaded with the machine code at the beginning= more memory space used

If done dynamically, the library (linked to the machine code by the linker) is loaded into memory when it is needed by the program

42
New cards

function of memory management

Organises the use of main memory by converting logical addresses (within a program) to physical addresses, which allows memory to be allocated and shared. Programs larger than main memory can also run (through paging).

43
New cards

features of safety-critical systems

  • takes multiple inputs at once

  • responds to inputs/sensors quickly

  • has failsafe mechanisms (detect failures in hardware components and respond appropriately)

  • has redundant hardware to replace failed hardware)

44
New cards

describe differences between off the shelf and bespoke applications

Bespoke

  • take longer to develop

  • may have undetected errors

  • have customisable features

  • more costly

Off the shelf:

  • cheaper

  • more unwanted features

  • can be installed immediately

  • error-free, well tested