-
Code Generation for a Variety of Accelerators for a Graph DSL
Authors:
Ashwina Kumar,
M. Venkata Krishna,
Prasanna Bartakke,
Rahul Kumar,
Rajesh Pandian M,
Nibedita Behera,
Rupesh Nasre
Abstract:
Sparse graphs are ubiquitous in real and virtual worlds. With the phenomenal growth in semi-structured and unstructured data, sizes of the underlying graphs have witnessed a rapid growth over the years. Analyzing such large structures necessitates parallel processing, which is challenged by the intrinsic irregularity of sparse computation, memory access, and communication. It would be ideal if pro…
▽ More
Sparse graphs are ubiquitous in real and virtual worlds. With the phenomenal growth in semi-structured and unstructured data, sizes of the underlying graphs have witnessed a rapid growth over the years. Analyzing such large structures necessitates parallel processing, which is challenged by the intrinsic irregularity of sparse computation, memory access, and communication. It would be ideal if programmers and domain-experts get to focus only on the sequential computation and a compiler takes care of auto-generating the parallel code. On the other side, there is a variety in the number of target hardware devices, and achieving optimal performance often demands coding in specific languages or frameworks. Our goal in this work is to focus on a graph DSL which allows the domain-experts to write almost-sequential code, and generate parallel code for different accelerators from the same algorithmic specification. In particular, we illustrate code generation from the StarPlat graph DSL for NVIDIA, AMD, and Intel GPUs using CUDA, OpenCL, SYCL, and OpenACC programming languages. Using a suite of ten large graphs and four popular algorithms, we present the efficacy of StarPlat's versatile code generator.
△ Less
Submitted 4 January, 2024;
originally announced January 2024.
-
StarPlat: A Versatile DSL for Graph Analytics
Authors:
Nibedita Behera,
Ashwina Kumar,
Ebenezer Rajadurai T,
Sai Nitish,
Rajesh Pandian M,
Rupesh Nasre
Abstract:
Graphs model several real-world phenomena. With the growth of unstructured and semi-structured data, parallelization of graph algorithms is inevitable. Unfortunately, due to inherent irregularity of computation, memory access, and communication, graph algorithms are traditionally challenging to parallelize. To tame this challenge, several libraries, frameworks, and domain-specific languages (DSLs)…
▽ More
Graphs model several real-world phenomena. With the growth of unstructured and semi-structured data, parallelization of graph algorithms is inevitable. Unfortunately, due to inherent irregularity of computation, memory access, and communication, graph algorithms are traditionally challenging to parallelize. To tame this challenge, several libraries, frameworks, and domain-specific languages (DSLs) have been proposed to reduce the parallel programming burden of the users, who are often domain experts. However, existing frameworks to model graph algorithms typically target a single architecture. In this paper, we present a graph DSL, named StarPlat, that allows programmers to specify graph algorithms in a high-level format, but generates code for three different backends from the same algorithmic specification. In particular, the DSL compiler generates OpenMP for multi-core, MPI for distributed, and CUDA for many-core GPUs. Since these three are completely different parallel programming paradigms, binding them together under the same language is challenging. We share our experience with the language design. Central to our compiler is an intermediate representation which allows a common representation of the high-level program, from which individual backend code generations begin. We demonstrate the expressiveness of StarPlat by specifying four graph algorithms: betweenness centrality computation, page rank computation, single-source shortest paths, and triangle counting. We illustrate the effectiveness of our approach by comparing the performance of the generated codes with that obtained with hand-crafted library codes. We find that the generated code is competitive to library-based codes in many cases. More importantly, we show the feasibility to generate efficient codes for different target architectures from the same algorithmic specification of graph algorithms.
△ Less
Submitted 5 May, 2023;
originally announced May 2023.
-
A Note On $\ell$-Rauzy Graphs for the Infinite Fibonacci Word
Authors:
Rajavel Praveen M,
Rama R
Abstract:
The $\ell$-Rauzy graph of order $k$ for any infinite word is a directed graph in which an arc $(v_1,v_2)$ is formed if the concatenation of the word $v_1$ and the suffix of $v_2$ of length $k-\ell$ is a subword of the infinite word. In this paper, we consider one of the important aperiodic recurrent words, the infinite Fibonacci word for discussion. We prove a few basic properties of the $\ell$-Ra…
▽ More
The $\ell$-Rauzy graph of order $k$ for any infinite word is a directed graph in which an arc $(v_1,v_2)$ is formed if the concatenation of the word $v_1$ and the suffix of $v_2$ of length $k-\ell$ is a subword of the infinite word. In this paper, we consider one of the important aperiodic recurrent words, the infinite Fibonacci word for discussion. We prove a few basic properties of the $\ell$-Rauzy graph of the infinite Fibonacci word. We also prove that the $\ell$-Rauzy graphs for the infinite Fibonacci word are strongly connected.
△ Less
Submitted 27 October, 2022; v1 submitted 16 October, 2022;
originally announced October 2022.