Docsity
Docsity

Prepare for your exams
Prepare for your exams

Study with the several resources on Docsity


Earn points to download
Earn points to download

Earn points by helping other students or get them with a premium plan


Guidelines and tips
Guidelines and tips

Computer Systems and Data Management: Memory, Processor Scheduling, and Database Systems, Lecture notes of Software Development

An overview of computer systems, focusing on memory management, processor scheduling, and database systems. Memory management discusses paging and segmentation methods for managing limited memory resources. Processor scheduling is explained in the context of multi-tasking operating systems. Database systems cover topics such as data models, relational databases, and sql. Interrupts and their handling are also touched upon.

Typology: Lecture notes

2023/2024

Available from 03/06/2024

kareey
kareey 🇬🇧

3.7

(12)

1.3K documents

1 / 11

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
System software notes
10cs52(vtuplanet.com), Lecture
notes of System Programming
A distributed OS provides better _______ by...? - ANSProvides better service:
- Faster processing
- If one section fails, others can potentially continue operating
- Reduction in delays
A software development company is building an operating system for a mobile phone that is in the
process of being designed.
One of the developers is responsible for writing the code for what happens when the CPU receives an
interrupt. Outline what the code must do. [6] - ANS- Complete the current FDE Cycle
- Check the priority of the incoming interrupt.
- If it's of a higher priority than the current task, contents of PC/memory stored in memory in a stack
- The relevant interrupt service routine is loaded by loading the relevant value into the program counter.
- When the interrupt service routine is complete the previous state is popped from the stack
- And are loaded back into the registers
An operating system uses scheduling. One method of scheduling is first come, first served.
i) Explain why the first come, first served scheduling method may not be efficient. [2]
ii) Describe one other scheduling method [2]
iii) Explain why scheduling is necessary [4] - ANSSome instructions may take less time than the ones at
the front, which may take a while, meaning instructions that can be done in seconds and held up by ones
that take longer
Shortest Remaining Time - the task that takes the least amount of time required to complete the job is
done first
Scheduling allows for processes to be ordered in a way that is beneficial. It ensures efficiency and
fairness between parties using the program. Maximise number of interactive users.
Benefits of virtual machine? - ANSEnergy consumption reduction
More control over network and users
Easy to move file of virtual machine
Compare and contrast the functions of operating systems designed for a personal computer and a
satellite navigation system in a car [7] - ANSA personal computer is likely to be a multi-task operating
system or a general purpose operating system, whereas a satellite navigation system in a car is likely to
be an embedded system.
A multi-task operating system allows multiple tasks to be seemingly carried out at once, but the operating
system just rapidly switches between the tasks. In contrast, an embedded system is built for limited,
specific functions, based on what is required.
pf3
pf4
pf5
pf8
pf9
pfa

Partial preview of the text

Download Computer Systems and Data Management: Memory, Processor Scheduling, and Database Systems and more Lecture notes Software Development in PDF only on Docsity!

10cs52(vtuplanet.com), Lecture

notes of System Programming

A distributed OS provides better _______ by...? - ANSProvides better service:

  • Faster processing
  • If one section fails, others can potentially continue operating
  • Reduction in delays A software development company is building an operating system for a mobile phone that is in the process of being designed. One of the developers is responsible for writing the code for what happens when the CPU receives an interrupt. Outline what the code must do. [6] - ANS- Complete the current FDE Cycle
  • Check the priority of the incoming interrupt.
  • If it's of a higher priority than the current task, contents of PC/memory stored in memory in a stack
  • The relevant interrupt service routine is loaded by loading the relevant value into the program counter.
  • When the interrupt service routine is complete the previous state is popped from the stack
  • And are loaded back into the registers An operating system uses scheduling. One method of scheduling is first come, first served. i) Explain why the first come, first served scheduling method may not be efficient. [2] ii) Describe one other scheduling method [2] iii) Explain why scheduling is necessary [4] - ANSSome instructions may take less time than the ones at the front, which may take a while, meaning instructions that can be done in seconds and held up by ones that take longer Shortest Remaining Time - the task that takes the least amount of time required to complete the job is done first Scheduling allows for processes to be ordered in a way that is beneficial. It ensures efficiency and fairness between parties using the program. Maximise number of interactive users. Benefits of virtual machine? - ANSEnergy consumption reduction More control over network and users Easy to move file of virtual machine Compare and contrast the functions of operating systems designed for a personal computer and a satellite navigation system in a car [7] - ANSA personal computer is likely to be a multi-task operating system or a general purpose operating system, whereas a satellite navigation system in a car is likely to be an embedded system. A multi-task operating system allows multiple tasks to be seemingly carried out at once, but the operating system just rapidly switches between the tasks. In contrast, an embedded system is built for limited, specific functions, based on what is required.

10cs52(vtuplanet.com), Lecture

notes of System Programming

