Status: Implemented and tested

SoC, CPU & GPU Architecture

Modern Android devices do not contain a standalone "processor"; they run on a System-on-Chip (SoC) integrating heterogeneous CPU core clusters, a graphics processing unit (GPU), an image signal processor (ISP), and a modem into a single silicon die.

Why /proc/cpuinfo Often Omits the Commercial SoC Name

Many users expect Linux /proc/cpuinfo to print "Snapdragon 8 Gen 2" or "Google Tensor G3." In practice, standard Linux kernel headers only report generic architecture strings like AArch64 Processor rev 1 (aarch64). Until Android 12 introduced official Build.SOC_MODEL APIs, Android had no standardized OS call for SoC marketing names. Voodoo cross-references Build.SOC_MODEL, ro.soc.model, ro.board.platform, and ARM implementer/part hexadecimal IDs to reliably identify the chip.

Critical Caveat: Maximum Frequency != Sustained Frequency

Hardware specifications state the maximum burst frequency (e.g. 2.84 GHz Cortex-X1). In real-world operation, Dynamic Voltage and Frequency Scaling (DVFS) and thermal throttling governors (schedutil, ondemand) downclock cores within milliseconds to prevent silicon overheating. Voodoo reports both physical hardware limits and real-time instantaneous core clock speeds.

How Voodoo Inspects the SoC, CPU & GPU

1. Primary Call & API-Level Fallback Chain

Extracted from SocCollector.kt. Commercial models use API 31+ Build.SOC_MODEL; topology and frequencies are read directly from Linux sysfs nodes (/sys/devices/system/cpu/); and GPU details are queried via an off-screen EGL 1x1 pbuffer surface without rendering a visual view:

// Excerpt from com.tool3.hardwareinfo.categories.soc.SocCollector.kt
val socModel = if (Build.VERSION.SDK_INT >= 31 && ModernSocHelper.getSocModel() != null) {
    ModernSocHelper.getSocModel()
} else {
    SystemPropertyReader.get("ro.soc.model", "")
        .ifEmpty { SystemPropertyReader.get("ro.board.platform", "") }
        .ifEmpty { cpuInfo.hardware }
}

// Per-core scaling clock from Linux sysfs
val curFreqKhz = CpuSysfsReader.readCoreFreq(coreIndex) // /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq
val governor = CpuSysfsReader.readGovernor(coreIndex)   // /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor

// Off-screen EGL GPU Query (Compatible across all Android versions API 1-34+)
val gpuInfo = GpuInfoHelper.getGpuInfo() // eglCreatePbufferSurface, glGetString(GL_RENDERER)

2. Permission & Privilege Gate

  • /proc/cpuinfo and off-screen EGL GPU queries require zero permissions.
  • On modern Android 8.0+ (API 26+), SELinux blocks standard apps from reading /sys/devices/system/cpu/cpu*/cpufreq/scaling_cur_freq directly on some OEM kernels. When blocked, Voodoo falls back to hardware limits (cpuinfo_max_freq) or marks real-time frequency as ROOT_REQUIRED without crashing.

3. Interpretation & Normalization Logic

  • ARM Part Lookup: Voodoo parses hexadecimal ARM part numbers from /proc/cpuinfo (e.g. 0xd03 maps to ARM Cortex-A53, 0xd05 to Cortex-A55, 0xd0b to Cortex-A76, 0x092 to Samsung Exynos M4).
  • Cluster Topology: Group cores by matching maximum frequency and microarchitecture into multi-cluster summaries (e.g. Tri-Cluster: 4x Cortex-A55 @ 1.95 GHz + 2x Cortex-A75 @ 2.31 GHz + 2x Exynos M4 @ 2.73 GHz).
  • Frequency Formatting: Raw kilohertz values from sysfs are normalized into human-readable MHz or GHz.

4. Availability-State Triggers

  • Build.SOC_MODEL on Android < 12 triggers fallback to system properties; if unlisted, marked AvailabilityState.UNSUPPORTED.
  • Protected GPU frequency nodes (e.g. Adreno kgsl sysfs) inaccessible in untrusted_app domain trigger AvailabilityState.ROOT_REQUIRED.
  • EGL initialization failure triggers AvailabilityState.RETRIEVAL_FAILED.

Subsystem Field Inventory

Field ID Display Name Type Primary Source / API Min API
soc.processor_name Processor / SoC Model STRING Build.SOC_MODEL (API 31) / ro.soc.model / ro.board.platform API 1
soc.manufacturer SoC Manufacturer STRING Build.SOC_MANUFACTURER (API 31) / Silicon heuristics API 1
soc.core_count CPU Core Count INTEGER /sys/devices/system/cpu/possible / /proc/cpuinfo API 1
soc.cluster_topology Cluster Topology STRING ARM Part lookup + cpufreq cluster grouping API 1
soc.instruction_sets CPU Instruction Features STRING /proc/cpuinfo (Features / Flags) API 1
soc.gpu_vendor GPU Vendor STRING Off-screen EGL GL10.glGetString(GL_VENDOR) API 1
soc.gpu_renderer GPU Renderer STRING Off-screen EGL GL10.glGetString(GL_RENDERER) API 1
soc.opengl_version OpenGL ES Version STRING Off-screen EGL GL10.glGetString(GL_VERSION) API 1