Main Content

ProfilerData

Data returned from profiler

Since R2020b

Description

Internal format returned by profiler and displayed by using public functions.

The Code Execution Profiling Report displays model execution profile results by task.

  • To display the profile data for a section of the model, click the membrane button  next to the report section.

  • To display the TET data for the section in the Simulation Data Inspector, click the plot time series data button .

  • To view the section in Simulink® Editor, click the link next to the expand tree button .

  • To view the lines of generated code corresponding to the section, click the expand tree button , and then click the view source button .

The Execution Profiler and the SLRT Overload Options block use different mechanisms to measure TET and do not generate identical TET values.

The maximum log file size for the profiler data is 1024 MB.

Object Functions

plotGenerate execution profiler plot
reportGenerate profiler report

Examples

collapse all

Load the application. Start the profiler. Start the application. Stop the profiler. Retrieve profile execution data. Call report and plot on the data.

  1. tg = slrealtime('TargetPC1');
    slbuild('slrt_ex_mds_and_tasks');
    load(tg,'slrt_ex_mds_and_tasks');
    startProfiler(tg);
    start(tg);
  2. stopProfiler(tg);
    stop(tg);
  3. profiler_object = getProfilerData(tg);
    Processing data on target computer, please wait ...
    Transferring data from target computer to host computer, please wait ...
    Processing data on host computer, please wait ...
     
    Code execution profiling data for model slrt_ex_mds_and_tasks.
  4. report(profiler_object);

    The code execution profiling report for the model profiles execution of each section of code.

  5. plot(profiler_object);

    The Simulation Data Inspector provides an execution profile diagram for the model.

Version History

Introduced in R2020b