A multi-task operating system is used for many types of personal computers, and it doesn't matter what tasks are being carried out, whereas an embedded system has a function specific to the device it is built into only. An embedded system consumes less power than a multi-task operating system as they are only used for limited functions when needed. E.S. needs to be as fast as possible to give accurate readings for real time traffic updates (e.g. closed road). Both operating systems maximise the experience for the user. Both allow inputs from users. However, the way these are input at different. PC = mouse, keyboard, etc. Sat nav = touchscreen, voice. Both give outputs to users. Both give visual outputs on the screen. Both use sound outputs. Describe a multi-tasking OS. - ANS- As used on your PC, Mac or Laptop

  • Manages many tasks simultaneously, e.g. PowerPoint, Chrome, iTunes, File Management etc.
  • Operating System switches between tasks rapidly, thanks to processor speed
  • Came about at the time of single core processors to allow several tasks to be carried out seemingly at the same time Describe a real time OS - ANSCarry out processes within a guaranteed amount of time (usually a fraction of a second) E.g. Flight control systems; Life support systems
  • Must respond quickly to any inputs or sensors
  • Must be able to deal with many inputs simultaneously
  • Must have mechanism to detect and respond to hardware faults Describe an embedded OS. - ANSMuch smaller Operating Systems, found within devices such as washing machines, cameras, POS (Point of Sale) machines, smart meters etc.
  • Specific to the device
  • Stored in ROM (program does not change)
  • Minimal user interface (buttons, dials, small screen)
  • Limited amount of RAM
  • Few if any data storage devices Describe multi-user OS. - ANSSupports more than one user... ...at the same time E.g. Unix

10cs52(vtuplanet.com), Lecture

notes of System Programming

Memory management in a computer for main memory can use either paging or segmentation. i. Explain what is meant by 'paging' [2] ii. Explain what is meant by 'segmentation' [2] iii. State two similarities between paging and segmentation [2] - ANSPaging is where data is broken up into equal blocks (pages), in order to make use of all of the storage available. Then, the pieces of data are put together in order to fully fill the memory available. Uses physical divisions. Segmentation is where the data is separated logically into chunks of unequal size to keep certain code together called segments (such as loops, where, if separated, would be inefficient). The data is then put together in a logical order to get the most out of the memory available.

  • Both split up files into chunks
  • Both try to use the most out of RAM
  • Both ways of partitioning / splitting up memory
  • Use virtual memory / backing store to swap parts of programs
  • Allow programs larger than memory to run / insufficient memory
  • Allows programs to be stored in memory non-contiguously Types of Processor Scheduling: - ANS- First Come First Served E.g. queue in a shop
  • Shortest Job First Processor chooses the shorter jobs before the longer ones. (Needs to know the length of each job first)
  • Round Robin Each process allocated a time slice (quantum) Fair, but not always efficient
  • Shortest Remaining Time Similar to shortest job first, but longer processes can be interrupted by shorter ones
  • Multi-level Feedback Queues All the above assume a single 'queue' of processes to be carried out. Multi-level Feedback Queues is an algorithm which uses more than one queue and moves jobs between them to prioritise more efficiently What are device drivers? - ANSDevice Drivers are pieces of software which enable the OS to communicate with the hardware device and vice versa With hundreds of different hardware devices from different manufacturers, it's impossible for an Operating System to know how to interact with them all - especially new devices What are hypervisors? - ANSHypervisors are software which enables virtualisation What are the different types of operating system? - ANS- Distributed OS
  • Embedded OS
  • Multi-tasking OS
  • Multi-User OS

10cs52(vtuplanet.com), Lecture

notes of System Programming

  • Real-Time OS
  • BIOS What are virtual machines? - ANSAny instance where software is used to take on the function of a machine, including executing intermediate code or running an operating system within another. What does WIMP stand for? - ANSwindows icon menus pointer What is a BIOS? - ANSBasic Input Output System Function - to detect, initialise and test system hardware, then load the OS into RAM Stored in EPROM (Erasable Programmable Read-Only Memory) What is a distributed operating system? - ANSGroups of computers working together on a single task, coordinated by the operating system Appears to the user that it's a single system being used (referred to as 'transparency') Form of parallel processing What is an Operating System? - ANSProgram or collection of programs that manage the operations of the computer for the user. Enables user to communicate with hardware What is paging? - ANS- Memory is divided into a number of equal size 'frames'.
  • Each process is divided into a number of equal size 'pages' of the same length as frames.
  • A process is loaded by loading all of its pages into available, not necessarily contiguous, frames What is prioritised: interrupts or CPU processes? - ANSAll interrupts have priority over CPU processes, but some interrupts have priorities over others, so not always as simple as taking them in the order they arrive. What is segmentation? - ANS- Similar to paging, but segments not necessarily the same size
  • Segments are logical divisions, rather than physical divisions
  • Segments are complete sections of programs Business Intelligence (BI) - ANStransform raw data into useful information

