Sparse functional stores for imperative programs

  • Authors:
  • Bjarne Steensgaard

  • Affiliations:
  • Microsoft Research, One Microsoft Way, Redmond, WA

  • Venue:
  • IR '95 Papers from the 1995 ACM SIGPLAN workshop on Intermediate representations
  • Year:
  • 1995

Quantified Score

Hi-index 0.00

Visualization

Abstract

In recent years, the trend in program representations for imperative programs has been to make them more functional, or to make them more sparse. However, new sparse representations have been non-functional, and new functional representations have not been sparse in the presence of pointer operations. In this paper, we present a functional representation that is sparse even in the presence of pointer operations.Conventionally, a store is represented in a functional program representation by a single object—typically a mapping from locations to values. We show how such a store object may be fragmented into several objects, each representing part of the store. The result is a sparser representation, which has not only the usual benefit of directly linking producers to consumers, but which also for static program analysis often leads to smaller domains of abstract values for store objects. Store fragmentation corresponds to assignment factored SSA form (a factorization of SSA form introduced in this paper). We report on experiments with a thorough fragmentation based on a data flow points-to analysis and an intermediate level fragmentation based on an almost linear time complexity points-to analysis by type inference.