Claims
- 1. A computer usable medium having computer readable code thereon, for inserting binary instrumentation code into a binary image of a subject program, the computer readable code when executed on a computer processor causing the processor to perform the steps of:
identifying a portion of the subject program into which insertion of instrumentation code is desired, the identified portion including an original prologue of a program procedure; duplicating the identified portion such that a working copy of the identified portion is formed, said duplicating including placing the working copy before the identified portion; removing instructions from the working copy such that only instructions necessary to restore calling context remains; instrumenting the identified portion; and enabling the working copy for use during exception handling of the subject program and otherwise effecting use of the instrumented identified portion in the subject program.
- 2. A computer usable medium as claimed in claim 1 further causing the processor to provide reverse instructions for reverse effecting the working copy of the identified portion.
- 3. A computer usable medium as claimed in claim 1 wherein the step of enabling the working copy includes setting constructs such that the working copy serves as a prologue and the original prologue is executed as part of a main body of the program procedure.
- 4. Computer apparatus for inserting binary instrumentation code into a binary image of a subject program comprising:
means for identifying a portion of the subject program into which insertion of instrumentation code is desired, the identified portion including an original prologue of a program procedure; means for duplicating the identified portion such that a working copy of the identified portion is formed, said duplicating including placing the working copy before the identified portion; means for removing instructions from the working copy such that only instructions necessary to restore calling context remains; means for instrumenting the identified portion; and means for enabling the working copy for use during exception handling of the subject program and otherwise effecting use of the instrumented identified portion in the subject program.
- 5. Computer apparatus as claimed in claim 4 further comprising means for providing reverse instructions for reverse effecting the working copy of the identified portion.
- 6. Computer apparatus as claimed in claim 4 wherein the means for enabling the working copy further sets constructs such that the working copy serves as a prologue and the original prologue is executed as part of a main body of the program procedure.
RELATED APPLICATION
[0001] This application is a continuation of U.S. application Ser. No. 09/410,388, filed Sep. 30, 1999, the entire teachings of which are incorporated herein by reference.
Continuations (1)
|
Number |
Date |
Country |
Parent |
09410388 |
Sep 1999 |
US |
Child |
10237449 |
Sep 2002 |
US |