NPRG042 Programming in Parallel Environment

Assignments

  1. C# .NET Core Tasks
  2. TBB
  3. OpenMP
  4. SYCL
  5. Spark

Each assignment objective is to implement a parallel solution for a described problem. Let us emphasize that the solution must use a specified technology and must not use any other technology for parallelization (code optimizations are allowed). Please read the assignment specification carefully and observe all details regarding file-naming conventions, framework utilization, compilation, and APIs.

The parallel solution must return the exact same results as the serial solution unless specified otherwise. A solution that fails to do so will not be accepted (i.e., no points will be granted). Furthermore, a solution is forbidden to produce any output to either stdout or stderr that is not required or allowed in the problem description. Debugging outputs may interfere with our testing framework, so such a solution will be treated as if it does not provide the correct output.

Assignment submission and evaluation

The solutions should be submitted to ReCodEx unless specified otherwise. It provides the first level of checking—i.e., it verifies that your solution produces correct results and exhibits at least some minimal speedup. Please note that the correct results are provided by the serial solution, which is given to you for each problem.

After the deadline, the last solution from each student that passed all tests (i.e., achieved 100% correctness) in ReCodEx will be taken for the second level of evaluation (speedup). We will run performance tests on your solutions on parlab/gpulab and compute their speedups (which are the basis for our grading). The speedup is computed as the ratio of the measured wall time of the serial solution to your parallel solution. When multiple datasets are provided, the speedup is determined for each dataset separately, and the final speedup is computed as a harmonic mean of the individual speedups.

Unlike ReCodEx, the performance-testing environment does not use a sandbox or other means to prevent submitted solutions from performing malicious tasks, since we need to measure performance without interference. Please take extra care to ensure that your solution does not perform any tasks that may violate the security of Parlab. Any attempt at an intentional breach will result in severe disciplinary (and possibly legal) actions against the participants.

Infrastructure

Details regarding the testing infrastructure and assignment submission can be found on the HPC cluster page. The best way to invoke make and run your compiled solutions is via the srun command. For example:

$> srun -p mpi-homo-short -A nprg042s ./my-executable my-args

The -A nprg042s option specifies the user account, which is important (as it defines permissions for job queues). You will be assigned this account just before the first labs, based on the data from SIS. If you are not enrolled in NPRG042 in SIS when the assignment takes place, you will need to contact the teacher to get your account affiliation right.

Please note that Parlab uses Rocky Linux, which has an older version of the g++ compiler by default. We have installed newer versions of g++ on all workers so you can use the latest C++ features. The newer g++ compiler will also be used to test your submissions. It will be invoked with the following flags: CXXFLAGS=-Wall -O3 -std=c++20, unless specified otherwise.

Provided materials are located in /home/_teaching. The subdirectory para holds data related to the assignments (data, frameworks, ...), and the subdirectory examples contains examples that will be presented during the lectures.