10cs52(vtuplanet.com), Lecture

notes of System Programming

relationship database - ANSorganized data into multiple tables selecting - ANSeliminating and picking rows single user - ANSone person can use it at a time SQL - From - ANSspecify table SQL - Select - ANSSpecify attribute SQL - Where - ANSSpecify the condition Structured query language (SQL) - ANSstandard language for relational databases Traditional approach - ANSdata files dedicated to each system Attribute - ANScharacteristic of an entity Business Intelligence (BI) - ANStransform raw data into useful information concurrency control - ANStwo or more people attempting to access the same record at the same time data center - ANSdata servers in a building that is climate controlled Data Hierarchy - ANSData in a database organized into sequential levels data item - ANSspecific value of an attribute data mart - ANSsubset of warehouse for a single asset like finance data mining - ANSDiscover patterns and relationships data model - ANSdiagram of data and there relationship data redundancy - ANSdata is copies and separated in several locations data warehouse - ANSstores historical data - like transactions database approach - ANSdata shared with multiple application Database as a service (DaaS) - ANSaccessed by client through network like cloud computing Database Management Systems (DBMS) - ANSinterface between the database and the user DBMS - ANSUsed to create one or more tables Entity Class - ANSRepresenting a row and a generalized class of people, pace or thing Entity-relationship diagram - ANSgraphical symbols to show data

10cs52(vtuplanet.com), Lecture

notes of System Programming

Field (column) - ANSstores a different element of data flat file - ANSrecords with no relationships to others joining - ANScombines two or more tables linking - ANScombines two or more tables that share at least one common data Logical design - ANSabstract model of data that needs to be structured OLAB - ANSSoftware that can explore data in multiple perspectives Physical design - ANSlogical database with cost considerations Primary key - ANSField or set of fields that uniquely identifies the record projecting - ANSeliminates columns Record (row) - ANSData for one item, person or transaction relational database model - ANSdescribes data using a standard tabular format relationship database - ANSorganized data into multiple tables selecting - ANSeliminating and picking rows single user - ANSone person can use it at a time SQL - From - ANSspecify table SQL - Select - ANSSpecify attribute SQL - Where - ANSSpecify the condition Structured query language (SQL) - ANSstandard language for relational databases Traditional approach - ANSdata files dedicated to each system Attribute - ANScharacteristic of an entity Business Intelligence (BI) - ANStransform raw data into useful information concurrency control - ANStwo or more people attempting to access the same record at the same time data center - ANSdata servers in a building that is climate controlled Data Hierarchy - ANSData in a database organized into sequential levels data item - ANSspecific value of an attribute data mart - ANSsubset of warehouse for a single asset like finance

10cs52(vtuplanet.com), Lecture

notes of System Programming

SQL - Select - ANSSpecify attribute SQL - Where - ANSSpecify the condition Structured query language (SQL) - ANSstandard language for relational databases Traditional approach - ANSdata files dedicated to each system Attribute - ANScharacteristic of an entity Business Intelligence (BI) - ANStransform raw data into useful information concurrency control - ANStwo or more people attempting to access the same record at the same time data center - ANSdata servers in a building that is climate controlled Data Hierarchy - ANSData in a database organized into sequential levels data item - ANSspecific value of an attribute data mart - ANSsubset of warehouse for a single asset like finance data mining - ANSDiscover patterns and relationships data model - ANSdiagram of data and there relationship data redundancy - ANSdata is copies and separated in several locations data warehouse - ANSstores historical data - like transactions database approach - ANSdata shared with multiple application Database as a service (DaaS) - ANSaccessed by client through network like cloud computing Database Management Systems (DBMS) - ANSinterface between the database and the user DBMS - ANSUsed to create one or more tables Entity Class - ANSRepresenting a row and a generalized class of people, pace or thing Entity-relationship diagram - ANSgraphical symbols to show data Field (column) - ANSstores a different element of data flat file - ANSrecords with no relationships to others joining - ANScombines two or more tables linking - ANScombines two or more tables that share at least one common data Logical design - ANSabstract model of data that needs to be structured

10cs52(vtuplanet.com), Lecture

notes of System Programming

OLAB - ANSSoftware that can explore data in multiple perspectives Physical design - ANSlogical database with cost considerations Primary key - ANSField or set of fields that uniquely identifies the record projecting - ANSeliminates columns Record (row) - ANSData for one item, person or transaction relational database model - ANSdescribes data using a standard tabular format relationship database - ANSorganized data into multiple tables selecting - ANSeliminating and picking rows single user - ANSone person can use it at a time SQL - From - ANSspecify table SQL - Select - ANSSpecify attribute SQL - Where - ANSSpecify the condition Structured query language (SQL) - ANSstandard language for relational databases Traditional approach - ANSdata files dedicated to each system