Princeton University
Computer Science Department

Computer Science 217
Introduction to Programming Systems

Szymon Rusinkiewicz

Spring 2019


Directory
General Information | Schedule | Assignments | Announcements | Policies

Overview

Monday Tuesday Wednesday Thursday Friday
10:00AM Lecture (Rusinkiewicz) Lecture (Rusinkiewicz)
11:00AM Office (Rusinkiewicz) Office (Li) Office (Rusinkiewicz) Office (Li) Office (Kyung)
12:30PM Precept (Kyung) Precept (Kyung) Office (Kyung) (at 12:00noon)
1:30PM Precept (Dondero) Precept (Li) Precept (Dondero) Precept (Li)
2:30PM
3:30PM Precept (Dondero) Precept (Heppenstall) Precept (Dondero) Precept (Heppenstall)
4:30PM Office (Dondero) Office (Dondero)
5:30PM Office (Dondero) Office (Dondero)
7:30PM Office (Heppenstall) Precept (Zhang) Office (Heppenstall) Precept (Zhang)
8:30PM Office (Zhang) Office (Zhang)


Week-by-Week

The schedule will change throughout the course. Please check it frequently.


Week 1: 2/4 - 2/10

Reading (required): C Programming (King) 1, 2 ,3

Reading (recommended): Unix Tutorial for Beginners

Reading (recommended): GNU Emacs Tutorial

Reading (recommended): Linux Pocket Guide (Barrett) pp. 166-179 (concerning composing Bash shell scripts) (available through Blackboard in the "Course Materials" section)

Reading (recommended): Wikipedia "Deterministic finite automaton" article

Lecture 1: (Monday) Introduction; C Overview

Precept 1: (Monday/Tuesday) Introduction; The Computing Environment; Program Preparation

Lecture 2: (Wednesday) A Taste of C

Precept 2: (Wednesday/Thursday) Linux and Bash; Emacs

(Sunday 2/10) Introductory Survey Assignment Due (at 10:00PM)


Week 2: 2/11 - 2/17

Reading (required): C Programming (King) 4, 5, 6, 7, 14, 15, 20.1

Reading (recommended): GNU GDB Tutorial

Lecture 3: (Monday) Data Types in C

Precept 3: (Monday/Tuesday) Simple C Programs; C Fundamentals

Lecture 4: (Wednesday) The Design of C (Operators, Statements, I/O)

Precept 4: (Wednesday/Thursday) Multi-File C Programs; GDB

(Sunday 2/17) De-Comment Assignment Due (at 10:00PM)


Week 3: 2/18 - 2/24

