Instruction
VBLENDPS
Picks each single from the first or the second source, as a bit of an immediate says, into a separate XMM or YMM destination.
- Extensions
- Forms
- 4 (4 VEX)
- Data
- Intel XED v2026.08.23
VBLENDPS picks each single of its result from one of two sources by a constant: bit i of the immediate set takes element i from the third operand, clear from the second. It is the VEX form of BLENDPS, with a separate destination and a 256-bit form that uses all eight bits of the immediate. The cases recorded on Zen 5 show both widths:
vblendps ymm1, ymm2, ymm3, 0x96took elements 1, 2, 4 and 7 from ymm3 and the rest from ymm2;vblendps xmm0, xmm13, xmmword ptr [mem], 0xEAtook elements 1 and 3 from memory: the 128-bit form reads only bits 3:0 of the immediate, and it cleared bits 128 and up of the destination.
Where the choice is made at run time, by a mask in a vector, the instruction is VBLENDVPS; there is no EVEX form of either, so code for AVX-512 selects under a mask register with VBLENDMPS.
A blend is often a shuffle
A shuffle of two vectors that leaves every element in its place is a
blend. GCC 14 and Clang 23 at -O2 with -march=x86-64-v3 compile
__builtin_shufflevector(a, b, 0, 9, 2, 11, 4, 13, 6, 15) on eight
floats to one VBLENDPS (GCC writes it with the sources swapped and the
immediate inverted, 85 against Clang’s 170). Setting element 0 of a
vector, a[0] = x, is vblendps ymm0, ymm0, ymm1, 1 in Clang, while
GCC uses VMOVSS and VINSERTF128.
Intel’s optimization manual turns the same fact to account: in the Sandy Bridge microarchitecture the shuffles run only on port 5 and the blends also on port 0, and its 8x8 transpose of singles replaces eight of twelve VSHUFPS with VBLENDPS to relieve port 5 (Section 15.11.1). AMD’s Zen 5 guide lists VBLENDPS with a latency of 1 cycle on all four vector pipes, against two pipes for VBLENDVPS.
In the optimization guide
What the optimization guide says about VBLENDPS, a line per claim. Each links to the claim in the guide, with its sources and where they differ.
Vectors
- Shuffles and lane crossing: Intel’s shuffles share one port, so blends and shuffles done by loads relieve it; Ice Lake and Golden Cove add a second, in-lane one.
Forms
| Instruction | Encoding | Requires |
|---|---|---|
VBLENDPS xmm, xmm, m128, imm8
VBLENDPS_XMMdq_XMMdq_MEMdq_IMMb | VEX.128.66.0F3A.WIG 0C /r ib | AVX |
VBLENDPS xmm, xmm, xmm, imm8
VBLENDPS_XMMdq_XMMdq_XMMdq_IMMb | VEX.128.66.0F3A.WIG 0C /r ib | AVX |
VBLENDPS ymm, ymm, m256, imm8
VBLENDPS_YMMqq_YMMqq_MEMqq_IMMb | VEX.256.66.0F3A.WIG 0C /r ib | AVX |
VBLENDPS ymm, ymm, ymm, imm8
VBLENDPS_YMMqq_YMMqq_YMMqq_IMMb | VEX.256.66.0F3A.WIG 0C /r ib | AVX |
Data flow
Where the elements of the sources go, element 0 on the right; results that depend on a control value are drawn for an example. How to read.
Example: imm8 = 0x05 (0000 0101 in binary). The wider forms go on with the next bits of imm8 for the higher elements.
Result singles 3 to 0: a3, b2, a1, b0.
Operation
What the forms do, in pseudocode that our tests run against results recorded on real processors. How to read.
for i in range(VL // 32):
if imm8 >> i & 1:
ymm1.d[i] = src3.d[i]
else:
ymm1.d[i] = ymm2.d[i]
# ymm1 is zeroed from bit VL upRun on AMD Zen 5 (EPYC 9645): 4 cases.
Operands
| Operand | Kind | Action |
|---|---|---|
VBLENDPS xmm, xmm, xmm/m128, imm8 VBLENDPS ymm, ymm, ymm/m256, imm8 | ||
xmm, ymm | explicit | write |
xmm, ymm | explicit | read |
xmm/m128, ymm/m256 | explicit | read |
imm8 | explicit | read |
Flags
None: XED records no flag that the forms test or change.
Exceptions
The exception class is XED's name for the set of exception conditions that a form follows. How to read.
- All forms
avx-type-4
Intrinsics
The C intrinsics of Clang 23.1.2 that compile to VBLENDPS, each with the form it compiles to and the Clang options it needs. The forms come from compiling every intrinsic and decoding the result with Intel XED; all intrinsics A–Z explains the method.
| Intrinsic | Compiles to |
|---|---|
_mm_blend_ps
__m128 _mm_blend_ps(__m128 V1, __m128 V2, const int M) |
|
_mm_move_ss
__m128 _mm_move_ss(__m128 __a, __m128 __b) |
|
_mm256_blend_ps
__m256 _mm256_blend_ps(__m256 V1, __m256 V2, const int M) |
|
_mm256_shuffle_f32x4
__m256 _mm256_shuffle_f32x4(__m256 A, __m256 B, const int imm) |
|
CPUID and processors
Each form belongs to an XED ISA set. A form can be used when the processor reports every CPUID bit of one of its ISA set's alternatives.
| ISA set | CPUID | Processors |
|---|---|---|
AVX | AVX | Sandy Bridge, Ivy Bridge, Haswell, Broadwell, Skylake, Comet Lake, Cannon Lake, Ice Lake (client), Tiger Lake, Alder Lake, Arrow Lake, Panther Lake, Nova Lake, Skylake-SP, Cascade Lake, Cooper Lake, Ice Lake (server), Sapphire Rapids, Emerald Rapids, Granite Rapids, Diamond Rapids, Sierra Forest, Clearwater Forest, Knights Landing, Knights Mill, Bulldozer, Piledriver, Zen, Zen+, Zen 2, Zen 3, Zen 4, Zen 5, Zen 6 |
More AVX instructions
- VADDPD
- VADDPS
- VADDSD
- VADDSS
- VADDSUBPD
- VADDSUBPS
- VANDNPD
- VANDNPS
- VANDPD
- VANDPS
- VBLENDPD
- VBLENDVPD
- VBLENDVPS
- VBROADCASTF128
- VBROADCASTSD
- VBROADCASTSS
- VCMPPD
- VCMPPS
- VCMPSD
- VCMPSS
- VCOMISD
- VCOMISS
- VCVTDQ2PD
- VCVTDQ2PS
- VCVTPD2DQ
- VCVTPD2PS
- VCVTPS2DQ
- VCVTPS2PD
- VCVTSD2SI
- VCVTSD2SS
- VCVTSI2SD
- VCVTSI2SS
- VCVTSS2SD
- VCVTSS2SI
- VCVTTPD2DQ
- VCVTTPS2DQ
- VCVTTSD2SI
- VCVTTSS2SI
- VDIVPD
- VDIVPS
Sources
- Intel XED v2026.08.23 (commit
0bcb6237345c): forms, encodings, operands, flags, exception classes, attributes, ISA sets, CPUID bits and chip model. - The CPU data of x86-64.net: Zen 3 to Zen 6, from GCC’s
-marchfeature sets and AMD’s Processor Programming References, which the page of each processor cites. - Clang's x86 intrinsic headers, LLVM 23.1.2 (commit
85ac56026243): the intrinsics, their signatures and doc comments, and the Clang of that release, which compiled each of them. - Intel 64 and IA-32 Architectures Software Developer's Manual, Volume 2 (325383-093, September 2026): Volume 2A, page 3-80 (BLENDPS)
- Intel 64 and IA-32 Architectures Software Developer's Manual, Volume 1 (253665-093, September 2026)
- Intel 64 and IA-32 Architectures Optimization Reference Manual, Volume 1 (248966-051, October 2026)
- Software Optimization Guide for the AMD Zen5 Microarchitecture (58455, rev. 1.00, August 2024), Wayback Machine copy of AMD's ZIP
The tables are derived from Intel XED, Copyright Intel Corporation, licensed under the Apache License 2.0; x86-64.net converted and reformatted them. The intrinsics and their signatures come from Clang, part of the LLVM Project, licensed under the Apache License 2.0 with LLVM Exceptions. The text is our own.