주요 콘텐츠

이 페이지는 기계 번역을 사용하여 번역되었습니다. 최신 내용을 영문으로 보려면 여기를 클릭하십시오.

코드 실행 시간 프로파일링

코드 섹션의 실행 시간 프로파일을 확인하고 분석

실행 시간 프로파일링을 사용하여 다음을 수행할 수 있습니다.

  • 생성된 코드가 타깃 하드웨어의 실시간 요구 사항을 충족하는지 확인합니다.

  • 성능 향상이 필요한 코드 섹션을 확인합니다.

생성된 코드에 대한 실행 시간 메트릭을 생성하기 위해 SIL(Software-in-the-Loop), PIL(Processor-in-the-Loop) 또는 XCP 기반 외부 모드 시뮬레이션을 구성할 수 있습니다. 코드 프로파일 분석기, 코드 실행 리포트 또는 시뮬레이션 데이터 인스펙터를 사용하여 실행 시간 메트릭을 분석합니다.

코드 프로파일 분석기Analyze execution-time and stack usage profiles for generated code (R2023a 이후)

클래스

모두 확장

target.ProfilingFreezingOverheadCapture freezing and unfreezing instrumentation overhead (R2021a 이후)
target.ProfilingFunctionOverheadCapture function instrumentation overhead (R2021a 이후)
target.ProfilingTaskOverheadCapture task instrumentation overhead (R2021a 이후)
target.TimerProvide timer details for processor

객체

모두 확장

coder.profile.ExecutionTimeSetAggregate code profiling results from multiple SIL, PIL, or external mode simulations (R2023b 이후)
coder.profile.test.TestHookDefine custom callback functions for coder.profile.test.runTests (R2025a 이후)

함수

모두 확장

annotateColor profiled model components or open model with profiled components colored
displayGenerate message that describes how to open code execution profiling report
ExecutionTimeInTicksGet execution times in timer ticks for profiled section of code
ExecutionTimeInSecondsGet execution time in seconds for profiled section of code
NameGet name of profiled code section
NumberGet number that uniquely identifies profiled code section
NumCallsTotal number of calls to profiled code section
scheduleVisualize task scheduling (R2021a 이후)
SectionsGet array of coder.profile.ExecutionTimeSection objects for profiled code sections
SelfTimeInTicksGet number of timer ticks recorded for profiled code section, excluding time spent in child functions
TimeGet simulation time for code section
TimerTicksPerSecondGet and set number of timer ticks per second
TotalExecutionTimeInTicksGet total number of timer ticks recorded for profiled code section
TotalSelfTimeInTicksGet total number of timer ticks recorded for profiled code section, excluding time spent in child functions
TotalTurnaroundTimeInTicksGet total number of timer ticks between start and finish of the profiled code section over the entire simulation
TurnaroundTimeInTicksGet number of timer ticks between start and finish of the profiled code section
reportOpen code execution profiling report and specify display of time measurements
MaximumExecutionTimeCallNumGet the call number at which maximum number of timer ticks occurred
MaximumExecutionTimeInTicksGet maximum number of timer ticks for single invocation of profiled code section
MaximumSelfTimeInTicksGet the maximum number of timer ticks recorded for profiled code section, excluding time spent in child functions
MaximumTurnaroundTimeCallNum Get call number of the maximum number of timer ticks between start and finish of a single invocation of profiled code section
MaximumTurnaroundTimeInTicksGet maximum number of timer ticks between start and finish of a single invocation of profiled code section
coder.profile.test.runTestsAutomate execution-time or stack usage analysis of code generated from Simulink models or MATLAB functions (R2024a 이후)
addAggregate execution-time profiles (R2023b 이후)
addDetailsAdd text items to Code Profile Analyzer display or code profiling report (R2025a 이후)
getExtract specific execution-time profile from aggregate of profiles (R2023b 이후)
removeRemove execution-time profile from aggregate of profiles (R2023b 이후)

도움말 항목

워크플로 개요

프로파일링 구성 및 결과