Reading (required): Computer Systems (Bryant & O'Hallaron) 1 (available through Blackboard in the "Course Materials" section)

Reading (required): ARM 64-bit Assembly Language (Pyeatt with Ughetta) 1 (available as hard copy through Pequod)

Reading (required): C Programming (King) 8, 9, 11, 12, 13, 24.1

Reading (recommended): Computer Systems (Bryant & O'Hallaron) 2

Reading (recommended): The Practice of Programming (Kernighan & Pike) 6

Lecture 5: (Monday) Number Systems

Precept 5: (Monday/Tuesday) C Pointers and Arrays

Lecture 6: (Wednesday) Number Systems (cont.); Testing

Precept 6: (Wednesday/Thursday) C Arrays and Strings


Week 4: 2/25 - 3/3

Reading (required): C Programming (King) 16, 17

Reading (recommended): The Practice of Programming (Kernighan & Pike) 2, 5

Reading (recommended): GNU Make Tutorial

Lecture 7: (Monday) Building; Debugging Part 1

Precept 7: (Monday/Tuesday) C Command-Line Arguments; C Structures; C Dynamic Memory Management

(Tuesday 2/26) String Module Assignment Due (at 10:00PM)

Lecture 8: (Wednesday) Debugging (Part 2); Data Structures

Precept 8: (Wednesday/Thursday) Tools for Debugging Dynamic Memory Management; Abstract Data Types in C


Week 5: 3/4 - 3/10

Reading (required): C Programming (King) 19, 22

Reading (recommended): The Practice of Programming (Kernighan & Pike) 1, 4, 8

Lecture 9: (Monday) Modularity

Precept 9: (Monday/Tuesday) C Void Pointers; The Symbol Table Assignment

Lecture 10: (Wednesday) Programming Style

Precept 10: (Wednesday/Thursday) C Function Pointers; A DynArray ADT

(Sunday 3/10) Symbol Table Assignment Due (at 10:00PM)


Week 6: 3/11 - 3/17

Reading (required): C Programming (King) 10, 18

Reading (recommended): The Practice of Programming (Kernighan & Pike) 7

Reading (recommended): Computer Systems (Bryant & O'Hallaron) 5.1-5

Reading (recommended, for reference only): GNU Gprof Tutorial

Lecture 11: (Monday) Performance Improvement

Precept 11: (Monday/Tuesday) C Declarations and Definitions

Lecture 12: (Wednesday) Midterm Examination (Midterm Exam Prep Document, Midterm Exams and Answers from Previous Semesters, This Semester's Exam, Answers to This Semester's Exam)

Precept 12: (Wednesday/Thursday) NO PRECEPT


Week 7: 3/18 - 3/24

(Monday - Sunday) Spring Recess


Week 8: 3/25 - 3/31

Reading (required): ARM 64 Bit Assembly Language (Pyeatt with Ughetta) 2-5 (available as hard copy through Pequod)

Reading (recommended, for reference only): ARMv8 Instruction Set Overview

Reading (recommended, for reference only): ARM Architecture Reference Manual

Reading (recommended, for reference only): Using as

Lecture 13: (Monday) Language-Levels Tour: Assembly Language 1

Precept 13: (Monday/Tuesday) Assembly Language: Getting Started

Lecture 14: (Wednesday) Language-Levels Tour: Assembly Language 2

Precept 14: (Wednesday/Thursday) Assembly Language: Fundamentals, Control Transfer (Part 1)


Week 9: 4/1 - 4/7

Reading (recommended): ARM 64 Bit Assembly Language (Pyeatt with Ughetta) 6-7 (available as hard copy through Pequod)

Reading (recommended): Computer Systems (Bryant & O'Hallaron) 7

Lecture 15: (Monday) Language-Levels Tour: Assembly Language Function Calls

Precept 15: (Monday/Tuesday) Assembly Language: Control Transfer (Part 2), Instruction Operands, GDB for Assembly Language

Lecture 16: (Wednesday) Language-Levels Tour: Machine Language

Precept 16: (Wednesday/Thursday) Assembly Language: Local Variables, Functions, The Assignment 4 BigInt_add Function


Week 10: 4/8 - 4/14

Reading (required): Computer Systems (Bryant & O'Hallaron) 8.1-8.3 (available through Blackboard in the "Course Materials" section)

Reading (recommended): Computer Systems (Bryant & O'Hallaron) 6

Lecture 17: (Monday) Assembler and Linker; Buffer Overrun Attacks(same slides as last time)

Precept 17: (Monday/Tuesday) Buffer Overrun Attacks

(Tuesday 4/9) Assembly Language and Testing Assignment Due (at 10:00PM)

Lecture 18: (Wednesday) Service-Levels Tour: Processes and Exceptions

Precept 18: (Wednesday/Thursday) Buffer Overrrun Attacks (Part 2); Linux File Permissions and File Sharing


Week 11: 4/15 - 4/21

Reading (required): The C Programming Language (Kernighan & Ritchie) 8.7 (available through Blackboard in the "Course Materials" section)

Reading (required): Computer Systems (Bryant & O'Hallaron) 9 (available through Blackboard in the "Course Materials" section)

Lecture 19: (Monday) Service-Levels Tour: Storage Hierarchy and Virtual Memory

Precept 19: (Monday/Tuesday) C Abstract Objects; The HeapMgr Assignment: Introduction

Lecture 20: (Wednesday) Service-Levels Tour: Dynamic Memory Management

Precept 20: (Wednesday/Thursday) The HeapMgr Assignment: Linked List Implementation Data Structures, Algorithms, and Code


Week 12: 4/22 - 4/28

Reading (required): Computer Systems (Bryant & O'Hallaron) 8.4 (available through Blackboard in the "Course Materials" section)

Lecture 21: (Monday) Service-Levels Tour: Dynamic Memory Management (cont., same slides as Lecture 20)

Precept 21: (Monday/Tuesday) The HeapMgr Assignment: Doubly-Linked List Implementation Data Structures, Algorithms, and (Partial) Code, Bins Implementation Data Structures, Algorithms, and (Partial) Code

(Tuesday 4/23) Buffer Overrun Assignment Due (at 10:00PM)

Lecture 22: (Wednesday) Service-Levels Tour: Process Management

Precept 22: (Wednesday/Thursday) The Unix Shell Assignment: Introduction


Week 13: 4/29 - 5/5

Reading (recommended): Computer Systems (Bryant & O'Hallaron) 10

Reading (required): Computer Systems (Bryant & O'Hallaron) 8.5 (available through Blackboard in the "Course Materials" section)

Reading (required): C Programming (King) 24.2-3

Lecture 23: (Monday) Service-Levels Tour: I/O Management

Precept 23: (Monday/Tuesday) The Unix Shell Assignment: Processes

Lecture 24: (Wednesday) Service-Levels Tour: Signals

Precept 24: (Wednesday/Thursday) The Unix Shell Assignment: I/O Redirection and Signals

(Friday 5/3) Heap Manager Assignment Due (at 10:00PM)


Week 14: 5/6 - 5/12

(Monday - Sunday) Reading Period


Week 15: 5/13 - 5/19

(Monday - Tuesday) Reading Period

(Tuesday) Dean's Date

(Tuesday 5/14) Shell Assignment Due (at 5:00PM)

(Wednesday - Sunday) Final Examination Period

(Thursday 5/16) Final Exam Prep Session, 1:30PM, CS Building 105

(Friday 5/17) Final Exam Prep Session, 1:30PM, CS Building 105


Week 16: 5/20 - 5/26

(Monday - Saturday) Final Examination Period

(Monday 5/20) Final Examination, 7:30PM-10:30PM, McCosh Hall 10 (Final Exam Prep Document, Final Exams and Answers from Previous Semesters, This Semester's Exam, Answers to This Semester's Exam)


All lecture notes are copyright 2001-2019 by Jaswinder Pal Singh, David August, Vivek Pai, Jennifer Rexford, Kai Li, Andrew W. Appel, Randolph Wang, Thomas Funkhouser, David R. Hanson, Larry Peterson, Aarti Gupta, Szymon Rusinkiewicz, and/or Robert M. Dondero, Jr. All precept handouts are copyright 2001-2019 by Robert M. Dondero, Jr. Permission to reproduce these notes for not-for-profit educational purposes is hereby granted. These notes may not be reproduced for commercial purposes without the express written consent of the author.