Optimizing pattern matching

  • Authors:
  • Fabrice Le Fessant;Luc Maranget

  • Affiliations:
  • INRIA Roquencourt, Le Chesnay, France;INRIA Roquencourt, Le Chesnay, France

  • Venue:
  • Proceedings of the sixth ACM SIGPLAN international conference on Functional programming
  • Year:
  • 2001

Quantified Score

Hi-index 0.03

Visualization

Abstract

We present improvements to the backtracking technique of pattern-matching compilation. Several optimizations are introduced, such as commutation of patterns, use of exhaustiveness information, and control flow optimization through the use of labeled static exceptions and context information. These optimizations have been integrated in the Objective-Caml compiler. They have shown good results in increasing the speed of pattern-matching intensive programs, without increasing final code size.