GSoC'22: Accelerating Fortran DO CONCURRENT in GCC

GSoC '22 Blog post 0: GCCprefab – a relatively easy way to build GFortran

This weekend marks the end of the community bonding period for GSoC '22, and here’s my progress so far with the project.

I met with Tobias Burnus, one of my mentors, over a MS Teams call on May 30, 2022. Together, we picked GCC PR# 102003 as a good starter issue to start delving into the Fortran parser in GCC. He also guided me through how to debug the compiler using gdb.

In the meantime, I’ve implemented a simple build script system for GCC that I christen GCCprefab. Before this build system existed, there are only three relatively easy ways to build GCC painlessly:

  1. Using Spack package manager: spack install gcc
  2. Using the install script for OpenCoarrays
  3. Using jwakely’s build script

The name pays homage to prefabricated buildings such as sheds/barns (even sections of houses) that are commonly sold in the US at hardware stores such as Home Depot or Lowe’s. It’s arguably an overengineered solution to my laziness having to memorize all the different configure flags when building GCC from sources.

Right now, GCCprefab has the following features:

  • One single script written in Bash
  • “Eats” a config file with a custom format inspired by Spack spec syntax and the Windows INI / TOML format for configuration files
  • Clones the main GCC Git repo, or a custom mirror of your choice
  • Upon execution, logs standard output for each phase of the build process into a timestamped log file, which is xz-compressed after each phase completes successfully
  • Licensed under the Apache 2.0 license

To try it out, you can head over to my GitHub repo. Please feel free to open an issue there if you found a bug undocumented feature or to suggest new features. Pull requests are welcome too!

4 Likes