CMPSC 476: Systems Debugging

Hello, if you have any need, please feel free to consult us, this is my wechat: wx91due

CMPSC 476: Systems Debugging

Description:

Debugging is a practical and essential skill for any computer scientist to be able to properly diagnosis and fix problems (i.e., bugs) in systems and/or code. The goal of this course is for students to develop debugging skills through extensive practice. The course will cover general methodologies for debugging such as instrumentation, consistency checking, and divide & conquer. The course will also cover how to effectively utilize a variety of debugging tools such as debuggers, memory error detectors, race condition detectors, etc. Lastly, the course will explain specific types of bugs such as race conditions, deadlocks, and corrupted memory, which is necessary for finding these types of bugs. This is a project-based course that will involve extensive reading and writing of C code and use of Linux, so a solid background knowledge in C and Linux is expected.

Prerequisites:

  • CMPSC311
  • C programming
  • Linux

Required materials:

  • Computer able to run a linux VM, run native linux, or ssh to a linux machine
  • Canvas access during lecture (e.g., phone, laptop, tablet)

Learning objectives:

By the end of the course,

  • students will be able to effectively utilize debugging tools (e.g., gdb, valgrind, thread sanitizer) and understand how they work
  • students will be able to identify the appropriate debugging approach and apply it to identify bugs
  • students will be able to identify symptoms and causes of common bugs (e.g., segfaults, memory corruption, race conditions, deadlocks)

Preliminaries (must be done first)

  • Academic Integrity in EECS
  • Programming Assignment Setup

Assignments

  • Assignment 1: pointer
  • Assignment 2: unit testing
  • Assignment 3: gdb usage
  • Assignment 4: gdb extension
  • Assignment 5: consistency checker
  • Assignment 6: valgrind
  • Assignment 7: concurrency

Grading:

  • 65% Assignments
  • 10% Midterm
  • 20% Comprehensive final
  • 5% Mini quizzes: during most (if not all) lectures

Late policy:

Each assignment can be submitted at most 1 day late with a 15% penalty. 1 day refers to 11:59PM the day after the assignment is due, which may be more than 24 hours. Assignments are generally due at the start of class. All times in the course are in local PA time (Eastern Time).

Class participation (mini quizzes) will be determined by answering a question during each lecture via a Canvas Quiz: 2 – Correct answer, 1 – Incorrect answer, 0 – No response. There will not be any makeup/excused absences for class participation, and instead, the lowest 5 participation scores will be dropped.

Schedule (subject to change):

CATEGORY TOPIC
Background Introduction/Background in C
Approach Effective Coding Practices
Approach Testing
Approach Testing
Bugs Segfaults
Background Linux Basic Tools
Tools GDB Basic (gdb_demo.c)
Tools GDB Basic (gdb_demo.c)
Tools GDB Intermediate
Tools GDB Intermediate
Tools GDB Advanced
Tools GDB Internals
Tools GDB Extensions – gdb
Tools GDB Extensions – python
Approach Debugging Approach
Bugs System/Configuration Bugs
Background Building – Compiling & Linking
Background Building – gcc & make
Bugs Build Bugs
Approach Consistency Checking
Bugs Corruption Bugs
Review Review
Midterm Midterm
Bugs Memory Leaks/Resource Leaks
Bugs Memory Leaks/Resource Leaks
Tools Valgrind
Tools Valgrind
Approach Profiling
Approach Profiling/Tracing
Approach Instrumentation/Logging
Tools tprof
Background Processes/Threads
Background Synchronization Primitives
Background Synchronization Primitives
Bugs Race Condition Bugs
Bugs Race Condition Bugs
Bugs Race Condition Bugs
Bugs Deadlock Bugs
Tools GDB and Threads
Tools Thread Sanitizer
Bugs Metastable Failures
Approach Fuzzing
Review Review

Academic Integrity Statement:

In this course, all work (e.g., homework assignments, programming assignments, quizzes, exams, etc.) is to be done individually and independently. No outside help of any form is permitted. You are also responsible for securing your work so that you do not intentionally or unintentionally assist any other student in violating the academic integrity policy.

