Font Size: a A A

Research And Application Of Fortran Symbol Table Construction Method Oriented To Composite Structure

Posted on:2024-05-31Degree:MasterType:Thesis
Country:ChinaCandidate:X T XuFull Text:PDF
GTID:2568306944963039Subject:Computer technology
Abstract/Summary:PDF Full Text Request
Fortran language is one of the most popular programming languages in the field of high-performance computing to date,and has wide applications in aerospace,meteorology,military industry,and other fields.However,with the increase in project scale and code complexity,code failures are constantly emerging in practical engineering,which has sparked an increasing demand for Fortran source code analysis.The symbol table system is an important component of the source code analysis process,and there is a large amount of numerical calculation process in Fortran programs,using multiple composite structure types of symbols.The existing symbol table system does not support the recognition of composite structure type symbols,and requires the combination of various types of information to form a description of composite structure type symbols,which affects the efficiency and accuracy of source code analysis.Therefore,how to design an efficient symbol table system for composite structure types has certain practical application value.This article combines the characteristics of Fortran language to design and propose a complete symbol table storage structure model and symbol attribute information derivation algorithm,introducing specific storage and representation of composite structure symbols to support the analysis of more source code defect patterns.Firstly,for the Fortran language composite structure type,a dynamic parallel scope storage structure based on multi-threaded scenarios is implemented,which can be dynamically created and destroyed during the symbol table construction process,reducing the memory consumption and space redundancy issues of composite structure symbol storage.Afterwards,an improved Knuth Morris Pratt string search algorithm and a Bloom filter optimization model were proposed to implement the derivation algorithm of composite structure symbol attribute information,in order to reduce the time consumption cost of symbol generation process and improve overall analysis efficiency.Finally,based on the research on symbol table construction methods in this article,a symbol table system for composite structure types is designed and implemented,and the application of the symbol table system in source code analysis defect detection process is explored.Experimental verification was conducted from three aspects:the completeness of symbol table functionality,performance optimization efficiency,and impact on defect detection results.The experimental results showed that(1)the symbol table system proposed in this paper can correctly derive various symbol types in the corresponding source code,with complete symbol generation function and 99.98%symbol coverage;(2)The optimization method based on composite structure type has a performance improvement of 8.35%,15.23%,and 17.56%for the construction time,memory space,and defect detection analysis processes of the symbol table system,respectively;(3)The symbol table system for composite structure types constructed based on the method in this article reduces the relative false alarm rate of code defect detection results by 7.72%compared to the symbol table system without introducing composite structure types,supporting the detection of more defects.
Keywords/Search Tags:numeral calculations, source code analysis, abstract syntax tree, dynamic parallel storage
PDF Full Text Request
Related items