CSEP551 -- Programming Assignment #1

Out: Thursday January 24th, 2008
Due: Thursday February 14th, 2008, before class

In this assignment, you will investigate the impact of system call overhead on application performance. Your ultimate goal is to produce a set of graphs that looks something like the following:


This graph shows some application-level benchmark performance as a function of system call latency. To generate this graph, you will modify the linux kernel so that you can add a specifiable amount of overhead to every system call. By varying this overhead, you can measure benchmark performance as a function of this overhead to generate the curve.

Here are the steps you should follow:

  1. Set up an environment in which you can install linux and compile linux kernels. I strongly recommend using VMware for this. (It is true that VMware will affect your benchmark performance, but let's ignore that for this assignment.) You'll need to:

  2. Download and install the linux kernel source code. You can get source code for different kernel versions from www.kernel.org.

  3. Practice compiling and installing a new kernel based on the kernel source code you downloaded. If you've never compiled/installed a kernel, you can find plenty of help on the Web, for example, from here.

  4. Modify the linux kernel so that you can add overhead to every system call that occurs. To do this, you'll need to:

  5. Make it possible for user-level programs to change the amount of system call overhead introduced by your code. I suggest that you add something to the /proc virtual file system to do this -- i.e., by writing a number to a file you create in proc, your code will vary the amount of loop overhead according to that number. There are plenty of web pages that will help you learn how to add something to the /proc filesystem; see, for example, here.

  6. Calibrate your system call overhead by measuring the latency of a simple system call (e.g., close(100)) as a function of your variable overhead.

  7. Measure the performance of the following three benchmarks as a function of system call overhead:

    Be careful of caching effects when running your benchmarks, in particular, of the file system buffer cache!

What to turn in

You should submit your assignment using the following "dropbox" URL:
https://catalysttools.washington.edu/collectit/dropbox/sangt/1736
Your submission should be a single .tar.gz or .zip file, containing the following elements: