Product Documentation
Cadence SKILL Development Reference
Product Version IC23.1, June 2023

profile

profile( 
s_profileField 
) 
=> t

Description

Turns on global SKILL profiling for measuring time or memory.

The profiler is interrupt-driven. It walks the SKILL stack and records functions being executed. When unprofile or profileSummary are called, profiling is stopped. profileSummary prints a report of the time spent or memory allocated in the functions executed. Profiling time is cumulative, so you must call profileReset to reset the profiled data.

Time measurements are done with UNIX system functions that have coarse granularity at 1/60 of a second, so functions must be executed many times for the CPU times to be reasonably accurate.

SKILL Profiler is not yet supported on the Windows/Wintel platform.

Arguments

s_profileField

Can be one of the following:

'time Only time is profiled.

'realTime Profiles real (elapsed) time rather than CPU
time.

'memory Only SKILL memory allocated is profiled.

Value Returned

t

Always returns t.

Examples

profile( 'time)
for(i 1 10000 i+1)
profileSummary( ?file "/tmp/profile.results")

Related Topics

Profiler Functions

unprofile

profileReset

profileSummary


Return to top
 ⠀
X