So, I am trying to measure power consumption of an algorithm that I have using PAPI calls and performance counters. I was able to do this on my intel skylake X86_64 processor using perf tools on ubuntu 16.04 and since this is an intel processor, I am assuming that PAPI reads from hardware counters using intel's RAPL. Although, what I actually want to measure is the power that is consumed on an ARM A9 cortex processor with armv7l architecture in a Zynq SoC which I was able to run linux on it with a kernel of some 3.x on it.
So, typically there are a lot of limitations in an embedded linux environment and is hard to "./configure" or "make" and things unless it is implemented in the kernel that is to be built. An alternative is to cross-compile PAPI for the Arm processor. I have seen a lot of posts where people were able to do it but am really not sure as to how even "./configure" is working or I mean since I am new to all of this and is being hard for me to follow up to.
After a while, with a lot of posts and looking at things, I was able to figure out how to configure but am facing issues.
I have done :
./configure --with-CPU=arm --with-arch=armv7l --with-os=linux --with-libpfm4 --with-ffsll --with-walltimer=clock_realtime --with-virtualtimer=clock_cputime_id --with-tls=__thread CC="arm-linux-gnueabi-gcc" CXX="arm-linux-gnueabi-g++" --host=arm-none-linux-gnueabi
and then make the files but am not able to understand how the entire "cross-compile configure" thing works.
When I configured it just as is with the command on my processor and for the same processor (native-compilation) with "./configure" and no funky options, it worked well and I was able to see "libpapi.a" under /usr/local/lib and all the other files. I was also able to call some PAPI functions and was able to see how many hardware counters were on my processor using PAPI but no power measurements whatsoever (Didn't know how to read the counters and all).
Is there a way to read the power consumption at all using PAPI and not involving RAPL because I don't think that is available on the ARM processor?
But now, when I am trying to configure for ARM processor, it just seems not to work at all, for me. I could use some help here. Any of it is appreciated.
Thanks