Chapter 1 What’s New for FortiOS 5.2.1 : System Features : Port Kernel Profiling
  
Port Kernel Profiling
Port kernel profiling is now supported in FortiOS 5.2. To use this feature, enter the command diagnose sys profile into the CLI. If you press enter, the following options are available:
1. set cpu mask
2. run start command
3. run stop command to read the profiling data and analyze
4. run show command to show the result
5. set cpu mask 00 to stop profiling
The following attributes are also available:
cpumask - profile which CPUs.
module - show kernel module (This is only available when the kernel is module mode).
show - show kernel profiling result.
start - start kernel profiling data.
stop - copy kernel profiling data.
sysmap - show kernel sysmap.