Good day everyone. I am new to the forums so I apologise in advance if I am posting in the wrong forum. I am looking to profile Android applications and collect hardware architectural counters (cache hit/miss rates, branch mispredictions, etc... as detailed as I can really) on newer mobile big.Little architecture (this is for my research project as school). I am looking to purchase a development board based on Qualcomm Snapdragon SOC:Snapdragon 888 Mobile Hardware Development Kit (https://developer.qualcomm.com/hardware/snapdragon-888-hdk). I have a question about profiling support for this SOC:
This SOC has what Qualcomm calls Kryo 680 CPU, which consists of: 1 x Kryo 680 Prime core (based on Arm Cortex-X1), 3 x Kryo 680 Gold core (based on Arm Cortex-A78), and 4 x Kryo 680 Silver core (based on Arm Cortex-A55). It says that these cores are based on Arm processors, and I was wondering if Arm-provided tools would be able to profile these cores. In particular I am looking at profiling the cores running Android 11 with Streamline Profiler of Arm Mobile Studio and later potentially Arm Development Studio. So my question is: will I be able to profile Android apps running on these cores with Streamline Profiler?
Another quick question related more to debugging hardware. The expansion board for this SOC has a 20 pin JTAG port. I know that JTAG is used for debugging and collecting traces. This is what I would be using it for. However, it is kind of throwing me off that the JTAG is on the display expansion and not on the board itself. I am new to development boards and so I am wondering if JTAG is also used for anything graphics/display/sensor related or is it just a design decision made by Qualcomm to put JTAG connector on the display expansion? Does anyone have any experience with those Qualcomm Development Kits who could shed some light on this?
I am attaching the pdf with information about 888 Development kit in question.snapdragon-888-mobile-hdk-product-brief_87-pu790-1 (2).pdf
Thank you very much,
Pavel.
Hi everyone. I am also interested in profiling applications using the same development board. While using Streamline I see the following warnings.
Warning 1: No Perf PMUs detectedCould not detect any Perf PMUs in /sys/bus/event_source/devices/ but the system contains recognised CPUs. The system may not support perf hardware counters. Check CONFIG_HW_PERF_EVENTS is set and that the PMU is configured in the target device tree.
Warning 2: Profiling SourceUsing perf API for primary data source
Warning 3: Atrace is disabledUnable to locate notify.dex
Should I be worried about these? How does this affect PMU stats capture?
Thanks,
Victor
Edit: Same error appears here but if I'm not mistaken the question is about Linux, whereas I'm interested in Android.
Some more info.
CONFIG_HW_PERF_EVENTS
This is a capture with some CPU stats (Cycles and Cache Accesses). All of them have values.
This is another capture where Thermal Throttling Stats have been added in the list. All the CPU stats are zero now. This happens when I add other stats as well (e.g., CPU Clock from Perf Software).
Is this behaviour expected?
Hi torvik - leaving aside the warning for a second, is the main issue that counter values appear to disappear when certain other counters are selected?Assuming that is the case, can you tell me what combinations seem to work / not work? If you stop the capture and let the analysis complete, do you see the missing data now?What device is this and is it stock or rooted?The warnings are most likely because the device has something like /sys/bus/event_source/devices/armv8_pmu generic entry rather than per cpu specific entries and usually can be ignored.
/sys/bus/event_source/devices/armv8_pmu
Hi Ben.
Ben Gainey said:Assuming that is the case, can you tell me what combinations seem to work / not work?
Some counters are always zero. There aren't any concrete combinations that always work or always don't work. It seemed that adding thermal stats or perf stats resulted in the other counters being zero. However, as you can see in this screenshot having thermal stats and CPU stats works fine.
Ben Gainey said:If you stop the capture and let the analysis complete, do you see the missing data now?
I tried again with more stats. Again some of them are zero, even if I let the analysis finish. (Screenshot)
Ben Gainey said:What device is this and is it stock or rooted?
Same as the thread starter. Qualcomm Snapdragon 888 Mobile Hardware Development Kit.
I also get the following error after the analysis is done.
Arm Processor PMU counters not configuredArm Processor PMU event counters have been detected, however the event counters are reading zeroes. Event counters include those counters listed in the counter configuration options dialog under the core name but exclude the cycle counter (Clock:Cycles) as it is controlled by a dedicated counter. It is possible that the PMU configuration bit DBGEN has not been enabled, and counter values subsequently will always read as zero. Alternatively, on it may be that the target kernel has not been configured to enable perf hardware counters. To remedy, please update your firmware or Linux kernel to enable DBGEN and/or CONFIG_HW_PERF_EVENTS. If a device tree is used it is also possible that the PMU entries are missing in the device tree. If this is the case please contact your vendor for a patch.
Thanks, can you open a support case via the link on https://developer.arm.com/All%20Support%20Services and attach a capture with the missing counters so that i can examine the data inside.You can menu-click on a capture in the list of captures in Streamline, and use the Export option from the popup menu to create a zip file of the capture containing just the relevant data.
Thanks Ben. I created a case named "ARM Streamline: Stats are zero".