摘要
采用面向对象技术设计VHDL编译系统M TC,通过对VHDL语法产生式进行分析,将各语法现象以C++类的形式进行抽象分类,给出词法分析和语法分析设计策略,并针对存在于LALR(1)分析过程中的两类冲突提出解决方法.M TC编译过程中通过语法制导进行语义分析,并提出用形式化方法表示中间数据结构.配合使用F lex++与B ison++最终得到面向对象VHDL编译系统.同时提出M TC的自动测试方法.在对SPARC芯片M B 86901算法描述编译过程中,M TC的编译效率比现有编译系统提高了57%.
A HDL compiler MTC is designed by introducing the object-oriented technology into the design process. The VHDL syntax phenomena are abstracted and classified in the C+ + class form, and the design strategy of lexical analyzer and grammar analyzer is presented. The method to resolve the two kinds of conflict existing in LALR (1) analysis is discussed in this paper. Semantic analysis is performed by adopting syntax-directed translation. A formalization method is adopted to represent the intermediate data structure. The automation tool Flex + + and Bison++ are used together to generate the final object-oriented VHDL compiler. The test scheme of MTC is also presented. Compared with the existing system, the efficiency of MTC is improved 57% in the compiling process of SPARC chip MB86901 algorithmic description.
出处
《北京理工大学学报》
EI
CAS
CSCD
北大核心
2005年第12期1043-1046,共4页
Transactions of Beijing Institute of Technology
基金
国家自然科学基金资助项目(69973007)