×

Parallelism performance analysis based on execution trace information

  • US 6,961,925 B2
  • Filed: 04/03/2001
  • Issued: 11/01/2005
  • Est. Priority Date: 12/23/1998
  • Status: Expired due to Fees
First Claim
Patent Images

1. A computer-implemented method for analyzing trace information generated during execution of multiple threads of a software program on a first computer, the first computer having multiple processors that each have multiple protection domains that are each able to execute at least one of the multiple threads, each processor having a counter indicating a number of instruction holes during which an instruction is not executed by the processor, each protection domain having a counter indicating a number of instructions issued in the protection domain by all executing threads, the method comprising:

  • receiving an indication of trace information reflecting a series of events that occurred during the execution, each event associated with execution of one of the multiple threads by one of the protection domains of one of the processors and each event having associated values in the trace information of variables maintained by the executing software program, by the one protection domain, and/or by the one processor;

    for each of a plurality of periods of time during which the execution was occurring, determining from the trace information a number of instructions executed for the software program during the period of time by identifying multiple protection domains that each executed at least one of the multiple threads during at least a portion of the period of time;

    for each of the identified protection domains, determining a change in the value of the issued instructions counter of the protection domain during the period of time;

    determining if all of the instructions issued in the protection domain during the period of time were for one of the multiple threads;

    when it is determined that all of the instructions issued in the protection domain during the period of time were for one of the multiple threads, calculating a value for the number of instructions executed for the software program during the period of time by the protection domain to be the determined change; and

    when it is determined that all of the instructions issued in the protection domain during the period of time were not for one of the multiple threads, calculating a value for the number of instructions executed for the software program during the period of time by the protection domain to be a portion of the determined change that corresponds to a portion of the period of time during which at least one thread for the software program was executing in the protection domain; and

    determining the number of instructions executed for the software program during the period of time to be a sum of the calculated values for each of the identified protection domains; and

    determining from the trace information a number of instruction slots available for execution of the instructions of software program during the period of time by identifying processors that each executed at least one of the multiple threads during the period of time;

    for each of the identified processors, determining a change in the value of the instruction holes counter of the processor during the period of time; and

    if all of the instruction holes that occurred during the period of time were attributable to the software program, calculating a value for the number of instruction holes for the processor that are attributable to the software program during the period of time to be the determined change in the value of the instruction holes counter;

    calculating a value for the number of instruction holes that are attributable to the software program during the period of time by all of the identified processors to be a sum of the calculated values for each of the identified processors; and

    determining the number of instruction slots available for execution of the instructions of software program during the period of time to be a sum of the determined number of instructions executed for the software program during the period of time and of the calculated value for the number of instruction holes that are attributable to the software program during the period of time; and

    presenting to a user an indication of the determined number of executed instructions for each of the periods of time and an indication of the determined number of available instruction slots for each of the periods of time, wherein only one software program can execute in a protection domain at any point in time, and wherein when it is determined that all of the instructions issued in a protection domain during a period of time were not for one of the multiple threads, the calculating of a value for the number of instructions executed for the software program during the period of time by the protection domain includes;

    determining from the trace information at least one swap event that occurred in the protection domain during the period of time such that the software program is swapped into the protection domain so as to commence execution of the software program or such that the software program is swapped out of the protection domain so as to suspend execution of the software program;

    retrieving for each of the determined swap events an associated value in the trace information of the issued instructions counter of the protection domain; and

    using the retrieved associated values to calculate the value for the number of instructions executed for the software program during the period of time by the protection domain to include only increments to the issued instructions counter that occurred while the software program is swapped into the protection domain.

View all claims
  • 2 Assignments
Timeline View
Assignment View
    ×
    ×