Skip to content
Home » Chapter 5: System Software

Chapter 5: System Software

  • by

1. Operating System (OS) Basics

Definition:
Software that manages hardware/resources and provides a user interface.

Key Functions:

  1. Process Management
    • Multitasking (time-slicing, scheduling).
    • Interrupt handling (prioritization, ISRs).
  2. Memory Management
    • RAM allocation, virtual memory, paging.
  3. File Management
    • Directory structures, permissions (read/write/execute).
  4. Security
    • User authentication, encryption, firewalls.

Examples: Windows, Linux, macOS.


2. Utility Software

UtilityPurposePerformance Impact
DefragmentationReorganizes fragmented files on HDDs.Faster file access.
Disk CleanupDeletes temporary/unused files.Frees storage space.
BackupCreates copies of data for recovery.Prevents data loss.
AntivirusScans for malware.Improves system security.

Note: SSDs do not need defragmentation (wear-leveling instead).


3. Language Translators

TranslatorOperationProsCons
CompilerTranslates entire program → executable.Fast execution; standalone file.Slower debugging; no line-by-line.
InterpreterExecutes code line-by-line.Immediate feedback; easier debug.Slow execution; no executable.
AssemblerConverts assembly → machine code.1:1 translation; low-level control.Platform-dependent.

Hybrid Approach (e.g., Java):

  • Compiled to bytecode → interpreted by JVM.

4. Integrated Development Environment (IDE)

Features:

  • Debugging Tools:
    • Breakpoints
    • Single-stepping
    • Variable watchers.
  • Editing Tools:
    • Syntax highlighting
    • Auto-completion (context-sensitive prompts).
  • Dynamic Syntax Checks:
    • Real-time error detection (e.g., missing semicolons).

Why Use an IDE?

  • Streamlines coding
  • Debugging
  • Testing in one interface.

5. Program Libraries & DLLs

Program Libraries

Definition: Collections of pre-written code (functions, classes, or modules) for common tasks.

5 Key Benefits:
  1. Time-Saving
    • Eliminates the need to write code from scratch (e.g., math.h for complex calculations).
  2. Error Reduction
    • Pre-tested code minimizes bugs (e.g., standard libraries like Python’s NumPy).
  3. Modularity
    • Code can be updated independently without rewriting entire programs.
  4. Consistency
    • Ensures uniform implementation of algorithms (e.g., encryption in OpenSSL).
  5. Cross-Platform Support
    • Libraries often work across OSes (e.g., Java’s Swing for GUIs).

Dynamic Link Libraries (DLLs)

Definition: Shared libraries loaded at runtime, not compile time.

5 Key Benefits:
  1. Reduced Executable Size
    • Code is stored separately (e.g., .dll files in Windows) → smaller main program.
  2. Memory Efficiency
    • Multiple programs share the same DLL in RAM (e.g., Windows API DLLs).
  3. Easier Updates
    • Update DLLs without recompiling the main program (e.g., security patches).
  4. Modular Design
    • Plug-in architectures (e.g., Photoshop filters as DLLs).
  5. Faster Development
    • Teams can work on separate DLLs concurrently.

Comparison Table
AspectProgram LibrariesDLLs
UsageLinked at compile time (static).Linked at runtime (dynamic).
MemoryEach program loads its own copy.Shared across programs.
UpdatesRequires recompilation.Independent updates.
Examplesmath.hPython’s pandas.kernel32.dllmsvcrt.dll.

6. Interrupt Handling

Types:

  • Hardware Interrupts: External events (e.g., keyboard press).
  • Software Interrupts: Generated by programs (e.g., division by zero).

Handling Process:

  1. CPU finishes current instruction.
  2. Saves state (registers) to the stack.
  3. Jumps to Interrupt Service Routine (ISR).
  4. Restores state and resumes original task.

Priority Levels:

  • Non-maskable interrupts (NMIs) > Maskable interrupts.

8. Cache Memory & Performance

Why Increase Cache Size?

  • Stores frequently used instructions/data closer to CPU.
  • Reduces cache misses → fewer RAM accesses → faster execution.

Hierarchy:
L1 (fastest, smallest) → L2 → L3 (shared, largest).


9. AI in System Software

Applications:

  • Voice Recognition: Converts speech to commands (e.g., Siri).
  • Predictive Caching: Anticipates data needs (e.g., OS prefetching).

Impact:

  • Improves efficiency but requires significant resources.

Exam-Style Questions

  1. Compare compilers and interpreters (4 marks).
  2. Explain how defragmentation improves HDD performance (3 marks).
  3. Describe the role of the OS in memory management (4 marks).

Key Terms Glossary

  • ISR: Interrupt Service Routine – handles interrupts.
  • DLL: Dynamic Link Library – shared code module.
  • IDE: Integrated Development Environment – coding toolkit.

Leave a Reply

Your email address will not be published. Required fields are marked *