Tightly coupled parallel problem

So far, we have worked on an embarrassingly parallel problem (the Julia set), where there is no communication between individual pixels.

Compared to explicit message passing with MPI, Chapel really shines on tightly coupled parallel problems that require frequent communication between CPU cores.

One example of a tightly coupled parallel problem is the heat diffusion solver in the next section. Rather than working on that problem, I suggest to use an LLM to find a simple tightly coupled parallel problem on a 2D grid and implement it in Chapel, first in serial and then in parallel.

Below are the specific steps. It is more important to complete each step correctly than to move on to the next one, so don’t rush!

  1. Select a problem. I have some ideas, but I would like you to come up with your own suggestions talking to an LLM.
  2. Serial implementation in Chapel. Try to finish this step today.
    1. If there is a temporal axis, plot the solution at each timestep into a PNG file and create a movie using ffmpeg command-line tool. Figure out the most efficient video codec and container.
    2. How far can you push this serial solver in terms of spatial resolution?
  3. Shared-memory implementation in Chapel. Try doing this without an LLM, as it is really simple.
  4. Distributed-memory implementation in Chapel.
  5. Study parallel scaling for both implementations.
  6. Optimize your distributed-memory code with a more efficient decomposition than BlockDist. You can use an LLM to explore the alternatives.