Elimination of redundant array subscript range checks

  • Authors:
  • Priyadarshan Kolte;Michael Wolfe

  • Affiliations:
  • Department of Computer Science and Engineering, Oregon Graduate Institute of Science & Technology;Department of Computer Science and Engineering, Oregon Graduate Institute of Science & Technology

  • Venue:
  • PLDI '95 Proceedings of the ACM SIGPLAN 1995 conference on Programming language design and implementation
  • Year:
  • 1995

Quantified Score

Hi-index 0.00

Visualization

Abstract

This paper presents a compiler optimization algorithm to reduce the run time overhead of array subscript range checks in programs without compromising safety. The algorithm is based on partial redundancy elimination and it incorporates previously developed algorithms for range check optimization. We implemented the algorithm in our research compiler, Nascent, and conducted experiments on a suite of 10 benchmark programs to obtain four results: (1) the execution overhead of naive range checking is high enough to merit optimization, (2) there are substantial differences between various optimizations, (3) loop-based optimizations that hoist checks out of loops are effective in eliminating about 98% of the range checks, and (4) more sophisticated analysis and optimization algorithms produce very marginal benefits.