Cmput 379 Lab Homepage
These web pages were developed by Justing Gamble
(MSc., 2001) for use in the 1999/2000 academic year (while he was a Teaching
Assistant for CMPUT 379). They are reproduced here with the kind permission
of Justin Gamble, but have been edited for use in the Winter 2001 Term
[Tony Marsland, Professor, February 2001]
Announcements / Links:
-
The official c379 course
outline and home page
-
Some of Steven's examples require
an "ourhdr.h" file. A custom version of this file is stored in this tar
file. See the README for help.
-
gcc vs g++
Lab 11: Using gdb under emacs
Lab 10: Record Locking and getloadavg()
Lab 9: Using the gdb debugger
Lab 8: Intro to csh scripting
Lab 7: Intro to select()
Lab 6: Intro to sockets
Lab 5: Intro to signals, signal(), sigaction(), alarm()
Lab 4: Buffering, makefiles, argc, argv, getopt()
-
Lecture Notes
-
Examples
-
Further Reading
Lab 3: wait() and waitpid()
-
Presentation Material
-
Homework
-
Lab
Exercise #3 .
-
Lab #2 should be demonstrated by the end of Friday's lab
-
Lab #3 can either be demonstrated in the lab, or it can be emailed to me
by Saturday midnight.
-
Recommended Reading:
-
Stevens 8.6 (pages 197 - 201)
Lab 2: dup2() and exec()
-
Presentation Material
-
Homework
-
Lab
Exercise #2 .
-
The review is slightly different from last week - now each input line causes
the parent to spawn a new child.
-
The grading for this can be found here
-
Recommended Reading:
-
Stevens 3.12 (pages 61 - 63)
-
Stevens 8.9 (pages 207 - 212)
Lab 1: fork() and pipe()
-
Presentation Material
-
Example of fork(), getpid(), and getppid()
-
Program 8.1 (p.190) fork() example: The parent
and child have private copies of all variables, which is why the output
of the parent and child varies
-
Program 14.1 (p.431) pipe() example: Sends
data from the parent to the child over a pipe
-
Homework
-
Lab
Exercise #1
-
Recommended Reading:
-
Stevens 8.1 - 8.3 (pages 187-193)
-
Stevens 14.1 - 14.2 (pages 427-431). Pager example optional
-
Browse Stevens chap 5, or read through my summary
-
Feedback