SEAILGSep 26, 2023

Supersonic: Learning to Generate Source Code Optimizations in C/C++

arXiv:2309.14846v331 citationsh-index: 51
Originality Incremental advance
AI Analysis

This addresses the need for efficient, automated software optimization for developers, though it is incremental as it builds on existing neural methods for code generation.

The paper tackles the problem of automated source code optimization in C/C++ by introducing Supersonic, a neural seq2seq model that generates minor modifications to improve efficiency, which outperforms GPT-3.5-Turbo and GPT-4 on competitive programming tasks while being over 600x smaller than GPT-3.5-Turbo.

Software optimization refines programs for resource efficiency while preserving functionality. Traditionally, it is a process done by developers and compilers. This paper introduces a third option, automated optimization at the source code level. We present Supersonic, a neural approach targeting minor source code modifications for optimization. Using a seq2seq model, Supersonic is trained on C/C++ program pairs ($x_{t}$, $x_{t+1}$), where $x_{t+1}$ is an optimized version of $x_{t}$, and outputs a diff. Supersonic's performance is benchmarked against OpenAI's GPT-3.5-Turbo and GPT-4 on competitive programming tasks. The experiments show that Supersonic not only outperforms both models on the code optimization task but also minimizes the extent of the change with a model more than 600x smaller than GPT-3.5-Turbo and 3700x smaller than GPT-4.

Code Implementations1 repo
Foundations

The foundational work for this paper's niche, ranked by how specifically the neighbourhood builds on it — not by global fame.

Your Notes