An empirical study of PHP feature usage: a static analysis perspective

An empirical study of PHP feature usage: a static analysis perspective
复制标题

PHP功能使用的实证研究:静态分析视角

DOI:
10.1145/2483760.2483786
复制
发表时间:
2013
期刊:
Proceedings of the 2013 International Symposium on Software Testing and Analysis
影响因子:
--
通讯作者:
J. Vinju
J. Vinju
中科院分区:
--
文献类型:
--
作者:
M. Hills;P. Klint;J. Vinju

文献摘要

被引文献

相似文献

PHP是服务器端应用程序开发的最受欢迎的语言之一。该语言具有高度的动态性,为程序员提供了大量的灵活性。但是,这些动态功能也有成本,因此很难应用标准代码分析和转换工具中使用的传统静态分析技术。作为我们为PHP创建分析工具的工作的一部分,我们已经对大量开源PHP系统进行了一项研究,研究了实际PHP程序的尺寸,实际上使用了PHP的功能,出现动态功能的频率频率,以及这些功能如何分布在组成PHP网站的文件中。我们还研究了这些动态功能的使用是真正的动态性还是在某些情况下是静态理解的,从而使我们能够确定特定的使用模式,然后可以考虑这些模式以构建更精确的工具。我们认为,这项工作将引起PHP分析工具的创建者的兴趣,并且我们提供的方法可以用于具有类似功能的其他动态语言。
PHP is one of the most popular languages for server-side application development. The language is highly dynamic, providing programmers with a large amount of flexibility. However, these dynamic features also have a cost, making it difficult to apply traditional static analysis techniques used in standard code analysis and transformation tools. As part of our work on creating analysis tools for PHP, we have conducted a study over a significant corpus of open-source PHP systems, looking at the sizes of actual PHP programs, which features of PHP are actually used, how often dynamic features appear, and how distributed these features are across the files that make up a PHP website. We have also looked at whether uses of these dynamic features are truly dynamic or are, in some cases, statically understandable, allowing us to identify specific patterns of use which can then be taken into account to build more precise tools. We believe this work will be of interest to creators of analysis tools for PHP, and that the methodology we present can be leveraged for other dynamic languages with similar features.