Abstract
We present a technique for introducing and op-timizing the use of memory in a functional array language, aimed at GPU execution, that supports correct-by-construction parallelism. Using linear memory access descriptors as building blocks, we define a notion of memory in the compiler IR that enables cost-free change-of-layout transformations (e.g., slicing, transposition), whose results can even be carried across control flow such as ifs/loops without manifestation in memory. The memory notion allows a graceful transition to an unsafe IR that is automatically optimized (1) to mix reads and writes to the same array inside a parallel construct, and (2) to map semantically different arrays to the same memory block. The result is code similar to what imperative users would write. Our evaluation shows that our optimizations have significant impact (1.1 x -2 x) and result in performance competitive to hand-written code from challenging benchmarks, such as Rodinia's NW, LUD, Hotspot.
Original language | English |
---|---|
Title of host publication | Proceedings of SC 2022 : International Conference for High Performance Computing, Networking, Storage and Analysis |
Publisher | IEEE Computer Society Press |
Publication date | 2022 |
Pages | 1-15 |
Article number | 31 |
ISBN (Electronic) | 9781665454445 |
DOIs | |
Publication status | Published - 2022 |
Event | 2022 International Conference for High Performance Computing, Networking, Storage and Analysis, SC 2022 - Dallas, United States Duration: 13 Nov 2022 → 18 Nov 2022 |
Conference
Conference | 2022 International Conference for High Performance Computing, Networking, Storage and Analysis, SC 2022 |
---|---|
Country/Territory | United States |
City | Dallas |
Period | 13/11/2022 → 18/11/2022 |
Sponsor | ACM's Special Interest Group on High Performance Computing (SIGHPC), Association for Computing Machinery, IEEE Computer Society, IEEE's Technical Committee on High Performance Computing (TCHPC) |
Bibliographical note
Publisher Copyright:© 2022 IEEE.
Keywords
- functional programming
- GPU
- op-timizing compiler
- parallelism