基于GCC的抽象语法树对C++源程序结构的分析  被引量:8

Analysis of the C++ Source Program Structure Based on GCC Abstract Syntax Tree

在线阅读下载全文

作  者:王相懂[1] 张毅坤[1] 

机构地区:[1]西安理工大学计算机科学与工程学院,西安710048

出  处:《计算机工程与应用》2006年第23期97-99,105,共4页Computer Engineering and Applications

基  金:陕西省自然科学基金资助项目(编号:2001x20);陕西省教育厅科研基金资助项目(编号:00JK265)

摘  要:源程序静态信息的提取是实现对源程序静态分析的基础,提取的静态信息的完整性、信息的规范性是静态分析的关键点。文章基于GCC编译器产生的AST(AbstractSyntaxTree)中间文件,给出了一种从AST文件中提取源程序的静态信息的方法,以XML(ExtensibleMarkupLanguage)标准格式输出,最后树形化地显示出源程序的结构关系。Extracting the static information from source code is the foundation of static source code analysis.Integrality and specification of static information are the key for static analysis.This paper presents a method to extract information from AST fdes the GCC has dumped and output the information in the XML format.At last,the structure of program is displayed in tree view.

关 键 词:GCC AST XML 信息提取 静态分析 

分 类 号:TP311.5[自动化与计算机技术—计算机软件与理论]

 

参考文献:

正在载入数据...

 

二级参考文献:

正在载入数据...

 

耦合文献:

正在载入数据...

 

引证文献:

正在载入数据...

 

二级引证文献:

正在载入数据...

 

同被引文献:

正在载入数据...

 

相关期刊文献:

正在载入数据...

相关的主题
相关的作者对象
相关的机构对象