ARM CPUs can be broadly divided into three profiles – Application profile, Real-time profile and Microcontroller profile. The Application profile is meant for high performance application processors like those used in smartphones. The Real-time profile is for real-time embedded systems that need deterministic timing behavior. The Microcontroller profile covers the microcontroller market and aims to provide an optimal solution for cost sensitive and power constrained embedded applications.
Within the Microcontroller profile, there are two sub-profiles – armv7-m and armv7e-m. Both are 32-bit architectures built on the ARMv7-M architecture. The main difference between them is in the supported instruction sets.
The armv7-m architecture is meant for embedded microcontrollers that require high performance and low cost. It includes Thumb-2 technology for improved code density. The key features of armv7-m are:
- 32-bit architecture with Thumb-2 instruction set
- 3-stage pipeline allowing single cycle execution
- Low interrupt latency
- Extensive debug support with Embedded Trace Macrocell (ETM)
- Memory Protection Unit (MPU) for system security
- Wake-up Interrupt Controller (WIC) to wake up the core on interrupt
- Support for Cortex Microcontroller Software Interface Standard (CMSIS) software framework
The armv7-m profile supports a baseline instruction set consisting mainly of Thumb-2 instructions. Some key supported instructions are:
- 32-bit Thumb-2 instructions for arithmetic, logical, branch and load/store operations
- Hardware integer divide instructions
- Saturating arithmetic instructions for DSP-like operations
- SIMD instructions operating on 8/16-bit data
- Bit-field manipulation instructions
- Exclusive access instructions for semaphores
- Coprocessor instructions for lazy context save/restore
Examples of ARM Cortex-M CPUs implementing the armv7-m architecture include Cortex-M3, Cortex-M4, Cortex-M7 etc. These microcontrollers are widely used in automotive, industrial automation, IoT and consumer applications. The baseline Thumb-2 instruction set provides an optimal trade-off between performance, code density and cost for these applications.
The armv7e-m architecture builds on top of armv7-m and adds support for more advanced DSP and floating point instructions for applications requiring higher performance compute capabilities. The key features of armv7e-m are:
- All features of armv7-m architecture
- DSP instructions for 16-bit and 32-bit multiplications
- Single precision floating point unit (FPU)
- Hardware division for integers and single precision floats
- Advanced bit-field manipulation instructions
- Saturated arithmetic and rounding instructions
The armv7e-m profile incorporates all instructions available in the armv7-m Thumb-2 baseline instruction set. Additionally, it supports the following advanced instruction set extensions:
- DSP Extension: Adds instructions for 16-bit and 32-bit multiplications, multiply-accumulate (MAC) and saturating arithmetic.
- Floating Point Extension: Adds single-precision floating point unit with support for floating point arithmetic, conversions, comparisons etc.
- Divide Extension: Supports integer and floating point hardware divide.
- Bit-field Extension: Provides advanced bitfield manipulation capabilities like bit-field insert, clear, count leading zeros etc.
- Saturation Extension: Adds saturating arithmetic instructions that saturate results to minimum or maximum value on overflow or underflow.
- SIMD Extension: Adds support for SIMD operations on 8-bit and 16-bit data.
By supporting these additional extensions on top of the baseline Thumb-2 instruction set, the armv7e-m architecture provides a performance boost for more demanding embedded applications. For example, the DSP instructions significantly accelerate DSP algorithms involving math-intensive operations like filters and transforms. The floating point unit enables advanced math capabilities. The enhanced bit-field and saturating arithmetic instructions help process low-bit data efficiently. And the SIMD instructions allow more parallelism on small integer data.
Let us summarize some of the key differences between the armv7-m and armv7e-m architectures:
- Instruction set support: armv7e-m incorporates all instructions in armv7-m baseline instruction set plus additional extensions like DSP, FPU, enhanced bit manipulation etc. In contrast, armv7-m only supports the baseline Thumb-2 instruction set.
- Performance: The extended instruction set enables armv7e-m to deliver much higher performance on math-intensive workloads involving DSP, floating point and SIMD operations.
- Silicon cost: The additional hardware needed for armv7e-m like FPU and hardware divide increases silicon cost. So armv7e-m based microcontrollers are more expensive than plain armv7-m ones at same process node.
- Power consumption: The higher performance of armv7e-m leads to increased power consumption. Arm states that armv7e-m typically consumes 2-3x power compared to armv7-m.
- Code density: While armv7e-m has mostly 32-bit instructions, armv7-m uses 16-bit and 32-bit Thumb-2 instructions which provides better code density.
To summarize, armv7e-m architecture builds on top of armv7-m by adding extensions for DSP, floating point and enhanced bit manipulation. This enables significantly higher compute performance at the cost of increased silicon cost and power consumption. The plain armv7-m architecture focuses more on low cost and power efficiency for microcontroller applications not requiring the advanced capabilities of armv7e-m.
Here are some examples of ARM Cortex-M processors belonging to the armv7-m and armv7e-m architectures:
- Cortex-M7 (without FPU)
- Cortex-M33 (without FPU)
- Cortex-M7 (with FPU)
- Cortex-M33 (with FPU)
The Cortex-M7 and M33 CPUs can exist in both variants i.e. with or without floating point unit. The M7 and M33 with FPU implement the armv7e-m architecture while the ones without FPU implement the armv7-m architecture.
Here are some typical use cases where armv7-m and armv7e-m architectures are commonly used:
- Cost-sensitive microcontroller applications like home appliances, toys, metering devices etc.
- IoT endpoints like wireless sensors, home automation devices, wearables etc.
- Industrial automation and control systems
- Low-end motor control applications
- POS terminals, barcode scanners, printers
- Advanced industrial automation like robotics, inverters, servo motors
- IoT devices with analytics capabilities
- Smart home hubs and appliances
- Automotive body control modules, instrument clusters
- Drones and other robotic vehicles
- Digital signal processing algorithms
- Predictive maintenance systems
In summary, armv7e-m microcontrollers tend to target more advanced applications that can benefit from higher performance compute capabilities. The armv7-m devices are geared towards low-cost and basic embedded control applications.
The armv7e-m and armv7-m represent two tiers of 32-bit microcontroller architectures from ARM aimed at embedded applications. Arm7e-m builds on top of armv7-m by incorporating extensions for digital signal processing, floating point and enhanced bit manipulation. This enables significantly higher compute performance versus plain armv7-m, at the cost of increased silicon cost and power consumption. Arm7v-m focuses more on embedded control applications requiring optimal cost and power efficiency rather than maximum performance.
So in summary:
- armv7e-m – High performance, more expensive, power hungry. Suited for advanced embedded analytics and control.
- armv7-m – Low cost, power efficient. Targets basic embedded control applications.
The choice between the two architectures ultimately depends on the performance, power, cost and software requirements of the target application.