Home / Learn / Processor Architecture / What Is a VLIW Processor?
On this page
The basic ideaHow it compares with a superscalar processorAdvantagesChallengesCompiler techniquesA brief historyWhere VLIW is usedWhy it fits embedded and parallel designsVLIW among other approachesCommon questionsRelated guidesWhat Is a VLIW Processor?
A VLIW processor relies on the compiler to pack several independent operations into one long instruction, which the hardware then executes at the same time. VLIW stands for very long instruction word. The idea is to move the work of finding parallelism out of the processor’s circuitry and into the compiler. This keeps the hardware simple and efficient. It works well where programs are regular and predictable, and it is widely used in digital signal processors and embedded systems.
The basic idea
Most programs contain operations that do not depend on each other and could be done simultaneously. Doing so, called instruction-level parallelism, makes a processor faster.
The question is who identifies those independent operations. There are two approaches.
- The hardware does it, while the program runs. This is how conventional high-performance processors work.
- The compiler does it, before the program runs. This is VLIW.
A VLIW compiler analyzes the program, decides which operations can safely run together and groups them. Each group becomes one long instruction with several slots, one for each of the processor’s execution units. The processor simply carries out what it is given.
How it compares with a superscalar processor
A superscalar, out-of-order processor examines a window of upcoming instructions as it runs, works out their dependencies, reorders them and dispatches several per cycle. That takes a large amount of sophisticated circuitry.
| Superscalar, out-of-order | VLIW | |
|---|---|---|
| Who finds parallelism | Hardware, during execution | Compiler, in advance |
| Hardware complexity | High | Low |
| Power and area | Higher | Lower |
| Adapts to run-time behavior | Yes | Limited |
| Handles unpredictable code | Well | Less well |
| Timing predictability | Variable | High |
| Dependence on compiler quality | Moderate | Very high |
Advantages
- Simple hardware. No large structures for tracking dependencies and reordering instructions.
- Low power and small area for the amount of parallelism achieved.
- Predictable timing. Execution follows the schedule the compiler fixed. This is valuable in real-time systems.
- A wider view. A compiler can analyze an entire function or program, where hardware sees only a short window of instructions.
- Efficiency on regular code. Loops with predictable structure can be scheduled very effectively.
Challenges
- Compiler difficulty. The whole approach depends on a compiler that can find parallelism well. Building one is hard.
- Unpredictable programs. A compiler cannot know which way a branch will go, or whether two memory accesses refer to the same location. Hardware can observe these at run time. For code full of such uncertainty, a static schedule is conservative.
- Code size. When a long instruction has slots that cannot be filled, they are wasted unless the encoding compresses them.
- Compatibility. A schedule is made for a particular hardware configuration. A processor with a different number of execution units may need the code recompiled.
- Variable delays. A cache miss stalls the whole long instruction, since everything in it was scheduled together.
Compiler techniques
VLIW compilers use several methods to expose parallelism.
- Scheduling across branches. The compiler identifies the most likely path through a region of code and schedules it as a unit, adding corrections for the less likely paths.
- Converting branches to conditional operations. Both outcomes are computed and the right one is selected, which removes the branch.
- Loop unrolling and software pipelining. Iterations of a loop are overlapped so that several are in progress at once.
- Speculation. Operations are moved ahead of the conditions that determine whether they are needed.
- Profile-guided optimization. The program is run on sample data to learn its typical behavior, and that information guides scheduling.
A brief history
The VLIW concept was developed in academic research in the early 1980s, and commercial minicomputers based on it appeared later that decade. They were technically notable and not commercially lasting.
The most prominent attempt in general-purpose computing was a 64-bit architecture introduced around 2001 that applied related ideas to servers. It struggled. General-purpose software is irregular and full of unpredictable branches and memory accesses, which favors the run-time approach of out-of-order processors. The compilers it needed proved very difficult to build.
VLIW found lasting success elsewhere.
Where VLIW is used
- Digital signal processors. Signal processing is dominated by regular loops over arrays of data, which compilers schedule well. Several widely used DSP families are VLIW designs.
- Media and embedded processors, for audio, video and imaging.
- Embedded and real-time systems, where low power and predictable timing matter.
- Manycore processors. Simple, efficient VLIW cores can be replicated many times on one chip.
- Binary translation systems, where software converts another architecture’s code into VLIW instructions as it runs.
Why it fits embedded and parallel designs
In these settings VLIW’s weaknesses matter less and its strengths more.
- Embedded software is compiled for a specific processor, so recompilation is no burden.
- The workloads tend to be regular and well understood.
- Power and area budgets are tight.
- Deterministic timing is often required.
When many cores are placed on one chip, the area and power of each core are multiplied. A core that achieves parallelism without heavy hardware is attractive for that reason.
VLIW among other approaches
VLIW extracts parallelism within a single stream of instructions. It is complementary to other forms.
- Vector and SIMD instructions apply one operation to many data values.
- Multicore and manycore designs run separate threads on separate cores.
A processor can use all three.
Common questions
What does VLIW stand for?
Very long instruction word. It refers to instructions that contain several operations to be executed in parallel.
Is VLIW faster than a conventional processor?
On regular, predictable code it can match the parallelism of more complex hardware with less power. On irregular general-purpose software, out-of-order processors usually perform better.
Why did VLIW not succeed in PCs and servers?
General-purpose software is hard to analyze in advance, the required compilers were difficult to build, and out-of-order processors kept improving. Compatibility with existing software also favored established architectures.