Skip to content

Detailed Time break-down compilation mode #10

@rbertran

Description

@rbertran

Enable a timing mode when compiling that collects the time spent in each phase.

Regarding the breakdown, I was thinking in the following categories:

  • Application time
  • Profiler time
    • Init time (fork + first instrumentation)
    • start region of interest time (fix traps and insert calls)
    • end region of interest time (fix traps and insert calls)
  • Support library time:
    • protect time
      • protect mem, system call time
      • IO time (write regs to disk)
      • other protect time (e.g.read all registers state, etc.)
    • unprotect time
      • unprotect system call time
      • other protect time
    • sighandler time
      • IO time (write)
      • unprotect system call time
      • other sighandler time

Regarding on how to implement it:

This should a be a configuration option during the compilation (e.g. -DTIMING in cmake), so that we can remove the timing overhead when needed. We need to implement this using architecture specific low level mechanisms when possible (e.g. STCKE instructions in Z, or MFTB in POWER) to read the time. Much faster: 1 instruction vs. 1 system call . If TIMING is enabled, reports are generated in stdout by default or in a file if TIMING_REPORT_FILE environment variable is defined with a filename.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions