Programming Parallel Computers

HY 2023–2024

Pre0: prerequisite test ★

You need to log in to make submissions.

What you will need to do in this task

Please read the general instructions for this exercise first. Here are the additional instructions specific to this task:

In this task you do not need to worry much about the performance. The most straightforward implementation that you can imagine should be fast enough to meet the time limits. No specific techniques are required and you are not expected to use any form of parallelism yet; any solution that works correctly is fine.

What I will try to do with your code

I will first run all kinds of tests to see that your code works correctly. You can try it out locally by running ./grading test, but please note that your code has to compile and work correctly not only on your own computer but also on our machines.

If all is fine, I will run the benchmarks. You can try it out on your own computer by running ./grading benchmark, but of course the precise running time on your own computer might be different from the performance on our grading hardware.


Name Operations Parameters
benchmarks/1 7,500 nx = 100, ny = 100
the input contains 100 × 100 pixels, and the rectangle contains 50 × 50 pixels
benchmarks/2 750,000 nx = 1000, ny = 1000
the input contains 1000 × 1000 pixels, and the rectangle contains 500 × 500 pixels

Here “operations” is our rough estimate of how many useful arithmetic operations you will at least need to perform in this benchmark, but of course this will depend on exactly what kind of an algorithm you are using.


In this task your submission will be graded using benchmarks/2: the input contains 1000 × 1000 pixels, and the rectangle contains 500 × 500 pixels.

The point thresholds are as follows. If you submit your solution no later than on Saturday, 31 August 2024, at 23:59:59 (Helsinki), your score will be:

Running timePoints
≤ 1.000 sec 1

For late submissions you will not get any points.