arrow
Return

HotLD: A Workload-Aware Method for Global Code-Layout Optimization of Shared Libraries

delete2025-12-01
delete0
PRE
AI
X
Xueqin Ning
J
Jun Ma
Z
Zhouyang Jia *
Y
Yusong Tan
J
Jie Yu
P
Pan Dong
J
J. Wang
L
Lianghao Shen
DOI:10.1145/3769310delete
deleteOriginal
deleteOriginal request for help
deleteShare
deleteSave
Abstract

Abstract

En 中文
Dynamic linking is an important technique in the process of software development. While dynamic linking can save memory and enhance maintainability, it also incurs performance overhead and hinders the application of profile-guided code layout optimization techniques to third-party libraries. Existing works (such as BOLT) can solve the problem by generating optimized versions of shared libraries for a given workload. Online PGO methods (such as OCOLOS) can further support on-the-fly code replacement to adapt to workload changes. These methods, however, are limited in several aspects: (1) hard to perform global optimization, (2) high memory consumption and performance overhead, and (3) limited usage scenarios. To address these issues, we propose HoTLD, a workload-aware method for global code-layout optimization of shared libraries. HoTLD can improve the performance of shared libraries while introducing limited performance and memory overhead. The core idea behind HoTLD is to create dedicated code copies for each typical application workload during the offline phase, and perform global optimization according to workload characteristics. At runtime, HoTLD monitors the running workload of the target program, then dynamically selects and links an appropriate code copy. We conducted experiments using real-world applications to evaluate the effectiveness and efficiency of HoTLD. The results demonstrate that HoTLD can improve their performance (up to 22.37%) with limited performance overhead (at the millisecond level). Compared with existing works, HoTLD uses 1%-46% memory to support 2x-9x workloads.
Keywords:
Dynamic linking
shared library
profile-guided optimization
workload-aware

Journal

A
ACM Transactions on Architecture and Code Optimization
IF:
1.8
Papers:
96
Citations:
1.1K

Organization

N
national university of defense technology - china
Scholars:
1.8W
Papers: 1.4W
Citations: 9