Welcome to the first (and only) course where you'll learn the truth about computers.

Syllabus »

Note on the Final Exam.

Time: Friday, 15 May, 1:30pm to 4:00pm.

We will Zoom at 1:30pm and you will be able to download the exam from Sakai at that time.  I'll explain the exam and will be available over Zoom during the exam to answer questions.    You can write your answers in the exam itself (it will be a word document) you can write your answers on a paper and take a picture.  You will upload your answers to Sakai.  Sakai will close at 4:00pm.

Note about classes during the second half of spring 2020

As you're well aware, Ithaca College will be moving all classes online for the remainder of the semester. The second half of the semester will begin on 23 March 2020. I will be recording lectures and making them available via Sakai (or maybe media.ithaca.edu) and we will be meeting during the normal class and lab times to review lectures, answer questions, and perform (required) in-class exercises. An overview of the schedule is available at Schedule. You'll receive an email from me soon detailing the format for the class along with a survey. The survey just asks some questions about your current situation. You can take the survey here: survey

Note on the online textbook

You can access a single-page version of the online textbook at: one-page textbook You can download this page as html (it's about 23MB) and then use it off-line.

Take the Book survey and earn extra credit on the exam!

My office hours: 3:00PM Monday and Wednesday, 1:00pm on Tuesday and 11:00am on Friday or by appointment.

TA hours: 5:30pm to 7:30pm on Wednesdays and 5:30pm to 8:00pm on Sundays in Williams 303. The TA is Milo Rue.

Class Server URL: comp210.eastus.cloudapp.azure.com

Exam dates:

  1. Exam 1: XX March
  2. Final: Friday, 15 May, 1:30PM (scheduled final period)

Notes

  • We will be using a free online textbook for this course. You can access it here. The account name is ithaca and I will provide the password in class.
  • We will be using Top Hat in this course. You must register for this class using join code 152764
  • Take the Book survey and earn extra credit on the exam!


Announcements

  • Important!! The on-line textbook has been updated. The account name and password are the same. The updates affect the assembly language chapter which we have not yet begun, but you should use the new version of the textbook at https://diveintosystems.cs.swarthmore.edu/development/x86_64/antora/diveintosystems/beta/x86_64/index.html
  • Tired of nano? Microsoft Visual Studio Code, an open source text editor for linux, is now available for Linux!
  • Obfuscated C Contest really exists. See https://www.ioccc.org Click on the "source code" link at the top of the page and then click on the "prog.c" file for some of the winners. Note that all these programs compile and run!
  • Optimization in gcc: Most optimizations are completely disabled at -O0 or if an -O level is not set on the command line, even if individual optimization flags are specified. Similarly, -Og suppresses many optimization passes. See https://gcc.gnu.org/onlinedocs/gcc/Optimize-Options.html
  • Note about the Practicum 2 writeup. For phase 4 I want the pseudo-code for the recursive function, not for phase 4.
  • Practicum 2: what is "%fs:0x28"? This is a reference to the way that the intel machine language adresses memory, something that we have not (and will not) talk about in class. If you're interested, see this article: X86 memory organization. You can safely ignore this instruction when you see it, but the larger lesson is that you have to deal with some uncertainty when working with the bomb. You won't know everything, but you have to use what you do know to figure out what is happening.
  • Lab 7: why is the instruction "sar 0x3f, %rdx" there?
  • Integer division always rounds it’s result by rounding towards 0. So if we do 5 the result is 2.5 which is rounded to 2. This is the same result that we get if we shift 0101 to the right one position, i.e., 0010. If we do −5, however, the 3 result is −2.5 which should round toward 0, i.e., to −2. The 2’s complement version of −5 however is 1011. If we shift it right we get 1101 or −3 not −2. To fix this, we can add one before we shift, i.e., −5 + 1 = −4 or 1100. When we shift this right we get 1110 or −2, the correct answer. How can we do this without an if statement to test whether the number is positive or negative? If a 2’s complement number is positive, the sign bit is 0. If the 2’s complement number is negative it’s sign bit is 1. So we shift the sign bit all the way to bit position 0 (63 bits if we have a 64 bit number). If the number is negative, it results in the value ”1”; if the number if positive it results in the value ”0”. We then add this to the number that we are to divide, i.e., we add ”1” to a negative number and ”0” to a positive number. Then when we shift right, the number will be rounded in the correct way.

  • Problem set 3: it's ok to use the time.h library to convert seconds into a date formate. Check out the strftime function in particular.

Coming up...

Lab 11 is due on Thursday, 30 April

Practicum 2 is due on Wednesday, 13 May at midnight.

Final Exam is on Friday, 15 May from 1:30pm to 4:00pm. You will get the exam from Sakai and will upload your complete document or images of your completed exam to Sakai.

Past Assignments »

Lab 10 will be done using Zoom during the normal class period on Thursday, 23 April and is due on Thursday, 30 April I'll send out a Zoom invitation shortly before class.

Lab 9 will be done using Zoom during the normal class period on Thursday, 16 April and is due on Thursday, 23 April I'll send out a Zoom invitation shortly before class.

Lab 8 will be done using Zoom during the normal class period on Thursday, 9 April and is due on Thursday, 16 April I'll send out a Zoom invitation shortly before class.

Lab 7 will be done using Zoom during the normal class period on Thursday, 2 April and is due on Thursday, 9 April I'll send out a Zoom invitation shortly before class.

Lab 6 will be done using Zoom during the normal class period on Thursday, 26 March and is due on Thursday, 2 April

Practicum 1 is due on Monday, 23 March Monday, 30 March

Exam 1 is in class on Thursday, 5 March

Lab 5 is due on Friday, 6 March

Problem Set 3 is due on Monday, 24 February.

Problem Set 2 is due on Monday, 17 Feb

    Lab 3 is due on Thursday, 27 Feb

    Lab 3 is due on Thursday, 20 Feb

    Lab 2 is due on Friday, 14 Feb

  • Quiz 1 on Monday, 27 Jan on Unix commands. The quiz will cover the material from tutorials 1, 2 and 5 from the UNIX tutorial.
  • Problem Set 1 is on Friday, 31 Janurary, Friday, 7 Feb, at midnight.
  • We will do Lab 1 on Thursday, 30 Janurary and is due on Monday, 3 Feb.

Comp 210 in the news

Fun

  • Interested in what happened to the engineers from Soul of a New Machine? Check out this article from Wired magazine in 2001. And this page has a photo of the development group in 1980.
  • vi or emacs? See this article.
  • Describe computer science in 5 words: BI
  • Bits in real life. Ariane 5, 1996. See here