Implementation of the Debugging Support for the LLVM Outlining Optimization




Abstract:
Outlining optimization has been used in compilers predominantly to decrease the code size and sometimes even to improve its efficiency. If a code segment is repeated at various places in the code, the compiler can encapsulate it into a function and then it replaces these segments with the function calls. The LLVM infrastructure supports the outlining optimization but lacks proper debugging information in such cases and an outlined function cannot be differentiated from some other compiler-generated code at debug time. This paper proposes the complete solution to this problem on three levels of abstraction: IR and Machine IR code, DWARF format, and LLDB debugger. It identifies the reason for insufficient precision of the previous debugging information and describes in detail the implementation focused on enhancing these data so that the outlined function can be exactly recognized during debugging. The implementation has been thoroughly tested through regression and custom tests and it was made publicly available. In practice, the enhanced debugging information for outlining has proven to be useful.

CITATION:

IEEE format

V. Tomašević, . Todorović, M. Vukasović, “Implementation of the Debugging Support for the LLVM Outlining Optimization,” in Sinteza 2025 - International Scientific Conference on Information Technology, Computer Science, and Data Science, Belgrade, Singidunum University, Serbia, 2025, pp. 233-240. doi:10.15308/Sinteza-2025-233-240

APA format

Tomašević, V., Todorović, ., Vukasović, M. (2025). Implementation of the Debugging Support for the LLVM Outlining Optimization. Paper presented at Sinteza 2025 - International Scientific Conference on Information Technology, Computer Science, and Data Science. doi:10.15308/Sinteza-2025-233-240

BibTeX format
Download

RefWorks Tagged format
Download