Changes between Version 8 and Version 9 of Developer/Tracing


Ignore:
Timestamp:
Mar 26, 2015, 5:57:47 AM (4 years ago)
Author:
Chris Johns
Comment:

Add trace buffering support.

Legend:

Unmodified
Added
Removed
Modified
  • Developer/Tracing

    v8 v9  
    2323
    2424The RTEMS Trace Linker can be configured to generate other trace output and can be used to generate custom logs for any specific purpose. For example you could create a trace log that is just an Id and timestamp so you can get a profile of the performance of you code.
     25
     26== RTEMS Trace Using Trace Buffering ==
     27
     28RTEMS Trace Buffering is an RTEMS Trace Linker generator that traces function entry and exit calls to a statically allocated buffer. The work flow is shown in following figure:
     29
     30[[Image(rtems-trace-buffering.png, 40%, align=center)]]
     31
     32 [1]:: The user creates an RTEMS application in the normal manner as well as a Trace Linker configuration file. The configuration file specifies using the Trace Buffering generator, the functions to trace, and the default trace enable and trigger configurations. The user invokes the Trace Linker with the configuration and the normal link command line used to the link the application executable. The application ELF object files and libraries, including the RTEMS libraries are standard and do not need to be built specially.
     33
     34 [2]:: The RTEMS Trace Linker reads the user's configuration file and that results in it reading the standard Trace Buffering Configuration files installed with the RTEMS Trace Linker. The trace linker uses the target compiler and linker to create the trace enabled application executable. It wraps the functions defined in the user's configuration with code that captures trace records into the statically allocated buffer. The trace wrapper code is compiled with the target compiler and the resulting ELF object file is added to the standard link command line used to link the application and the application is re-linked using the wrapping option of the GNU linker.
     35
     36 [3]:: The trace linker creates an RTEMS ELF executable that can be run on the target hardware or simulator.
     37
     38 [4]:: The RTEMS Shell command `rtrace` provides commands to write the buffer to disk or print the trace records.
     39
     40The [wiki:Developer/Tracing/Trace_Buffering Trace Buffering] page details how to use RTEMS Trace Buffering.
    2541
    2642== RTEMS Trace Using CTF ==