Research on an optimization method for region-level similar code merging

On devices with limited memory and processing power (e.g., embedded systems, IoT devices), code size is crucial, which not only concerns the execution efficiency of the program but also directly affects the system's resource consumption. In current mainstream compilers, the commonly used code size optimization is mainly achieved by reducing redundant code, failing to fully use the optimization opportunities of similar code in conditional branches. To address this problem, this paper proposes a region-level similar code merging method, which is implemented in the form of Pass in LLVM compiler. It can identify and merge similar code regions in conditional branches to further reduce the code size. The method in this paper is experimented on MiBench and SPEC CPU 2006 test sets, and achieves an average of 543 bytes and a maximum of 2464 bytes code size reduction. The experimental results show that the method in this paper can effectively merge similar code and further reduce the code size.

Authors

Institutions

Publication Details

Journal
IET conference proceedings.
Published
2025-10-13
DOI
https://doi.org/10.1049/icp.2025.2876
Primary Topic
Distributed and Parallel Computing Systems
Type
article
Field-Weighted Citation Impact
0.00
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

Research on an optimization method for region-level similar code merging

Kai Nie, Chenbo Zhao, Tao Xie, Zixiao Wu et al.
IET conference proceedings.
Distributed and Parallel Computing Systems
article

Research on an optimization method for region-level similar code merging

Kai Nie, Chenbo Zhao, Tao Xie, Zixiao Wu, Han Lin
article en

Abstract

On devices with limited memory and processing power (e.g., embedded systems, IoT devices), code size is crucial, which not only concerns the execution efficiency of the program but also directly affects the system's resource consumption. In current mainstream compilers, the commonly used code size optimization is mainly achieved by reducing redundant code, failing to fully use the optimization opportunities of similar code in conditional branches. To address this problem, this paper proposes a region-level similar code merging method, which is implemented in the form of Pass in LLVM compiler. It can identify and merge similar code regions in conditional branches to further reduce the code size. The method in this paper is experimented on MiBench and SPEC CPU 2006 test sets, and achieves an average of 543 bytes and a maximum of 2464 bytes code size reduction. The experimental results show that the method in this paper can effectively merge similar code and further reduce the code size.

IET conference proceedings.Vol. 2025(23)
National Center for Supercomputing Applications (BG), Zhengzhou University (CN), National Supercomputing Center in Wuxi (CN)
Openalex Percentile: Top 66%
Distributed and Parallel Computing Systems
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.

Research on an optimization method for region-level similar code merging — Kai Nie, Chenbo Zhao, et al. · IET conference proceedings. (2025) | TGRS Research Map | TGRS