Hello,
I look for a software measurement tool or an API I can include to know my kernel power consumption during execution on GPU / linux. How can I do that? With GPUperf?
Thanks
Hi,
You can use the Power Profiling capabilities of AMD CodeXL to measure power consumed by the internal GPU of an AMD APU processor.
CodeXL's upcoming release will also support power profiling on discrete AMD GPUs.
Profiling shows the power consumed by the whole GPU and not just your specific kernel execution. If there are no other significant workloads running on the GPU then this profile can be used to give a fair estimation of your kernel's power consumption.
Note: Only recently released models of APUs and GPUs are supported:
CodeXL includes a graphic client as well as a command line tool for power profiling.
AMD CodeXL can be freely downloaded from the CodeXL web page
Sincerely,
Doron Ofek
Yes, thank you.
I've tried with CodeXL. Before running an opencl program I tried first with a small program that runs only on CPU and I dont understand why the power is 16W for the GPU and only 0.12W for the CPU... I expected to be the opposite because in that case I dont use the GPU... Is there an explanation? It is a Kaveri A10 7850K. And CodeXL Version 1.7.7300.0
Any clue, advice?
Hi,
May be I did something wrong in my configuration?
Hi,
Can you try using command line tool and let us know how these power values are appearing.
Command to collect power values using command line tool
CodeXLPowerProfile.exe -P Power -T 100 -d 50 -o /tmp/output.txt
Please use "CodeXLPowerProfile.exe -h" to know about all the options
You can try following:
regards,
Rajeeb
Hello Rajeebbarman,
Here are some results of the command
/opt/AMD/CodeXL/CodeXLPowerProfiler -P power -T 100 -d 50 -o /tmp/output_file.txt
RecordId Timestamp | pcie-ctrl-power mem-ctrl-power | total-apu-power display-ctrl-powe cpu-cu0-power | cpu-cu1-power | igpu-power |
Idle:
61 | 11:12:58:100 | 1.906 | 5.555 | 22.430 | 0.445 | 0.125 | 0.125 | 14.273 | ||
62 | 11:12:58:200 | 1.906 | 5.535 | 22.402 | 0.445 | 0.125 | 0.125 | 14.266 | ||
63 | 11:12:58:300 | 1.906 | 5.547 | 22.410 | 0.445 | 0.125 | 0.125 | 14.262 | ||
64 | 11:12:58:400 | 1.906 | 5.527 | 22.391 | 0.445 | 0.125 | 0.125 | 14.262 | ||
65 | 11:12:58:500 | 1.906 | 5.531 | 22.398 | 0.445 | 0.125 | 0.125 | 14.266 | ||
66 | 11:12:58:600 | 1.906 | 5.551 | 22.422 | 0.445 | 0.125 | 0.125 | 14.270 | ||
67 | 11:12:58:700 | 1.906 | 5.539 | 22.410 | 0.445 | 0.125 | 0.125 | 14.270 | ||
68 | 11:12:58:800 | 1.906 | 5.551 | 22.414 | 0.445 | 0.125 | 0.125 | 14.262 | ||
69 | 11:12:58:900 | 1.906 | 5.547 | 22.414 | 0.445 | 0.125 | 0.125 | 14.266 | ||
70 | 11:12:59:000 | 1.906 | 5.543 | 22.414 | 0.445 | 0.125 | 0.125 | 14.270 |
CPU:
61 | 11:46:14:100 | 1.906 | 5.516 | 22.406 | 0.445 | 0.125 | 0.125 | 14.289 | ||
62 | 11:46:14:200 | 1.906 | 5.516 | 22.410 | 0.445 | 0.125 | 0.125 | 14.293 | ||
63 | 11:46:14:300 | 1.906 | 5.516 | 22.406 | 0.445 | 0.125 | 0.125 | 14.289 | ||
64 | 11:46:14:400 | 1.906 | 5.516 | 22.406 | 0.445 | 0.125 | 0.125 | 14.289 | ||
65 | 11:46:14:500 | 1.906 | 5.523 | 22.418 | 0.445 | 0.125 | 0.125 | 14.293 | ||
66 | 11:46:14:600 | 1.906 | 5.516 | 22.410 | 0.445 | 0.125 | 0.125 | 14.293 | ||
67 | 11:46:14:700 | 1.906 | 5.516 | 22.410 | 0.445 | 0.125 | 0.125 | 14.293 | ||
68 | 11:46:14:800 | 1.906 | 5.520 | 22.414 | 0.445 | 0.125 | 0.125 | 14.293 | ||
69 | 11:46:14:900 | 1.906 | 5.516 | 22.406 | 0.445 | 0.125 | 0.125 | 14.289 | ||
70 | 11:46:15:000 | 1.906 | 5.520 | 22.410 | 0.445 | 0.125 | 0.125 | 14.289 |
GPU:
60 | 11:50:32:004 | 1.906 | 5.789 | 27.664 | 0.445 | 0.125 | 0.125 | 19.273 | ||
61 | 11:50:32:104 | 1.906 | 5.766 | 28.027 | 0.445 | 0.125 | 0.125 | 19.660 | ||
62 | 11:50:32:204 | 1.906 | 5.527 | 22.770 | 0.445 | 0.125 | 0.125 | 14.641 | ||
63 | 11:50:32:304 | 1.906 | 5.609 | 24.254 | 0.445 | 0.125 | 0.125 | 16.043 | ||
64 | 11:50:32:404 | 1.906 | 5.668 | 25.637 | 0.445 | 0.125 | 0.125 | 17.367 | ||
65 | 11:50:32:504 | 1.906 | 6.012 | 32.020 | 0.445 | 0.125 | 0.125 | 23.406 | ||
66 | 11:50:32:604 | 1.906 | 5.805 | 28.652 | 0.445 | 0.125 | 0.125 | 20.246 | ||
67 | 11:50:32:704 | 1.906 | 5.660 | 25.289 | 0.445 | 0.125 | 0.125 | 17.027 | ||
68 | 11:50:32:804 | 1.906 | 5.516 | 22.746 | 0.445 | 0.125 | 0.125 | 14.629 | ||
69 | 11:50:32:904 | 1.906 | 5.602 | 23.918 | 0.445 | 0.125 | 0.125 | 15.715 | ||
70 | 11:50:33:008 | 1.906 | 5.738 | 26.422 | 0.445 | 0.125 | 0.125 | 18.082 |
Hi,
Do you have AMD Catalyst graphics driver installed in your machine? If catalyst is not installed, low power state will not be enabled and you are expected to see more power consumption. If you haven't installed catalyst graphics driver. Please install and let us know the result.
Regards,
-Rajeeb
Hello Rajeeb,
Catalyst release seems to be 14.40.1 [Sep 2 2014] ?
I reinstall...
Regards,
Samy
HI Samy,
Can you run “clinfo” command and provide the output?
Regards,
Rajeeb
Not yet... I have troubles installing the latest Catalyst drivers (15.7) on ubuntu server x64 (14.04.3 LTS)...
System doesn't start correctly... black screen with white cursor for me...
Hi Samy,
Looks like Catalyst driver is installed now.
You can try following again:
regards,
Rajeeb
Hello,
Seems like the minimal resolution of power measurement profiling is 20ms... What is the resolution for the "timeline profiling"? Is it the same? 20ms?
Hi,
The Application Timeline Trace profile session traces OpenCL and DirectCompute API calls and their respective GPU async invocations. These are presented on a timeline scale with a fine resolution of 1 microsecond.
The timeline of the Power Profiler has a minimal resolution of 20 milliseconds as you have noted.
Doron
Hello,
On my ubuntu 14.04.1 I just updated the drivers with sudo apt-get -y install fglrx-updates and the module loaded is then fglrx 15.20.3 [Sep 8 2015]
I run latest CodeXL but I dont undestand the error message:
Regards,