EmbeddedRelated.com

RISC

Category: Architecture | Also known as: reduced instruction set computer

RISC (Reduced Instruction Set Computer) is a processor architecture philosophy that favors a small set of simple instructions, typically fixed-length, that each execute in a predictable number of clock cycles, often one on simple in-order implementations. The design trades instruction-set complexity for implementation simplicity, high clock rates, and compiler-friendly regularity.

In practice

RISC principles underpin many of the dominant embedded processor families in use today. ARM Cortex-M cores (found in STM32, nRF52, Kinetis, SAM, and many others), RISC-V cores, MIPS, and AVR all reflect RISC design to varying degrees, though some -- like AVR and certain ARM variants -- are better described as RISC-like than textbook RISC. The fixed-length or near-fixed-length instruction encoding, general-purpose register files (often 16 or 32 registers, though the exact count varies by ISA), and load/store memory model are common hallmarks you encounter when reading datasheets and writing assembly for these parts, even if individual ISAs deviate in details.

In practice, the most visible consequence of RISC design for embedded developers is the load/store architecture: arithmetic operates on registers, not directly on memory. A read-modify-write on a peripheral register requires an explicit load, modify, and store sequence rather than a single memory-operand instruction. Some RISC ISAs do include addressing modes with pre/post-increment or specialized load/store forms that blur the line slightly, but the general separation of memory access and computation holds across most RISC targets. This makes cycle counting and optimization more transparent and predictable, which matters on timing-sensitive bare-metal code.

The "reduced" label can mislead. Modern RISC ISAs like ARMv7-M (Thumb-2) and RISC-V with optional compressed and other extensions have grown to hundreds of instructions including DSP, SIMD, and floating-point variants when the full extension set is counted -- though the base ISA in each case remains comparatively small. The philosophical core -- simple base operations, regular encoding, compiler-oriented design -- remains, even if the total instruction count across optional extensions is no longer small. Comparing a Cortex-M33 instruction reference against an Intel 8088 manual (a classic CISC part covered in "Intel 8088 - A blast from the past") illustrates both how far apart the two philosophies sit and how each reflects the compiler and toolchain assumptions of its era.

Compiler toolchains for RISC targets, such as GCC and LLVM targeting ARM or RISC-V, take full advantage of the regular register file and predictable instruction latencies to produce efficient code. High-level languages including C, C++, and Rust (see "Learning Rust For Embedded Systems") are well-supported on RISC embedded targets largely because the ISA regularity simplifies code generation and optimization passes.

Discussed on EmbeddedRelated

Frequently asked

What is the practical difference between RISC and CISC for an embedded developer?
On most RISC targets you work with a load/store architecture: memory access and computation are generally separate instructions, though some ISAs include addressing modes that partially blur this boundary. Register files tend to be large (often 16-32 general-purpose registers on ARM and RISC-V, though exact counts vary). On a CISC target like x86, instructions can read, modify, and write memory in one operation and the register file is smaller and more specialized. For embedded work the difference mostly shows up in assembly code, interrupt latency analysis, and understanding what the compiler emits, rather than in day-to-day C or Rust development.
Are ARM Cortex-M cores 'pure' RISC?
They follow RISC principles -- fixed-width base encoding, general-purpose register file, load/store memory model -- but Thumb-2 includes multi-cycle instructions like LDM/STM (load/store multiple) and hardware divide on Cortex-M3 and later. Purists debate the label, but for practical purposes ARM Cortex-M is designed and optimized along RISC lines.
Does RISC mean fewer instructions in the binary?
Not necessarily. Because RISC instructions do less per instruction, a given task often requires more instructions than an equivalent CISC implementation. Code density can be lower, which is one reason ARM introduced the 16-bit Thumb encoding (and later Thumb-2, and RISC-V introduced the 'C' compressed extension) to reduce binary size on memory-constrained devices.
Is RISC-V actually RISC?
Yes. RISC-V is explicitly designed around RISC principles: a small base integer ISA (RV32I or RV64I) with fixed-width 32-bit instruction encoding, a load/store memory model, and a large general-purpose register file. Optional standard extensions (M for multiply/divide, F/D for floating-point, C for compressed 16-bit instructions, V for vector) layer additional instructions -- including variable-length encodings -- on top without altering the base philosophy.
Do RISC processors always run faster than CISC processors?
Not categorically. Early RISC research showed performance gains from simpler pipelines and higher clock rates under the assumptions of the 1980s. Modern high-end CISC processors (desktop x86) use microcode and out-of-order execution to match or exceed many RISC implementations in throughput. In the embedded space the comparison is largely irrelevant since the two camps target very different market segments; most embedded developers choose between RISC families (ARM, RISC-V, AVR, MIPS) rather than RISC vs. CISC.

Differentiators vs similar concepts

RISC is frequently contrasted with CISC (Complex Instruction Set Computer), the architecture style of x86/x86-64 and the earlier Intel 8088. CISC designs allow instructions to operate directly on memory, use variable-length encodings, and expose a smaller, less orthogonal register file; the goal was to close the semantic gap between hardware and high-level languages at a time when compilers were weak. RISC moves that complexity into the compiler and runtime, producing simpler hardware that is easier to pipeline. In practice the boundary has blurred: modern x86 CPUs decode CISC instructions into RISC-like micro-ops internally, while RISC ISAs have grown in instruction count over time.