Course Computer Systems for AI-programmers

"Computersystemen voor AI-programmeurs"

Week 10, March 9, 2010

Description

In this class, the rest of part II of the book will be covered. Part II describes how programs are run on a system. This will give you an understanding of the interactions of your program with the operating system.

We learn how new processes are started, as children of a parent process(typically the shell), and how the parent can control its children by signals.

Virtual memory is an abstraction of main memory, which allows every process to have its 'own' memory. The virtual memory provides three important capabilities. First, it provides as cache to the slow access to pages on the harddisk. Secondly, it provides an efficient way to share memory between processes, as for instance parent and children-processes. Thirdly, it provides a simple way to protection of the memory against wrong usage.

In this class the following concepts are introduced:

  • exceptions, interrupts, traps, faults, aborts, exception handling
  • processes, user and kernel mode, context switches, system calls
  • process creation & termination, reaping, suspension

  • virtual address space, physical address space
  • page table, virtual pages, physical pages, page faults
  • virtual memory areas, user areas, private areas, shared areas

Literature

The class is based on chapters 8 and 10 of the book Computer Systems: A programmer's perspective by R.E. Bryant and D.R. O'Hallaron.

Recommanded reading:

8   Exceptional Control Flow, 8.1 - 8.5.1
10.1 Physical and Virtual Addressing
10.2 Address Spaces
10.3 Virtual Memory as Tool for Caching
10.4 Virtual Memory as Tool for Memory Management
10.5 Virtual Memory as Tool for Memory Protection
10.7.2Linux Virtual Memory System
10.8 Memory Mapping (until 10.8.4)


Schedule

The class is scheduled in three hours:

  1. Lecture(Recording): 'Computer systems - Processes'
    Problem 8.2: How many 'hello' output lines does forkprob1.c print?
  2. Lecture (sorry, no recording): 'Computer systems - the advantages of Virtual Memory'
  3. Exercise: 'Optimize the procedure 'rotate'
    Previous year Description, code.

Last updated March 9, 2010

o This web-page and the list of participants to this course is maintained by Arnoud Visser (arnoud@science.uva.nl)
Faculty of Science
University of Amsterdam

visitors in arnoud@science.uva.nl