arrow
Return

Compiler-Runtime Co-operative Chain of Verification for LLM-Based Code Optimization

delete2026-01-01
delete0
PRE
AI
H
H. Kwon *
S
Sanggyu Shin
J
J. Lee
H
Hoyun Youm
S
Seungbin Song
S
S.D. Kim
H
Hanwoong Jung
S
Seungwon Lee
H
Hanjun Kim
DOI:10.1109/CGO68049.2026.11395240delete
deleteOriginal
deleteOriginal request for help
deleteShare
deleteSave
Abstract

Abstract

En 中文
Large Language Models (LLMs) have recently shown promise in compiler optimizations such as loop vectorization and memory access restructuring. However, due to their generative nature, LLM-optimized code may contain syntax errors or semantic inconsistencies. While state-of-the-art compilers using LLMs employ symbolic verification to ensure correctness, they fail to fully utilize LLM-based optimizations due to the limited and unreliable verification coverage. This work introduces CoV, a compiler-runtime co-operative Chain of Verification framework that safely integrates LLM-based code transformations into modern compilation workflows. CoV employs a multi-stage verification pipeline that begins with lightweight static checks such as syntax validation and profiling-based checksum filtering, and then applies symbolic equivalence verification using tools like Alive2. For code fragments that cannot be statically verified, CoV inserts runtime verification mechanisms to ensure correctness during execution. These runtime checks are optimized through verification parallelization and batching to minimize overhead. This work implements a prototype CoV framework atop an LLM-based automatic vectorizer within LLVM, and evaluates it using 151 loops in the TSVC benchmark suite and three realistic applications. CoV expands vectorization coverage by 13.9% and 10.6% over LLVM and GCC -O3 vectorization, respectively. In addition, CoV successfully vectorizes loops in three realistic applications that are not handled by the -O3 vectorization.
Keywords:
Large Language Model
Code Optimization
Compiler
Verification

Journal

2
2026 IEEE/ACM INTERNATIONAL SYMPOSIUM ON CODE GENERATION AND OPTIMIZATION, CGO
IF:
0
Papers:
48
Citations:
0

Organization

S
samsung
Scholars:
8.6K
Papers: 6.4K
Citations: 8
Y
Yonsei University
Scholars:
4.8W
Papers: 4.6W
Citations: 5.2W