Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Beginner
40 Views

command line "CPU sampling intervall modification"

Hello,
I vould like to reduce user-mode sampling period fro 10ms to 1ms, using command line.
For this, I modified this parameter using the gui, by modifying "CPU sampling intervall, ms" to 1 and pushed "get command line". I did not find any related fields in the command line.
In addition, I tested the available knobs : amplxe-cl -knob-list hotspots ->There are no knobs available for this analysis type.
Thanks for your help,
Marc

0 Kudos
6 Replies
Highlighted
Employee
40 Views

Use command line such as below example:
amplxe-cl -collect-with runss -knob interval=20 -- ./qsort
0 Kudos
Highlighted
Beginner
40 Views

Hello Peter,

thanks for the asnwer.
The collection performs well, but when I want to analyse the result, the gui does not handle it :

The data cannot be displayed: there is no viewpoint applicable for the data

regards,
Marc
0 Kudos
Highlighted
Employee
40 Views

You can use the GUI to create a custom analysis type with a modified sampling interval, and then reference the custom analysis type from the command line. If the target machine doesn't support running the GUI, you can create the custom analysis type on a different machine and copy it to the target machine (the 'Get Command Line' button will show the location of the file for custom analysis types)

Mark
0 Kudos
Highlighted
Employee
40 Views

The command can generate correct result on U2, but I don't know why it generates empty result on U5.

Mark is right.Ican create new user mode analysis typeon GUI - modify sample interval. Then run it in command line: (But it still doesn't work)

1.amplxe-cl -collect-list ; list new created analysis type, my case "custom-analysis-1 User-mode Sampling and Tracing Analysis 0"

2. amplxe-cl -collect custom-analysis-1 -- qsort.exe

3.amplxe-cl -report hotspots
Using result path `C:\temp\qsort\Debug\r002custom-analysis-1'
Executing actions 75 % Generating a report

Result directory does not contain CPU samples.
Executing actions 100 % done
Error: Error 0x40000024 (Reporter error)

So ifrun modified sample interval in command line, have to wait future releases which fix this bug.

Regards, Peter

The command can generate correct result on U2, but I don't know why it generates empty result on U5.

Mark is right.Ican create new user mode analysis typeon GUI - modify sample interval. Then run it in command line: (But it still doesn't work)

1.amplxe-cl -collect-list ; list new created analysis type, my case "custom-analysis-1 User-mode Sampling and Tracing Analysis 0"

2. amplxe-cl -collect custom-analysis-1 -- qsort.exe

3.amplxe-cl -report hotspots
Using result path `C:\temp\qsort\Debug\r002custom-analysis-1'
Executing actions 75 % Generating a report

Result directory does not contain CPU samples.
Executing actions 100 % done
Error: Error 0x40000024 (Reporter error)

So ifrun modified sample interval in command line, have to wait future releases which fix this bug.

Regards, Peter

0 Kudos
Highlighted
Employee
40 Views

There are several ways to create a custom analysis type through the GUI. One is to select an existing analysis type and use the "Copy" button in the upper left. Another way is to bring up the context menu over the list of analysis types and select "New User-mode Sampling and Tracing Analysis". With the second method, it appears the default for collecting all types of data is set to 'No' (which will not collect any data, and you will get the error you see from the hotspots report). For the sampling interval to have an effect, the "Collect CPU sampling data" needs to be set to "With stacks" or "Without stacks".

For adjusting the sampling interval I would recommend the first method - copy from the existing 'Hotspots' analysis type.
0 Kudos
Highlighted
Employee
40 Views

It works! If click on "Hotspots" on GUI, then right-click to select "Copy from Current" - so new "Hotspots 0"will becreated under "Custom Analysis", or edit it. There is no problem to use new "hotspots-0"collector in command line, also I can see report. Thank you, Mark!
0 Kudos