Dynamic instrumentation event trace system and methods
First Claim
1. A system providing for dynamic instrumentation and event data collection with respect to a target program as executed by a target computer, said system comprising:
- a) a target data collection routine including a data collection buffer and wherein said target data collection routine is responsive to calls to store event data in said data collection buffer; and
b) a target driver including a trace control routine and an instrumentation routine, wherein execution of said instrumentation routine by said target computer subsequent to the loading and initial execution of said target program dynamically installs a deterministic program execution redirection instruction with respect to a named function of said target program to redirect execution of said target program by said target computer to said trace control routine, said instrumentation routine providing for the dynamic location and decoding of said named function to enable dynamic installation of said deterministic program execution redirection instruction, wherein execution of said instrumentation routine further provides, in response to a predetermined input signal provided to said target driver, for the dynamic removal of said deterministic program execution redirection instruction whereby said named function is restored to a non-instrumented state, wherein said instrumentation routine preserves an instance of said named function, wherein said trace control routine supports the collection and transfer of event data to said target data collection routine, and wherein execution of said trace control routine includes execution of said instance of said named function.
3 Assignments
0 Petitions
Accused Products
Abstract
Program code loaded for execution by a computer can be dynamically instrumented to collect event data by inserting an instruction at a trace point within the program code as loaded in a memory space of a computer, where the trace point corresponds to the beginning of a predefined function of the program selected for event tracing. The instruction provides for the direction of the execution of said computer to a function proxy routine, which includes a call to an instance of the predefined function. Event data is collected in connection with the calling of the instance of the predefined function.
-
Citations
19 Claims
-
1. A system providing for dynamic instrumentation and event data collection with respect to a target program as executed by a target computer, said system comprising:
-
a) a target data collection routine including a data collection buffer and wherein said target data collection routine is responsive to calls to store event data in said data collection buffer; and b) a target driver including a trace control routine and an instrumentation routine, wherein execution of said instrumentation routine by said target computer subsequent to the loading and initial execution of said target program dynamically installs a deterministic program execution redirection instruction with respect to a named function of said target program to redirect execution of said target program by said target computer to said trace control routine, said instrumentation routine providing for the dynamic location and decoding of said named function to enable dynamic installation of said deterministic program execution redirection instruction, wherein execution of said instrumentation routine further provides, in response to a predetermined input signal provided to said target driver, for the dynamic removal of said deterministic program execution redirection instruction whereby said named function is restored to a non-instrumented state, wherein said instrumentation routine preserves an instance of said named function, wherein said trace control routine supports the collection and transfer of event data to said target data collection routine, and wherein execution of said trace control routine includes execution of said instance of said named function. - View Dependent Claims (2, 3, 4, 5)
-
-
6. A method of dynamically instrumenting executable program code provided in the memory of a computer system, said method comprising the steps of:
-
a) dynamically provisioning a sequence of executable program code in response to a predetermined user input, wherein said sequence of executable program code is part of an executable program and wherein said step of dynamically provisioning is performed after initiation of execution of said executable program within the memory of said computer system, said dynamically provisioning including i) enabling the interception of execution of said sequence through insertion of a deterministic branch instruction at a predetermined location within said sequence; and ii) restoring said sequence by removal of said deterministic branch instruction from said predetermined location; and b) executing an event capture routine in response to interception of said sequence, wherein execution of said event capture routine enables execution of said sequence and selectively enables execution of a data collection routine to record data associated with execution of said sequence. - View Dependent Claims (7, 8, 9, 10, 11)
-
-
12. A diagnostic system supporting dynamic instrumentation of a target program executing within the memory of a computer system, said diagnostic system comprising:
-
a) a buffer providing for the storage of execution trace data reflective of the occurrence of traceable events within the execution of said target program; and b) a trace program provided and concurrently executable within the memory of said computer system, said trace program including i) a list of addresses within said target program designated as the source of traceable events; ii) a trace data collection routine executable to selectively capture and provide trace data to said buffer; iii) a dynamic patch routine executable to dynamically instrument said target program at each address of said list by establishing respective deterministic execution paths through said addresses that provide for execution of said trace data collection routine, wherein said dynamic patch routine includes a patch management routine that supports an instrumenting of said target program at a predetermined address subsequent to loading and initial execution of said target program by said computer system, and wherein said patch management routine is responsive to user provided trace commands issued with respect to said predetermined address to selectively apply and remove said instrumenting of said target program at said predetermined address; and wherein trace data is collected through a deterministic flow of execution through said target program with minimal impact on the system behavior of said target program and said computer system. - View Dependent Claims (13, 14, 15, 16, 17, 18, 19)
-
Specification