- 3
- 0
- 约1.39万字
- 约 5页
- 2018-12-18 发布于天津
- 举报
编译基础设施Openimpact调试信息生成的设计①.PDF
计 算 机 系 统 应 用 2012 年 第 2 1 卷 第 6 期
编译基础设施 Openimpact 调试信息生成的设计①
陈 元 1,2, 郑启龙 1,2, 陈思灵 1,2, 邱鹏飞 1,2
1( 国家高性能计算重点实验室,合肥 230026)
2( 中国科学技术大学 计算机科学与技术学院,合肥 230026)
摘 要:基于编译基础设施 Openimpact 开发 DSP 编译器的过程中,调试信息的生成是支持调试功能的必要条件。
Openimpact 本身并不支持调试信息的生成,它仅仅将调试信息从源代码携带到前端,以高级中间语言 Pcode 格
式存放。为了支持调试信息的生成,我们必须对 Openimpact 进行适当扩展。本文详细讨论了具体扩展方法,包
括调试信息从 Pcode 格式到低级中间语言 Lcode 格式的转换以及从 Lcode 格式到汇编格式的生成。
关键词:调试信息;块作用域;行号;变量
Design of Debugging Information Generation in Compiler Infrastructure Openimpact
CHEN Yuan1,2, ZHENG Qi-Long1,2, CHEN Si-Ling1,2, QIU Peng-Fei1,2
1(Key Laboratory of High Performance Computing, Hefei 230026, China)
2(School of Computer Science and Technology, University of Science and Technology of China, Hefei 230026, China)
Abstract :In the process of developping compiler for DSP based on compiler infrastructure Openimpact, the generation
of debugging information is necessary for the support of debugging. Openimpact doesn’t support the generation of
debugging information which is only carried from source code to front end, stored in the form of advanced intermediate
language Pcode. To support the generation of debugging information, it is necessary to make the corresponding
expansion on Openimpact. It is discussed in detail that the concrete methods for expansion, containing the conversion of
debugging information from Pcode to low-level intermediate language format Lcode and from Lcode format to assembly
format.
Key words :debugging information; block scope; line number; variable
1 引言 LLVM 在重用 GCC 的前端高级语言处理的同时,
DSP 编译器的开发一般利用开源的编译器基础设 采用了自创的代码优化机制,对 GCC 的不足做了大量
[1]
施 来支持新的 DSP 体系结构。当前比较常用的开源 改进,尤其使得整个程序的全局优化成为可能。Open64
编译器基础设施有 Openimpact, GCC, LLVM, Open64 开源编译器的设计结构合理,分析优化全面,是编译
等。编译器开发者应根据 DSP 的体系结构
原创力文档

文档评论(0)