×

Method using a computer for automatically instrumenting a computer program for dynamic debugging

  • US 5,581,696 A
  • Filed: 05/09/1995
  • Issued: 12/03/1996
  • Est. Priority Date: 05/09/1995
  • Status: Expired due to Term
First Claim
Patent Images

1. A method using a computer for automatically instrumenting a computer program for dynamic debugging, such a computer program comprising source code written in a programming language for executing instructions on said computer, said programming language having a grammar comprising operations having an operator and at least one operand and a set of rules for relating said operations to said at least one operand, comprising the steps of:

  • providing said source code as a sequence of statements in a storage device to said computer, each such statement representing a desired instruction expressed in said programming language as one or more operations with at least one operand each;

    separating each such statement into tokens representing either said operator or said at least one operand;

    building a parse tree according to said set of rules using said tokens, said parse tree being a directed acyclic graph and comprising a plurality of nodes connected by paths organized into a hierarchy of parent nodes representing operators connected using said paths to children nodes representing operands of said operators;

    providing additional nodes to said computer for instrumenting the computer program comprising instrumentation operations required to communicate runtime conditions to an error-checking engine, said additional nodes comprising a further plurality of nodes connected by paths organized into a hierarchy of parent nodes representing instrumentation operators connected using said paths to children nodes representing instrumentation operands of said instrumentation operators;

    instrumenting said computer program by augmenting said parse tree with said additional nodes to create an instrumented parse tree for indicating that an error condition occurred in said computer program during execution using said instrumentation operations; and

    generating object code from said instrumented parse tree and storing said object code in the storage device for later execution using the error-checking engine that indicates error conditions in said computer program.

View all claims
  • 1 Assignment
Timeline View
Assignment View
    ×
    ×