I have a model and a corresponding SIL/PIL test harness in which I have enabled the 'CodeExecutionProfiling' option in the model Configuration Parameters. If I simulate the test harness normally, the 'ExecutionTime' object is created and stored in the variable 'executionProfile'. However, when I a SIL/PIL equivalence test in Test Manager, the object is not created. How can I retrieve the 'ExecutionTime' object upon completion of my test case?
Kshitij Singh answered .
2025-11-20
% Get the ExecutionTime object
executionProfile = test.sltest_simout.executionProfile;
% Option 1: Save as a MAT file
save('executionProfile.mat','executionProfile');
% Option 2: Assign in the base workspace
assignin('base','executionProfile',executionProfile);