Aims

Systems research refers to the study of a broad range of behaviours
arising from complex system design, including: low-level operating systems;
resource sharing and scheduling; interactions between hardware and software;
network-protocol design and implementation; separation of mutually distrusting
parties on a common platform; and control of distributed-system behaviours
such as concurrency and data replication. This module will:

expose students to real-world systems artefacts such as OS schedulers and
network stacks, and consider their hardware-software interactions with
CPUs and network-interface cards;

develop scientific writing skills through a series of laboratory reports;
and

assign a selection of original research papers in these areas in order to
gain insight into potential research topics and approaches.

The teaching style will blend lectures and hands-on labs that teach
methodology, design principles, and practical skills. Students will be
taught about (and assessed via) a series of lab-report-style assignments based
on in- and out-of-classroom practical work. The systems studied are real, and
all wires will be live.

Prerequisites

It is strongly recommended that students:

Have previously (and successfully) completed an undergraduate
operating-system course with practical content -- or have equivalent
experience through project or open-source work.

Have reasonable comfort with the C and Python programming languages. C is
the primary implementation language for systems that we will analyse,
requiring reading fluency; userspace C programs will also be written and
extended as part of lab exercises.
Students without a Python background will wish to complete an online Python
tutorial prior to term, as the language will be used in data collection,
analysis, and presentation from the first lab.

Review an undergraduate operating-system textbook (such as the 'Dinosaur
Book') and the first four chapters of 'The Design and Implementation of the
FreeBSD Operating System' prior to term. Students will also benefit from
skimming the DTrace book prior to the start of the first lab.

Be comfortable with the UNIX command-line environment including compiler/
debugging tools. Students without this background may wish to sit in on
the undergraduate UNIX Tools lecture series in Michaelmas Term.

Syllabus

Please note: at the time of writing, this module is under active
development.
Some change is expected between the material and labs described here. Note that the
module is to be taught at the end of Lent Term and the beginning of Easter Term 2015.
Overall, however, the module content and approach will be as described here.

The sessions are split up into three submodules:

Lent Weeks 6-7: Introduction to kernels and kernel tracing/analysis

The purpose of this submodule is to introduce students to the structure of
a contemporary operating system kernel through tracing and profiling.
Students will gain familiarity with practical systems tools such as DTrace
and hardware performance counters, as well as with data interpretation,
analysis, and presentation using Python and GraphViz. They will write a
first lab report which will receive feedback from the instructor, but not
count towards the final mark.

This submodule will introduce students to aspects of the UNIX process model
(processes and threads in userspace and kernel), as well as the impact of
scheduling and affinity. It will also consider local hardware-software
interactions such as interrupt delivery and cache behaviour. The first
marked lab report will be written.

This submodule will introduce students to a contemporary, multithreaded,
multiprocessing network stack, with a particular interest in the TCP
protocol. Labs will consider both the behaviour of a single TCP connection,
and its interactions with other TCP connections through congestion control.
Students will also look at how hardware behaviour such as caching and
multiqueue work distribution affect performance. The second marked lab
report will be written.

Objectives

Gained insight into hardware-software interactions for compute and I/O

Have practical skills in system tracing and performance analysis

Have been exposed to research ideas in system structure and behaviour

Have learned how to write systems-style performance evaluations

Coursework

Students will write and submit three lab reports to be marked by the
instructor. The first lab report is a 'practice run' intended to help
students develop and analysis techniques and writing styles, and will not be
included in the final mark for the module. The remaining reports are marked
and assessed, each constituting 50% of the final mark.

Practical work

Five in-classroom labs will ask students to develop and use skills in tracing
and performance analysis as applied to real-world systems artefacts. Results
from these labs (and follow-up work by students outside of the classroom) will
by the primary input to lab reports. Typical labs will involve using tracing
and profiling to characterise specific behaviours (e.g., TCP congestion
control) as well as diagnose and fix problems through modifications to
application-level behaviours (e.g., modifying network clients and servers to
better exploit real-world TCP behaviour). Students may wish to work in pairs
within the lab, but must prepare lab reports independently.

The module lecturer will give a short introductory lecture at the start of
each lab, and instructors will be on-hand throughout labs to provide
assistance. Lab participation is not directly included in the final mark, but
as lab work is a key input to lab reports that are assessed.

Assessment

Each student will write three lab reports, roughly 5-10 pages each including
several figures. The first is a 'practice run' that will be used to develop
lab-report structure, content, and presentation, and will not contribute to
the final mark. The remaining two lab reports will each contribute 50% to the
final mark.

Recommended reading

All module texts should be in the department library; if there appear to be
too few copies to go around, please let the module convener and librarian
know so that additional copies can be ordered.
Texts should also be available via Amazon, iBooks, etc.