Resources

If you added late, check this page to get caught up.

An introduction to system programming is Angrave’s CS 241 Crowd-Sourced Wikibook. We also have the second iteration the Coursebook That provides html, pdf, and wiki versions. Angrave’s mini searchable video-introduction and playful system programming-in-the-browser environment is at: mini lectures (Firefox and Chrome recommended).

No formal textbook is required, but if you really want to buy a physical book, we recommend the following custom book Angrave put together in 2007:

Introduction to Systems Concepts and Systems Programming
University of Illinois Custom Edition
Copyright 2007 by Pearson Custom Publishing
ISBN 0-536-48928-9

How to Succeed #

Is this course hard? Yes, but you are bright. You’re taking computer science at UIUC. Schedule the time to do it. The two big changes from CS 225:

  1. Your code is now much smaller than the complexity of the system around it.
  2. No, we will not debug your code for you.

With lecture content, one lab, one MP, and one Quiz/Midterm every week or two, it can get easy to fall behind.

How to fail: some students do not take the time to learn how to debug and reason about system code and then end up complaining that office hours is too busy before deadlines. If you can’t write correct solutions, you need to learn exactly how C works, the details of the system calls you are using, learn better debugging skills and reason behind synchronization. Only then can you spot and fix mistakes. Hard? Yes. Impossible? No.

There are no shortcuts to mastery, but we can help you get there. We recommend the Feynman technique to learning. Remember, simply recognizing some text in a past exam or in the coursebook is not mastery of those concepts! Find ways to deeply engage your brain with the ideas by working actively with those ideas. Yes, this requires effort. Start the assignments early; expect to get stuck. Write code slowly; reason about every line of code you write. Experiment with your own mind hacks so that you have fun spending “time on task” with these materials.

Piazza: Search First. Don’t Post. #

Low-Effort Questions

We will not accept “low effort questions”:

  • “My code doesn’t work, can someone look at my github?”
  • Questions that are already answered in a pinned post
  • Questions that are already answered in the docs
  • Questions that have already been answered many times before and can easily be found by searching
  • Questions that provide basically no information to go off of (Debugging? Tests? Valgrind? Anything?)

If we find you asking too many of these low-effort questions, then we reserve the right to remove your Piazza privileges. Hopefully these steps will lead you to the answer you’re looking for, or at the very least help you find the answer yourself. Asking on Piazza should not be the first thing you do when you have a problem. You’re here to learn; we’re not going to give you the answer every time you ask.

Debugging

Have you run it in Valgrind? Are you testing simpler cases that might show where the problem is? How about adding print statements or using breakpoints in gdb to figure out if you’re actually getting to the code you think is running? Are you using the VM we provide to test the code? If you’re getting erratic behavior, make sure you’ve fixed everything Valgrind complains about, as what you do wrong in one place can affect a completely unrelated piece of code. If you ask a question, make sure that you’ve made some effort to find the problem. Be prepared to provide some Valgrind log.

Documentation

A lot of questions can be answered simply by looking at the MP spec, pinned errata posts, or looking through a man page. Don’t know where your specific question is answered? Use Ctrl+F with some keywords to search the page. Don’t know how to use a function? Read the man page. It provides detailed info on how to use a function, and can even list some examples. Also note man page section 7. It’s all explanations of different parts of the C library. There you can find how signal, epoll, and more work in practice.

Google Is Your Friend

Most questions can simply be answered by searching Piazza, or Googling your question. The chances are that someone has had your exact problem, and someone has answered it (especially near a due date when most people have already finished). Even if you don’t find your exact answer, the questions you find can be close enough to what you’re looking for. Here are some tips on Googling: How to be a Google Power User and How to get more out of Google.

I Found Nothing. What Now?

If you are truly lost, can’t find an answer in the docs, or in other questions, or the wide expanse of the internet, ask your question!

  • What’s the problem you’re having? (And give an example)
  • What have you tried? Have you tested your code?
  • What does Valgrind say? How about a gdb backtrace?
  • If you need to show code, don’t take a screenshot. Copy it into a pre tag (“code” on the rich editor bar)

CS 241 Admin #

Jillian is our class admin, and she is in charge of all administrative items (e.g. exam sickness, DRES, 1% issues). If you feel your issue falls under those definitions, then please email her at cs241admin@illinois.edu and explain your scenario.

Note: We do not provide attendance misses for labs (this is not negotiable), especially for something that is 100% in your control like “I have an interview.”

Lawrence Angrave #

Lawrence Angrave can often be found on the second floor of Siebel in or near SC2217. His office hours are on Tuesdays 11:00-12:00. He’s also able to answer quick questions before or after lecture.

Graham Carl Evans #

Graham Carl Evans has also taught this course. His office is on the third floor of Siebel 3209.