Engineering.wustl.edu

E81 CSE 542S: Concurrency and Memory Safe System Software Development

Professor: Chris Gill
e-mail: cdgill@wustl.edu
office: McKelvey 1039 (office hours outside of class meetings are by appointment)

Fall 2024

Course web page: http://www.cse.wustl.edu/~cdgill/courses/cse542/

Course Piazza page: https://piazza.com/wustl/fall2024/fl2024e81cse542s01

Exam 1: Tue Oct 15, 10-11:20am in Whitaker 218

Exam 2: Tue Nov 26, 10-11:20am in Whitaker 218


Contents

  1. Times and Locations
  2. Course Description
  3. Prerequisites
  4. Discussions/Studios
  5. Labs
  6. Textbooks and Other Resources
  7. Grading
  8. Academic Support, Health and Wellness, and Disabilities
  9. Title IX, Diversity, and Inclusion
  10. Academic Integrity


Times and Locations

Lectures/Discussions/Studios: Urbauer 216, 10-11:20am Tuesdays and Thursdays


Course Description

As multi-core processors and multi-threaded programming are ever more prevalent in modern computing systems, ensuring correctness of programs depends strongly on avoiding hazards that may arise from concurrency and memory management semantics in those contexts. This course focuses on the memory safety and concurrency safety models in Rust, with an emphasis on the language's syntax and semantics related to those models, both separately and in combination, as well as a general coverage of the language as a whole. Lectures and assigned readings will be augmented with studio exercises and laboratory assignments in which key language features will be explored and applied hands-on.


Prerequisites

CSE 422S (Operating Systems Organization), or graduate standing and prior experience with concurrency, synchronization, and memory management.

Discussions/Studios

This course is offered in a studio/lab format, to emphasize active learning through hands-on participation. Except for a few open lab sessions, and the days when exams reviews and the exams themselves are held, you will work in small groups on studio exercises that will emphasize three main topics: (1) Rust language syntax and semantics, (2) memory safety, and (3) concurrency safety.

Reading materials will be assigned for many of the topics. It is to your advantage to go over the readings prior to class time, and to ask questions about anything that may be unclear. Supplemental resources including web materials and additional books that may be helpful also may be suggested.

Dates
Topics
Readings/Resources
Assignments
Tue Aug 27 Course Introduction
Academic Integrity
About Rust
BOT Chapter 1
(optionally KN Chapter 1)
 
