Saved in:
Bibliographic Details
Main Authors: Piersall, Scott, Gao, Yang, Liu, Shenyang, Wang, Liqiang
Format: Preprint
Published: 2026
Subjects:
Online Access:https://arxiv.org/abs/2604.02398
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866918426153320448
author Piersall, Scott
Gao, Yang
Liu, Shenyang
Wang, Liqiang
author_facet Piersall, Scott
Gao, Yang
Liu, Shenyang
Wang, Liqiang
contents Message Passing Interface (MPI) is a foundational technology in high-performance computing (HPC), widely used for large-scale simulations and distributed training (e.g., in machine learning frameworks such as PyTorch and TensorFlow). However, maintaining MPI programs remains challenging due to their complex interplay among processes and the intricacies of message passing and synchronization. With the advancement of large language models like ChatGPT, it is tempting to adopt such technology for automated error detection and repair. Yet, our studies reveal that directly applying large language models (LLMs) yields suboptimal results, largely because these models lack essential knowledge about correct and incorrect usage, particularly the bugs found in MPI programs. In this paper, we design a bug detection and repair technique alongside Few-Shot Learning (FSL), Chain-of-Thought (CoT) reasoning, and Retrieval Augmented Generation (RAG) techniques in LLMs to enhance the large language model's ability to detect and repair errors. Surprisingly, such enhancements lead to a significant improvement, from 44% to 77%, in error detection accuracy compared to baseline methods that use ChatGPT directly. Additionally, our experiments demonstrate our bug referencing technique generalizes well to other large language models.
format Preprint
id arxiv_https___arxiv_org_abs_2604_02398
institution arXiv
publishDate 2026
record_format arxiv
spellingShingle Improving MPI Error Detection and Repair with Large Language Models and Bug References
Piersall, Scott
Gao, Yang
Liu, Shenyang
Wang, Liqiang
Software Engineering
Artificial Intelligence
Message Passing Interface (MPI) is a foundational technology in high-performance computing (HPC), widely used for large-scale simulations and distributed training (e.g., in machine learning frameworks such as PyTorch and TensorFlow). However, maintaining MPI programs remains challenging due to their complex interplay among processes and the intricacies of message passing and synchronization. With the advancement of large language models like ChatGPT, it is tempting to adopt such technology for automated error detection and repair. Yet, our studies reveal that directly applying large language models (LLMs) yields suboptimal results, largely because these models lack essential knowledge about correct and incorrect usage, particularly the bugs found in MPI programs. In this paper, we design a bug detection and repair technique alongside Few-Shot Learning (FSL), Chain-of-Thought (CoT) reasoning, and Retrieval Augmented Generation (RAG) techniques in LLMs to enhance the large language model's ability to detect and repair errors. Surprisingly, such enhancements lead to a significant improvement, from 44% to 77%, in error detection accuracy compared to baseline methods that use ChatGPT directly. Additionally, our experiments demonstrate our bug referencing technique generalizes well to other large language models.
title Improving MPI Error Detection and Repair with Large Language Models and Bug References
topic Software Engineering
Artificial Intelligence
url https://arxiv.org/abs/2604.02398