Extending C++ with Co-array Semantics
Title | Extending C++ with Co-array Semantics |
Publication Type | Conference Paper |
Year of Publication | 2016 |
Authors | Tan, Antoine Tran, Kaiser, Hartmut |
Conference Name | Proceedings of the 3rd ACM SIGPLAN International Workshop on Libraries, Languages, and Compilers for Array Programming |
Date Published | June 2016 |
Publisher | ACM |
Conference Location | New York, NY, USA |
ISBN Number | 978-1-4503-4384-8 |
Keywords | API, APIs, applications programming interfaces, C++, Co-Array, compositionality, distributed containers, PGAS, pubcrawl, Resiliency |
Abstract | The current trend of large scientific computing problems is to align as much as possible to a Single Programming Multiple Data (or SPMD) scheme when the application algorithms are conducive to parallelization and vectorization. This reduces the complexity of code because the processors or (computational nodes) perform the same instructions which allows for better performance as algorithms work on local data sets instead of continuously transferring data from one locality to another. However, certain applications, such as stencil problems, demonstrate the need to move data to or from remote localities. This involves an additional degree of complexity, as one must know with which localities to exchange data. In order to solve this issue, Fortran has extended its scalar element indexing approach to distributed structures of elements. In this extension, a structure of scalar elements is attributed a "co-index" and lives in a specific locality. A co-index provides the application with enough information to retrieve the corresponding data reference. In C++, containers present themselves as a "smarter" alternative of Fortran arrays but there are still no corresponding standardized features similar to the Fortran co-indexing approach. In this paper, we present an implementation of such features in HPX, a general purpose C++ runtime system for applications of any scale. We describe how the combination of the HPX features and the actual C++ Standard makes it easy to define a high performance API similar to Co-Array Fortran. |
URL | https://dl.acm.org/doi/10.1145/2935323.2935332 |
DOI | 10.1145/2935323.2935332 |
Citation Key | tan_extending_2016 |