Thu Aug 29 A Tour of Rust BOT Chapter 2
(optionally KN Chapter 2)
Studio 1
Tue Sep 3 Types in Rust BOT Chapter 3
(optionally KN Chapter 3)
Studio 2
Thu Sep 5 Ownership and Moves BOT Chapter 4
(optionally KN Chapter 4 pp. 59-70)
Studio 3
Tue Sep 10 References
Lab 1 overview
BOT Chapter 5
(optionally KN Chapter 4 pp. 71-83)
Studio 4
Lab 1 assigned
Thu Sep 12 Expressions BOT Chapter 6 Studio 5
Tue Sep 17 Error Handling BOT Chapter 7
(optionally KN Chapter 9)
Studio 6
Thu Sep 19 Crates and Modules BOT Chapter 8 and BOT pp. 535-540 (Atomics and Global Variables)
(optionally KN Chapter 7)
Studio 7
Tue Sep 24 Structs BOT Chapter 9
(optionally KN Chapter 5)
Studio 8
Thu Sep 26 Enums and Patterns BOT Chapter 10
(optionally KN Chapter 6)
Studio 9
Lab 1 due 11:59pm Fri Sep 27
Tue Oct 1 Traits and Generics
Lab 2 overview
BOT Chapter 11
(optionally KN Chapter 10)
Studio 10
Lab 2 assigned
Thu Oct 3 Operator Overloading BOT Chapter 12 Studio 11
Tue Oct 8 Fall Break (no course meeting)
Thu Oct 10 Exam 1 Review Studios 1-11 due by 11:59pm Mon Oct 14
Tue Oct 15 Exam 1 (10-11:20am in Whitaker 218)
Thu Oct 17 Utility Traits BOT Chapter 13 Studio 12
Tue Oct 22 Closures BOT Chapter 14
(optionally KN Chapter 13 pp. 274-284)
Studio 13
Thu Oct 24 Iterators BOT Chapter 15
(optionally KN Chapter 13 pp. 284-294)
Studio 14
Tue Oct 29 Collections BOT Chapter 16
(optionally KN Chapter 8 pp. 141-147 and 154-159)
Studio 15
Thu Oct 31 Strings and Text BOT Chapter 17
(optionally KN Chapter 8 pp. 147-154)
Studio 16
Lab 2 due 11:59pm Fri Nov 1
Tue Nov 5 Input and Output
Lab 3 overview
BOT Chapter 18
(optionally KN Chapter 12)
Studio 17
Lab 3 assigned
Thu Nov 7 Concurrency BOT Chapter 19
(optionally KN Chapter 16)
Studio 18
Tue Nov 12 Asynchronous Programming BOT Chapter 20 Studio 19
Thu Nov 14 Macros BOT Chapter 21
(optionally KN Chapter 19 pp. 449-458)
Studio 20
Tue Nov 19 Unsafe Code
Foreign Functions
BOT Chapters 22 and 23
(optionally KN Chapter 19 pp. 420-429)
open time to catch up on studios or work on lab 3
Thu Nov 21 Exam 2 Review Studios 12-20 due by 11:59pm Mon Nov 25
Tue Nov 26 Exam 2 (10-11:20am in Whitaker 218)
Thu Nov 28 Thanksgiving Break (no course meeting)
Tue Dec 3 open time to work on lab 3
Thu Dec 5 open time to work on lab 3
Lab 3 due 11:59pm Fri Dec 6th


Labs

There will be 3 lab projects this semester, which will be turned in via Canvas, and will be graded and returned to you electronically as well. Each lab assigment will give details of the procedure for turning in the lab. Labs will increase in length, value, and difficulty throughout the semester. The exact due date will be specified in each lab description.

Each lab will require a lab report. Report format and length and content requirements will be described in each lab assignment. The actual report will be submitted via e-mail, as well, so it must go into a file.

Labs will be performed in teams of 1, 2 or 3 people (but not more than 3): teams may be different for each lab assignment or may remain the same for all labs. Each team should submit its solution and lab report for each project.

Labs submitted within 24 hours after the posted deadline will be accepted with a 10% penalty up front, and labs submitted between 24 and 48 hours after the posted deadline will be accepted with a 20% penalty up front. Labs submitted after that will not be graded except in the case of extenuating circumstances approved by the professor.

You may discuss your lab projects with other students outside your team only during course meeting times. Discussion of lab projects within a team, is encouraged at any time. Each team must design and implement its own solution, and prepare its own report.

The following lab assignments have been posted so far in the course:


Textbooks and Other Resources

Required text:

We'll use the required textbook both for class material and as a reference. Revelant portions of the required text will be assigned throughout the semester: please read each assigned section before the course meeting where it will be discussed.

Optional text:

Readings in the optional textbook also will be suggested, for enrichment and to complement the assigned readings in the required text.

Please read through the CSE 542 Programming Guidelines and follow them as you develop your studio and lab solutions this semester.


Grading

Labs and studios will constitute a major portion of the grade in this course. This reflects the course's emphasis on hands-on exploration of the material. Labs will be graded for quality of design, implementation, and documentation. Studios will be graded for completion of all the required exercises, though grading comments may be provided as feedback even if a studio is marked complete.

The in-semester exams will be roughly proportioned to cover the material in all other aspects of the course: readings, lectures, studios, and labs. The best way to study for the exams is to keep up with the readings, lectures, studio exercises, and labs during the semester. The first exam will cover the material up to that point in the course, and the second exam will cover the material after the first exam.

Labs 50 percent
   Lab 1:  10 percent
   Lab 2:  15 percent
   Lab 3:  25 percent
