Chapter

Java's integral types in PVS

DOI: 10.1007/978-3-540-39958-2_1 In book: Formal Methods for Open Object-Based Distributed Systems, pp.1-15
Source: CiteSeer

ABSTRACT

This paper presents an extension of the standard bitvector library of the theorem prover PVS with multiplication, division
and remainder operations, together with associated results. This extension is needed to give correct semantics to Java’s integral
types in program verification. Special emphasis is put on Java’s widening and narrowing functions in relation to the newly
defined operations on bitvectors.

Full-text preview

Available from: psu.edu
  • Source
    • "The two for-loops require appropriate (in)variants (not shown). A 32- bit bounded representation for Java's numeric types has been used, see [16], in the translations of both Java and JML expressions. The semantics of 16-bit Java Card is preserved, because in the code no integer types are declared, and all casts are explicit. "
    [Show abstract] [Hide abstract] ABSTRACT: This paper presents a case study in formal specification and verification of a smart card application. The application is an electronic purse implementation, developed by the smart card producer Gemplus as a test case for formal methods for smart cards. It has been annotated (by the authors) with specifications using the Java Modeling Language (JML), a language designed to specify the functional behavior of Java classes. The reason for using JML as a specification language is that several tools are available to check (parts of) the specification w.r.t. an implementation. These tools vary in their level of automation and in the level of correctness they ensure. Several of these tools have been used for the Gemplus case study. We discuss how the usage of these di#erent tools is complementary: large parts of the specification can be checked automatically, while more precise verification methods can be used for the more intricate parts of the specification and implementation. We believe that having such a range of tools available for a single specification language is an important step towards acceptance of formal methods in industry.
    Full-text · Article · May 2004
  • Source
    • "This standard approach is not followed for operators that are explicitly defined on the bit representation of the arguments. Our approach differs from the approach used by Jacobs [16] who exclusively uses bit representations for the integer representation as well as the operator definitions. "
    [Show abstract] [Hide abstract] ABSTRACT: We present a formal model of the Java two's-complement integral arithmetics. The model directly formalizes the arithmetic operations as given in the Java Language Specification (JLS). The algebraic properties of these definitions are derived. Underspecifications and ambiguities in the JLS are pointed out and clarified. The theory is formally analyzed in Isabelle/HOL, that is, machine-checked proofs for the ring properties and divisor/remainder theorems etc. are provided. This work is suited to build the framework for machine-supported reasoning over arithmetic formulae in the context of Java source-code verification.
    Full-text · Article · Aug 2003 · Electronic Notes in Theoretical Computer Science
  • Source
    [Show abstract] [Hide abstract] ABSTRACT: We present a formal model of the Java two's-complement integral arithmetics. The model directly formalizes the arithmetic operations as given in the Java Language Specification (JLS). The algebraic prop- erties of these definitions are derived. Underspecifications and ambi- guities in the JLS are pointed out and clarified. The theory is for- mally analyzed in Isabelle/HOL, that is, machine-checked proofs for the ring properties and divisor/remainder theorems etc. are provided. This work is suited to build the framework for machine-supported rea- soning over arithmetic formulae in the context of Java source-code verification.
    Preview · Article ·
Show more