Computing stack maps with interfaces - Inria - Institut national de recherche en sciences et technologies du numérique Accéder directement au contenu
Rapport (Rapport De Recherche) Année : 2008

Computing stack maps with interfaces

Thomas Jensen
  • Fonction : Auteur
  • PersonId : 831246
Tiphaine Turpin
  • Fonction : Auteur
  • PersonId : 841971

Résumé

Lightweigth byte code verification uses stack maps to annotate Java byte code programs with type information so that the byte code verifier (BCV) only has to check this typing, without having to do any data flow analysis. This report describes an improved analysis technique together with algorithms for optimizing the stack maps generated by the analyser. The improved BCV is based on a modified version of the abstract domain. This domain is simplified in its treatment of base values, keeping only the necessary information to ensure the memory safety property. It is richer in its representation of interface types, using the known Dedekind-MacNeille completion technique to construct abstract domain elements representing sets of interfaces. Tracking interface information allows to remove the dynamic checks at interface method invocations. We prove the memory safety property guaranteed by BCV using an operational semantics whose distinguishing feature is a low-level memory model operating on untagged 32-bit values, as opposed to the standard, higher-level memory models using tagged memory objects. For bytecode that is typable without sets of types (this includes any code compiled from Java) we show how to prune the fix-point to obtain a stack map that can be validated without the interface set computations arising from this extension. In the context of lightweight verification, this is an advantage as it does not make the verification more complex or costly. The size of the certificates is not significantly modified. Experiments show that the pruning can be done by reasonably efficient (though in theory exponential) algorithms that uses heuristics to explore the space of valid program typings from the least fixpoint generated by the analyser. Stack maps for three substantial test suites were correctly handled by the optimized (but incomplete) pruning algorithm.
Fichier principal
Vignette du fichier
PI-1879-V2.pdf (396.76 Ko) Télécharger le fichier
Origine : Fichiers produits par l'(les) auteur(s)
Loading...

Dates et versions

inria-00200724 , version 1 (21-12-2007)
inria-00200724 , version 2 (15-07-2008)

Identifiants

  • HAL Id : inria-00200724 , version 2

Citer

Frédéric Besson, Thomas Jensen, Tiphaine Turpin. Computing stack maps with interfaces. [Research Report] PI 1879, 2008, pp.39. ⟨inria-00200724v2⟩
246 Consultations
264 Téléchargements

Partager

Gmail Facebook X LinkedIn More