Using Invariants to Optimize Formal Specifications Before Code Synthesis

Abstract

Formal specifications of required system behavior can be analyzed, verified, and validated, giving high confidence that the specification captures the desired behavior. Transferring this confidence to the system implementation depends on a formal link between requirements and implementation. The automatic generation of provably correct code provides just such a link. While optimization is usually performed on code to achieve efficiency, we propose to optimize the formal specification before generating code, thus providing optimization independent of the particular code generation method. This paper investigates the use of invariants in optimizing code generated from formal specifications in the Software Cost Reduction (SCR) tabular notation. We show that invariants: (1) provide the basis for simplifying expressions that otherwise cannot be improved using traditional compiler optimization techniques, and (2) allow detection and elimination of parts of the specification that would lead to unreachable code.

Open PDF

Document Details

Document Type
Technical Report
Publication Date
Jan 01, 2004
Accession Number
ADA465307

Entities

People

  • Elizabeth I. Leonard
  • Ralph D. Jeffords

Organizations

  • United States Naval Research Laboratory

Tags

Communities of Interest

  • Energy and Power Technologies
  • Materials and Manufacturing Processes
  • Weapons Technologies

DTIC Thesaurus Topics

  • Abstracts
  • Algorithms
  • Artificial Intelligence Computing
  • Computer Programs
  • Cost Reductions
  • Demographic Cohorts
  • Language
  • Machines
  • Military Research
  • Models
  • Notation
  • Optimization
  • Redundancy
  • Software Development
  • Specifications
  • Standards
  • Transitions

Fields of Study

  • Computer science
  • Engineering

Readers

  • Adaptive Control and Estimation with Uncertainty in Dynamic Systems.
  • Computer Science.
  • Mathematical Modeling and Probability Theory.