For example, the following are strictly forbidden:

  • Looking at another student’s code or work
  • Debugging another student’s code
  • Looking online for hints on how to solve an assignment
  • Getting hints from another student on how to complete an assignment
  • Providing hints to another student on how to complete an assignment
  • Using any code or solution from any online source
  • Using any Artificial Intelligence tool (e.g., ChatGPT) for assignments
  • Posting any course-related code or material to any online public location (e.g., public github repository, online forums, etc.)
  • Using any other student’s account or allowing anyone else to use your account
  • Assisting anyone in violating any academic integrity policy either intentionally or unintentionally from not securing your work
  • Getting any help from any source other than a course staff member

The above list is non-exhaustive, and it is your responsibility to ensure that you A) complete all the coursework individually and independently without any outside help of any form, and B) secure your work so that you do not intentionally or unintentionally assist any other student in violating the academic integrity policy.

Additionally, this course follows all the standards in the CSE Department’s Academic Integrity Policy, which includes using tools to identify similarities with submitted code and other code from online sources and any submission, prior or present.

Completing the department’s Academic Integrity module is required for the course.

Failure to comply by the academic integrity policy will result in a 0 for the assignment plus a 10% overall course grade reduction. Additional sanctions (e.g., F for course) may apply depending on the severity and for repeat offenders. Providing false or misleading information or failure to provide relevant information when addressing academic integrity could increase the severity of the offense — honesty is an important aspect of academic integrity.

Academic integrity is the pursuit of scholarly activity in an open, honest and responsible manner. Academic integrity is a basic guiding principle for all academic activity at The Pennsylvania State University, and all members of the University community are expected to act in accordance with this principle. Consistent with this expectation, the University’s Code of Conduct states that all students should act with personal integrity, respect other students’ dignity, rights and property, and help create and maintain an environment in which all can succeed through the fruits of their efforts.

Academic integrity includes a commitment by all members of the University community not to engage in or tolerate acts of falsification, misrepresentation or deception. Such acts of dishonesty violate the fundamental ethical principles of the University community and compromise the worth of work completed by others.

Lecture Recording Statement:

Video and audio recordings of class lectures will be part of the classroom activity. The video and audio recording is used for educational use/purposes and only may be made available to all students presently enrolled in the class. For purposes where the recordings will be used in future class session/lectures, any type of identifying information will be adequately removed.

Recordings can be found in the Media Gallery tab after processing is completed.

Disability Accommodation Statement:

Penn State welcomes students with disabilities into the University’s educational programs. Every Penn State campus has an office for students with disabilities. The Student Disability Resources website provides contact information for every Penn State campus. For further information, please visit the Student Disability Resources website.

In order to receive consideration for reasonable accommodations, you must contact the appropriate disability services office at the campus where you are officially enrolled, participate in an intake interview, and provide documentation. If the documentation supports your request for reasonable accommodations, your campus’s disability services office will provide you with an accommodation letter. Please share this letter with your instructors and discuss the accommodations with them as early in your courses as possible. You must follow this process for every semester that you request accommodations.

Counseling and Psychological Services (CAPS) Statement:

Many students at Penn State face personal challenges or have psychological needs that may interfere with their academic progress, social development, or emotional wellbeing. The university offers a variety of confidential services to help you through difficult times, including individual and group counseling, crisis intervention, consultations, online chats, and mental health screenings. These services are provided by staff who welcome all students and embrace a philosophy respectful of clients’ cultural and religious backgrounds, and sensitive to differences in race, ability, gender identity and sexual orientation.

Counseling and Psychological Services at University Park (CAPS) (http://studentaffairs.psu.edu/counseling/): 814-863-0395

Counseling and Psychological Services at Commonwealth Campuses (https://senate.psu.edu/faculty/counseling-services-at-commonwealth-campuses/)

Penn State Crisis Line (24 hours/7 days/week): 877-229-6400
Crisis Text Line (24 hours/7 days/week): Text LIONS to 741741

Education Equity and Reporting Bias:

Penn State takes great pride to foster a diverse and inclusive environment for students, faculty, and staff. Acts of intolerance, discrimination, or harassment due to age, ancestry, color, disability, gender, gender identity, national origin, race, religious belief, sexual orientation, or veteran status are not tolerated and can be reported through Educational Equity via the Report Bias webpage (http://equity.psu.edu/reportbias/).

发表评论

电子邮件地址不会被公开。 必填项已用*标注