Exam 1 15 percent
Exam 2 15 percent
Studios 20 percent


Academic Support, Health and Wellness, and Disabilities

We encourage everyone to take a look at, and potentially make use of, the many academic support resources available at Washington University in St. Louis, including: The Learning Center, and The Writing Center, and Student Technology Services.

Washington University recognizes that students serving in the U.S. Armed Forces and their family members may encounter situations where military service forces them to withdraw from a course of study, sometimes with little notice. Students may contact the Office of Military and Veteran Services at (314) 935-2609 or veterans@wustl.edu and their academic dean for guidance and assistance.

The Habif Health and Wellness Center, WashU Cares, Center for Counseling and Psychological Services, and RSVP are important university resources for issues pertaining to physical and mental health.

Students with disabilities or suspected disabilities are strongly encouraged both to bring any additional considerations to the attention of the instructor and to make full use of Washington University's Disability Resources, potentially including accommodations for studios, labs, and/or exams.


Title IX, Diversity, and Inclusion

Washington University is firmly committed to addressing and preventing sexual misconduct on our campuses: please see the Washington University statement on new Title IX rules. If a student discusses or discloses an instance of sexual assault, sex discrimination, sexual harassment, dating violence, domestic violence or stalking, or if a faculty member otherwise observes or becomes aware of such an allegation, the faculty member will keep the information as private as possible, but as a faculty member of Washington University, they are required to report it immediately to their Department Chair or Dean or directly to Ms. Jessica Kennedy, the University's Title IX Director, at (314) 935-3118 or jwkennedy@wustl.edu. Additionally, incidents or complaints can be reported to the Office of Student Conduct and Community Standards or by contacting WUPD at (314) 935-5555 or contacting your local law enforcement agency. To explore options for medical care, protections, or reporting, free and confidential support resources and professional counseling services are available through the Relationship and Sexual Violence Prevention (RSVP) Center in Seigle Hall, Suite 435, which can be reached at rsvpcenter@wustl.edu or at (314) 935-3445. For after-hours emergency response services, call 314-935-6666 or 314-935-5555 and ask to speak with an RSVP Counselor on call.

Washington University's Center for Diversity and Inclusion supports and advocates for undergraduate, graduate, and professional school students from underrepresented and/or marginalized populations, collaborates with campus and community partners, and promotes dialogue and social change to cultivate and foster a supportive campus climate for students of all backgrounds, cultures, and identities. The University has a process through which students, faculty, staff, and community members who have experienced or witnessed incidents of bias, prejudice, or discrimination against a student can report their experiences to the University's Bias Report and Support System team. For procedures and information on reporting an instance of bias, please visit the Bias Report and Support System page on the Center for Diversity and Inclusion web site. In order to affirm each person's gender identity and lived experiences, it is important that we each ask and check in with others about pronouns. This simple effort can make a profound difference in a person's experience of safety, respect, and support. Please see the Office of the Registrar's Preferred Name page for additional information and resources.


Academic Integrity

Each studio and lab assigned in this course is expected to be completed collaboratively by up to three people (and not more than that). Student teams may change from assignment to assignment, but the sharing of code between teams without prior permission of the instructor is strictly prohibited, and you must acknowledge and document in detail all contributions that anyone has made to the work.

Exams must be completed individually without assistance from any other person and without reference to materials or devices, except as specifically allowed by the instructor (documentation of what is allowed will be described in class, provided in the corresponding exam review slides, and written on the font page of the exam).

Cheating costs everyone something. Someone who cheats misses out on the intended opportunity to improve through the assigned work, and like anyone helping them cheat is at risk of diminished reputation as well as specific sanctions. Cheating also degrades the value of the degree earned by those who complete their work with integrity. If you have any doubt about whether something is allowed under the academic integrity policy for this course, please ask your instructor first.

Academic integrity is itself worth studying and thinking about as a key component of your education. Please read, familiarize yourself with, and reflect on the McKelvey School of Engineering's and Washington University's undergraduate and graduate policies on academic integrity.