On Thu, Sep 01, 2011 at 10:40:27AM +0100, Andrew Stubbs wrote:
I'm currently trying to get GCC to auto-detect what CPU to optimize for by finding out what CPU it's actually running on (the user would only have to pass -mcpu=native). It does this simply by reading /proc/cpuinfo.
The problem is finding what magic numbers correspond to what CPU. I've found the numbers for A8 and A9 empirically, but I'd like a longer list than that!
Does anybody have a list of such numbers?
Or else, perhaps people could just post any number they happen to know?
/proc/cpuinfo on the three Qualcomm MSM platforms I have convenient gives:
The Hardware string on the last one is my device tree work, it's on an MSM8660 FLUID (http://www.bsquare.com/snapdragon-mobile-development-platform.aspx)
---------------------------------------------------------------------- Processor : ARMv7 Processor rev 1 (v7l) processor : 0 BogoMIPS : 13.53
processor : 1 BogoMIPS : 13.53
Features : swp half thumb fastmult vfp edsp neon vfpv3 CPU implementer : 0x51 CPU architecture: 7 CPU variant : 0x0 CPU part : 0x04d CPU revision : 1
Hardware : QCT MSM8960 CDP Revision : 0000 Serial : 0000000000000000 ---------------------------------------------------------------------- Processor : ARMv7 Processor rev 1 (v7l) BogoMIPS : 191.69 Features : swp half thumb fastmult vfp edsp neon vfpv3 CPU implementer : 0x41 CPU architecture: 7 CPU variant : 0x0 CPU part : 0xc05 CPU revision : 1
Hardware : QCT MSM9615 CDP Revision : 0000 Serial : 0000000000000000 ---------------------------------------------------------------------- Processor : ARMv7 Processor rev 2 (v7l) processor : 0 BogoMIPS : 501.35
processor : 1 BogoMIPS : 209.30
Features : swp half thumb fastmult vfp edsp neon tls CPU implementer : 0x51 CPU architecture: 7 CPU variant : 0x0 CPU part : 0x02d CPU revision : 2
Hardware : Qualcomm MSM (Flattened Device Tree) Revision : 0000 Serial : 0000000000000000 ----------------------------------------------------------------------