COMP 322: Fundamentals of Parallel Programming (Spring
...
2023)
InstructorsInstructor: | Mackale Joyner, DH 2063 |
---|
Zoran Budimlić, DH 3003 Adrienne Li, Austin Hushower, Claire Xu, Diep Hoang, Hunena Badat, Maki Yu, Mantej Singh, Rose Zhang, Victor Song, Yidi Wang | Admin Assistant: | Annepha Hurlock, annepha@rice.edu , DH 3122, 713-348-5186 | | Mohamed Abead, Chase Hartsell, Taha Hasan, Harrison Huang, Jerry Jiang, Jasmine Lee, Michelle Lee, Hung Nguyen, Quang Nguyen, Ryan Ramos, Oscar Reynozo, Delaney Schultz, Tina Wen, Raiyan Zannat, Kailin Zhang |
Piazza site: | https://piazza.com/rice/ |
---|
spring2022spring2023/comp322 (Piazza is the preferred medium for all course communications) | Cross-listing: | ELEC 323 |
---|
Lecture location: | Herzstein Amphitheater |
---|
(online 1st 2 weeks) | Lecture times: | MWF 1:00pm - 1:50pm |
---|
Lab locations: | Mon (Herzstein Amp), Tue (Keck 100 |
---|
(online 1st 2 weeks) | Lab times: | Mon 3:00pm - 3:50pm ( |
---|
Austin, ClaireRaiyan, Oscar, Mohamed, Ryan, Michelle, Taha) |
Wed 30pm 520pm Hunena Mantej Yidi Victor Rose Adrienne Diep, Maki Course Syllabus
A summary PDF file containing the course syllabus for the course can be found here. Much of the syllabus information is also included below in this course web site, along with some additional details that are not included in the syllabus.
...
- Fork-Join Parallelism with a Data-Structures Focus (FJP) by Dan Grossman (Chapter 7 in Topics in Parallel and Distributed Computing)
- Java Concurrency in Practice by Brian Goetz with Tim Peierls, Joshua Bloch, Joseph Bowbeer, David Holmes and Doug Lea
- Principles of Parallel Programming by Calvin Lin and Lawrence Snyder
- The Art of Multiprocessor Programming by Maurice Herlihy and Nir Shavit
Lecture Schedule
...
20222023) | Lecture | Assigned Reading | Assigned Videos (see Canvas site for video links) | In-class Worksheets | Slides | Work Assigned | Work Due | Worksheet Solutions |
---|
1009 | Lecture 1: Introduction |
| slides | | 1211 | Lecture 2: Functional Programming |
GList.java | | | | | 14 | worksheet3 | lec3-slides | | 17 | | | | | | | | 1918 | Lecture 4: Lazy Computation |
LazyList.java Lazy.java | | | | 2120 | Lecture 5: Java Streams |
| | 2423 | Lecture 6: Map Reduce with Java Streams | Module 1: Section 2.4 | Topic 2.4 Lecture, Topic 2.4 Demonstration | worksheet6 | lec6-slides |
| | 2625 | Lecture 7: Futures | Module 1: Section 2.1 | Topic 2.1 Lecture , Topic 2.1 Demonstration | worksheet7 | lec7-slides |
| | 2827 | Lecture 8: Async, Finish, Computation Graphs |
, Ideal Parallelism232 2 1 Demonstration, Topic 1. |
3 3 lec8 | | 31 Async Finish, Data-Driven Tasks | Module 1: Section 1. |
1
1 1 | | 0201 | Lecture 10: Event-based programming model |
| | | 0403 | Lecture 11: GUI programming |
as an example of event-based,futures/callbacks in GUI programming, Scheduling/executing computation graphs
| Module 1: Section 1.4 | Topic 1.4 Lecture , Topic 1.4 Demonstration | worksheet11 | lec11 |
| | worksheet11 | lec11Homework 1 07Scheduling/executing computation graphs Abstract performance metrics, Parallel Speedup, Amdahl's Law | Module 1: Section 1. |
44 4 | | 09 Parallel Speedup, Critical Path, Amdahl's Law Accumulation and reduction. Finish accumulators |
15 15 , 15 | 1110 | No class: Spring Recess |
| | | | | | | 14 Accumulation and reduction. Finish accumulatorsData Races, Functional & Structural Determinism | Module 1: |
Section 35, 2.6 | Topic 2.5 Lecture , Topic 2.5 Demonstration, Topic 2. |
3 3 | | 16 Recursive Task Parallelism | | | | Fri | 18 Data Races, Functional & Structural DeterminismModule 1: Sections 2.5, 2.6 | Topic 2.5 Lecture , Topic 2.5 Demonstration, Topic 2.6 Lecture, Topic 2.6 DemonstrationHomework 2 | 21 20 | Lecture 17: Midterm Review |
| | | lec17-slides | | | | | 23 | | worksheet18 | Limitations of Functional parallelism.
Abstract vs. real performance. Cutoff Strategy | WS18-solution | | | 25 Fork/Join programming model. OS Threads. Scheduler Pattern Data-Parallel Programming model. Loop-Level Parallelism, Loop Chunking | Module 1: Sections |
278 27 1 Lecture, Topic 3.1 Demonstration , Topic 3.2 Lecture, Topic 3. |
7 28 Topic 28 , | 28 Confinement & Monitor Pattern. Critical sections
Global lock Barrier Synchronization with Phasers | Module |
2 5.1, 5.2, 5.6 51 5.1 Demonstration, Topic 5.2 Lecture, Topic 5.2 Demonstration, Topic 5.6 Lecture, Topic 5.6 Demonstration | | Wed | 02 Atomic variables, Synchronized statements Module 2: Sections 5.4, 7.2 | Topic 5.4 Lecture, Topic 5.4 Demonstration, Topic 7.2 LectureStencil computation. Point-to-point Synchronization with Phasers | Module 1: Sections 4.2, 4.3 | Topic 4.2 Lecture, Topic 4.2 Demonstration, Topic 4.3 Lecture, Topic 4.3 Demonstration | worksheet21 | lec21-slides |
| | 04Parallel Spanning Tree, other graph algorithms Fuzzy Barriers with Phasers | Module 1: Section 4.1 | Topic 4.1 Lecture, Topic 4.1 Demonstration |
| Homework 4 | Homework 3 | 07 Java Threads and LocksModule 2: Sections 7.1, 7.3 | Topic 7.1 Lecture, Topic 7.3 Lecture Fork/Join programming model. OS Threads. Scheduler Pattern |
| Topic 2.7 Lecture, Topic 2.7 Demonstration, Topic 2.8 Lecture, Topic 2.8 Demonstration | worksheet23 | lec23-slides |
| | 09 Java Locks - Soundness and progress guarantees Confinement & Monitor Pattern. Critical sections Global lock | Module 2: |
7.5Sections 5.1, 5.2 | Topic 5.1 Lecture, Topic 5.1 Demonstration, Topic 5.2 Lecture, Topic 5.2 Demonstration, Topic 5.6 Lecture, Topic 5.6 Demonstration |
Topic 7.5 Lecture | | 11 Dining Philosophers Problem Atomic variables, Synchronized statements | Module 2: Sections 5.4, 7. |
62 | Topic 5.4 Lecture, Topic 5.4 Demonstration, Topic 7. |
6 Lecture | | 14 | | | | | | | 16 | | | | | | | | Mar 18 | No class: Spring Break | | | | | | | | | Mar 17 | No class: Spring Break |
21 | N-Body problem, applications and implementations | | 23 Read-Write Locks, Linearizability of Concurrent ObjectsJava Threads and Locks | Module 2: Sections 7. |
343 4 | Homework 3 (CP 2) | WS27-solution |
| 25 Message-Passing programming model with ActorsJava Locks - Soundness and progress guarantees | Module 2: |
6.1, 6.2 61 Lecture, Topic 6.1 Demonstration, Topic 6.2 Lecture, Topic 6.2 Demonstration5 Lecture | worksheet28 | lec28-slides |
worksheet28 | lec28-slides | |
28 Active Object Pattern. Combining Actors with task parallelism Dining Philosophers Problem | Module 2: |
63, .4 6.3 Lecture, Topic 6.3 Demonstration, Topic 6.4 Lecture, Topic 6.4 Demonstration7.6 Lecture | worksheet29 | lec29-slides |
| | 3029 | Lecture 30: Task Affinity and locality. Memory |
hierarchy | hierarchy |
|
| worksheet30 | lec30-slides |
| Homework 3 (All) | WS30-solution |
| Apr 01Data-Parallel Programming model. Loop-Level Parallelism, Loop ChunkingModule 1: Sections 3.1, 3.2, 3.3 | Topic 3.1 Lecture, Topic 3.1 Demonstration , Topic 3.2 Lecture, Topic 3.2 Demonstration, Topic 3.3 Lecture, Topic 3.3 DemonstrationRead-Write Locks, Linearizability of Concurrent Objects | Module 2: Sections 7.3, 7.4 | Topic 7.3 Lecture, Topic 7.4 Lecture | worksheet31 | lec31-slides |
Homework 5 04 Barrier Synchronization with PhasersModule 1: Section 3.4 | Topic 3.4 Lecture, Topic 3.4 Message-Passing programming model with Actors | Module 2: Sections 6.1, 6.2 | Topic 6.1 Lecture, Topic 6.1 Demonstration, Topic 6.2 Lecture, Topic 6.2 Demonstration | worksheet32 | lec32-slides |
| | 06 Stencil computation. Point-to-point Synchronization with PhasersModule 1: Section 4.2, 4.3 | Topic 4.2 Lecture, Topic 4.2 Demonstration, Topic 4.3 Lecture, Topic 4.3 Active Object Pattern. Combining Actors with task parallelism | Module 2: Sections 6.3, 6.4 | Topic 6.3 Lecture, Topic 6.3 Demonstration, Topic 6.4 Lecture, Topic 6.4 Demonstration | worksheet33 | lec33-slides |
| | 08 Fuzzy Barriers with PhasersModule 1: Section 4.1 | Topic 4.1 Lecture, Topic 4.1 Demonstration N-Body problem, applications and implementations |
|
| worksheet34 | lec34-slides |
| | 1110 | Lecture 35: Eureka-style Speculative Task Parallelism |
| | | 1312 | Lecture 36: Scan Pattern. Parallel Prefix Sum |
| | | | | 1514 | Lecture 37: Parallel Prefix Sum applications |
| | | | | 1817 | Lecture 38: Overview of other models and frameworks |
| | | | | | | 2019 | Lecture 39: Course Review (Lectures 19-38) |
| | | | | 2221 | Lecture 40: Course Review (Lectures 19-38) |
| | | Homework 5 | | Lab Schedule
20222023) | Topic | Handouts | Examples |
---|
1 | Jan |
---|
10 |
|
- | Jan 16 | No lab this week (MLK) |
|
|
---|
2 | Jan |
---|
17 | 3 | Jan 24 | | lab3-handout
| |
---|
4 | Jan 31lab45 | 07lab56 | 14lab6 21 20 | No lab this week (Midterm Exam) |
| 7 | 28Recursive Task Cutoff Strategy | lab7 8 0706 | Recursive Task Cutoff Strategy | lab7 |
Java Threads | lab8 | 1413 | No lab this week (Spring Break) |
|
|
- |
---|
| | 9 21Concurrent Listslab9 10 | Mar 28 | Actors | Apr 03 | Concurrent Lists | lab9 |
lab10 | 11 04Loop Parallelismlab11 11 | | - | Apr 18 | | | Grading, Honor Code Policy, Processes and Procedures
...