Retrieval Method of Static Code Information for Multi-Language

PANG Long,WANG Tian-tian,SU Xiao-hong,MA Pei-jun
2011-01-01
Abstract:There are many requirements for the multilanguage static information retrieval,and it is wasteful and complex to build specific front end for each language.So to meet the need and conquer the weakness we present a method based on GCC source code change to provide a uniform interface for retrieval.According to the static information type and the GCC inside mechanism,this method integrates the specific hook point with the GCC's internal functions to gather the needed.The details to be collected include: the type and function declaration,the statements traverse and the uniform multilanguage middle-representation.The reusability of this method reduces the duplicated cost of the construction for each language.The comparison experiments shows that this method can efficiently and robustly parse multilanguage and be directly applied to large-scale open source code to retrieve the static information.
What problem does this paper attempt to address?