Implementing Coarray Support in LFortran
This project aims to implement full coarray support in the LFortran compiler, enabling native parallel programming capabilities based on the Partitioned Global Address Space (PGAS) model defined in the Fortran 2008/2018 standards. Currently, while LFortran’s parser supports coarray syntax, the feature is not implemented beyond basic stubs, preventing execution of even minimal coarray programs. The project will bridge this gap by extending LFortran’s Abstract Semantic Representation (ASR) to model coarrays, implementing semantic analysis for coarray constructs, and introducing a dedicated coarray runtime library. A key component is an ASR-to-ASR lowering pass that translates high-level coarray operations (such as coindexed access, synchronization, and collective intrinsics) into runtime calls. This design follows LFortran’s existing OpenMP architecture, ensuring backend-agnostic support across LLVM, C, and other targets. The implementation will proceed in two phases: first, establishing a fully functional single-image mode with correct semantics and runtime integration; second, enabling multi-image execution using an MPI-based runtime backend. By the end of the project, LFortran will be capable of compiling and executing coarray programs in both single-node and distributed environments. This work lays the foundation for supporting real-world coarray-based HPC applications and positions LFortran as a leading LLVM-based Fortran compiler with modern parallel programming support.
Project details
Technologies
Not listed in the archive