ABSTRACT
We present an extension of field analysis (sec [4]) called related field analysis which is a general technique for proving relationships between two or more fields of an object. We demonstrate the feasibility and applicability of related field analysis by applying it to the problem of removing array bounds checks. For array bounds check removal, we define a pair of related fields to be an integer field and an array field for which the integer field has a known relationship to the length of the array. This related field information can then be used to remove array bounds checks from accesses to the array field. Our results show that related field analysis can remove an average of 50% of the dynamic array bounds checks on a wide range of applications.
We describe the implementation of related field analysis in the Swift optimizing compiler for Java, as well as the optimizations that exploit the results of related field analysis.
- 1.R. Bodik, R. Gupta, and V. Sarkar. ABCD: Eliminating Array Bounds Checks on Demand. In Proceedings of the ACM SIGPLAN '00 Conference on Programming Language Design and Implementation (PLDI), pages 321-333, June 2000. Google ScholarDigital Library
- 2.Compaq Computer Corporation. Compaq Fast Virtual Machine V1.2.2-4 for Alpha. At URL http://www. compaq.com/java.Google Scholar
- 3.D. L. Detlefs, K. R. M. Leino, G. Nelson, and J. B. Saxe. Extended Static Checking. Technical Report 159, Compaq, 1998.Google Scholar
- 4.S. Ghemawat, K. H. Randall, and D. J. Scales. Field Analysis: Getting Useful and Low-cost Interprocedural Information. In Proceedings of the ACMSIGPLAN '00 Conference on Programming Language Design and Implementation (PLDI), pages 334-344, June 2000. Google ScholarDigital Library
- 5.W. Harrison. Compiler analysis for the value ranges of variables. IEEE Transactions on Software Engineering, 3(3):243- 250, May 1977.Google ScholarDigital Library
- 6.P. Kolte and M. Wolfe. Elimination of Redundant Array Subscript Range Checks. In Proceedings of the SIGPLAN '95 Conference on Program Language Design and Implementation, June 1995. Google ScholarDigital Library
- 7.V. Markstein, J. Cocke, and P. Markstein. Optimization of Range Checking. In Proceedings of the SIGPLAN '82 Symposium on Compiler Construction, June 1982. Google ScholarDigital Library
- 8.G. C. Necula. Compiling with Proofs. PhD thesis, Carnegie Mellon University, Oct. 1998. Available as tech report CMU- CS-98-154. Google ScholarDigital Library
- 9.J. R. Patterson. Accurate Static Branch Prediction by Value Range Propagation. In Proceedings of the SIGPLAN '95 Conference on Program Language Design and Implementation, pages 67-78, June 1995. Google ScholarDigital Library
- 10.R. Rugina and M. Rinard. Symbolic Bounds Analysis of Pointers, Array Indices, and Accessed Memory Regions. In Proceedings of the ACM SIGPLAN '00 Conference on Programming Language Design and Implementation (PLDI), pages 182-195, June 2000. Google ScholarDigital Library
- 11.D. J. Scales, K. H. Randall, S. Ghemawat, and J. Dean. The Swift Java Compiler: Design and Implementation. Technical Report 2000/2, Compaq Western Research Laboratory, Apr. 2000.Google Scholar
- 12.N. Suzuki and K. Ishihata. Implementation of an array bound checker. In Conference Record of the Fourth ACM Symposium on Principles of Programming Languages, pages 132- 143, Jan. 1977. Google ScholarDigital Library
- 13.Z. Xu, B. P. Miller, and T. Reps. Safety Checking of Machine Code. In Proceedings of the ACM SIGPLAN '00 Conference on Programming Language Design and Implementation (PLDI), pages 70-82, June 2000. Google ScholarDigital Library
Index Terms
- Related field analysis
Recommendations
Related field analysis
We present an extension of field analysis (sec [4]) called related field analysis which is a general technique for proving relationships between two or more fields of an object. We demonstrate the feasibility and applicability of related field analysis ...
CRB analysis of planar antenna arrays for optimizing near-field source localization
This paper focuses on the Cramér Rao bound (CRB) of the azimuth, elevation and range with planar arrays for narrowband near-field source localization, using the exact expression of the time delay. Specifically, the aim of this paper is twofold. First, ...
Performance analysis of higher order ESPRIT for localization of near-field sources
Most existing array processing techniques for estimating the directions of arrival (DOAs) or signal copy rely heavily on the plane-wave assumption of far-field sources. When the sources are located relatively close to the array, these techniques may no ...
Comments