CITS2002 Systems Programming  
 

Unit home

Project 1

help2002

Lecture & Workshop
recordings on LMS

Schedule

FAQ

Unit outline

C textbooks

OS textbooks

Information resources


Extra reading

Past projects

Recent feedback


Working effectively

Look after yourself!

Schedule of topics in 2024

The materials presented here do not define the whole unit. Reviewing lecture material comprises about of the effort required for this unit. The remainder of your time should be spent reading the recommended reading, participating in workshops, and undertaking the laboratory tasks and projects.

LCS recordings are not a substitute for the face-to-face sessions. Be aware that the recording system can fail. There is no guarantee that the video or the audio will be recorded and available in LCS.

All source code provided in lectures, laboratories, and workshops is released under the Creative Commons CC BY-NC-SA 4.0 license. CITS2002 students may use the materials in assessed work without attribution.

Please note the order of topics and lectures may change throughout the semester. Please refer to this webpage, rather than a printed copy, for up-to-date information.

Most lectures are supported by further reading, using the following keys:

Week Lectures (each Monday and Wednesday) and Workshops (Fridays) Laboratories and Projects
Week 1
Mon 22nd July
Lecture 1 (single page)
Administrivia; The C programming language; Why C?; A brief history of C; Standardization.

Lecture 2 (single page)
The structure of a C program; Basic datatypes; Variables, naming, and scope.
Flow-control in C programs; Conditional tests, Boolean values, and conditional execution; Bounded and unbounded loops, and their equivalence.
Reading: BGC: Ch.2, Ch.3

Workshop-1 - getting started with practical work (recorded, but no slides).

No laboratories this week.

OS and C compiler software

unix and C compiler basics

Frequently used commands

Week 2
Mon 29th July
Lecture 3 (single page)
An introduction to operating systems; A brief history of operating systems; The contemporary role of operating systems.
Reading: DIS: Ch.13 intro; TEP: Ch.2 intro, §2.6; The Evolution of Operating Systems, Per Brinch Hansen, Nov 2001.

Lecture 4 (single page)
Functions in C; Passing parameters to functions; Returning values from functions; the static keyword; Functions receiving a variable number of parameters.
Reading: BGC: Ch.4

Workshop 2: Conditions, Loops, Basic Formatting, and Standard Library Functions
the MP4 recording from 2023 (145MB),
and the solution we developed in 2024.

Labsheet 1
and some sample solutions.
Week 3
Mon 5th Aug
Lecture 5 (single page)
Aggregate data structures in C - arrays and strings; Initializing arrays and strings; Formatting results into character arrays; Defining and accessing structures; Better representations of our data - enumerated types.
Reading: BGC: Ch.6, Ch.7, Ch.8

Lecture 6 (single page)
An overview of computer hardware components; The processor and its registers; The memory hierarchy; Code execution.
Reading: DIS: §5.2, §5.6, §11.1

Workshop 3: Functions, parameter passing, and structures
and the solution we developed.

Labsheet 2
and some sample solutions.
Week 4
Mon 12th Aug
Lecture 7 (single page)
File input and output (I/O); File descriptors; File copying; Reading and writing text files; File pointers and standard I/O; Reading and writing structures and binary data.
Reading: BGC: Ch.9

Lecture 8 (single page)
Operating system processes; The state of an operating system process; Timer interrupts; The scheduling of processes; Process suspension and swapping.
Reading: DIS: §13.2, TEP: Ch.4

Workshop 4: File I/O and measuring execution time
and the solution we developed.

Labsheet 3
and some sample solutions.
Week 5
Mon 19th Aug
Lecture 9 (single page)
Creating new processes; Parent and child processes; Waiting for process termination; Overlaying a new process image; The importance of the exit status.
Reading: DIS: §13.2, TEP: Ch.5

Lecture 10
(get up-to-date with all past lecture material...)
Mid-semester test discussion; come prepared with your questions.


Friday 23rd Aug - Mid-semester test

1st programming project
Week 6
Mon 26th Aug
Lecture 11 (single page)
Addresses and pointers in C; The relationship between pointers and arrays; Pointer arithmetic;
Reading: DIS: §2.1, §2.2; BGC: Ch.5, Ch.11


Lecture 12 (single page) Passing pointers to functions. Dynamic memory allocation; Allocating memory for arrays and strings; Reallocating and deallocating memory.
Reading: DIS: §2.4; BGC: Ch.12 TEP: Ch.14

Workshop-5 - 1st Project discussion; come prepared with your questions.

Non-teaching week
Mon 2nd Sept
Non-teaching week (no lectures, workshop, or scheduled laboratories)
Week 7
Mon 9th Sept
Lecture 13
An introduction to memory management; Allocating physical memory to processes; Fixed and dynamic partitioning schemes; Simple memory paging.
Reading: DIS: §11.1-11.2; TEP: §18.1-18.3

Lecture 14
The principle of referential locality; Memory paging in more detail; Virtual memory.
Reading: DIS: §11.3; DIS: §13.3;

Friday - no workshop this week

Week 8
Mon 16th Sept
Lecture 15
File-system basics; The file management system; Directory structures; File allocation methods.
Reading: TEP: §40.1-40.6

Lecture 16
System-calls and system-defined structures; Accessing structures using pointers; Defining our own datatypes; Finding the attributes of a file; Reading the contents of a directory; File and Directory Permissions.
Reading: BGC: Ch.10; DIS: §17.7; TEP: Ch.39

Workshop-6: Creating and managing processes using system-calls

Labsheet 4
Week 9
Mon 23rd Sept
Monday 23rd September - public and UWA holiday, no lecture or laboratory sessions

Lecture 17
Developing C programs in multiple files; Linking; Simplifying program development with make;
Reading: BGC: Ch.17; DIS: §17.5

Workshop-7: Using structures and reading directories

Labsheet 5
Week 10
Mon 30th Sept
Lecture 18
Supporting command-line options with getopt. Interprocess-communication using pipes.

Lecture 19
Self-referential data structures; stacks; linked lists; queues; binary trees.

Workshop-8 - 2nd Project discussion; come prepared with your questions.

2nd programming project
Week 11
Mon 7th Oct
Lecture 20
Multi-threaded programming; Thread support in standard-C; Benefits of threads; Threads versus processes; Thread creation, execution, and termination;
Reading: DIS: §14.2; BGC: Ch.39.1-39.5.

Lecture 21
Waiting for threads; Synchronization using mutexes; Condition variables; When are threads faster, and when slower?
Reading: DIS: §14.3; BGC: Ch.39.7-39.8.

Workshop-9: Building a hashtable data structure

Week 12
Mon 14th Oct
Lecture 22
Portable systems programs; Using the preprocessor to isolate system-specific code; Preprocessor tokens for C language standards and operating system platforms; System-specific integer datatypes; Unicode support in C11.
Reading: BGC: Ch.19; Ch.27.

Lecture 23
Discussion on questions from last year's final examination
(recorded, but no slides).

Friday - no workshop this week

The University of Western Australia

Computer Science and Software Engineering

CRICOS Code: 00126G
Presented by [email protected]