Landing: 47f2a222ceda
Project / Subsystem
gcc / risc-v
Date
2026-04-15
Author
Bohan Lei
Commit
47f2a222ceda5f9834e0840a14cc6155f7d15190
Source
github
Perf win
Yes
Breaking
No
All attributes
- project
- gcc
- subsystem
- risc-v
- patch_id
- —
- commit_hash
- 47f2a222ceda5f9834e0840a14cc6155f7d15190
- source_type
- github
- headline
- RISC-V: Use vnsrl instruction for even-odd shuffles.
- tldr
- GCC now uses vnsrl instruction in RISC-V for even-odd shuffles, potentially improving performance versus vcompress.
- author
- Bohan Lei
- outcome
- committed
- performance_win
- true
- breaking_change
- false
- series_id
- —
- series_parts
- []
- tags
-
- • risc-v
- • optimization
- • vectorization
- • performance
- discussion_id_link
- —
- bugzilla_pr
- —
- date
- 2026-04-15T00:00:00.000Z
This change replaces the vcompress instruction with vnsrl for implementing even-odd shuffles on RISC-V. The vcompress instruction is slower, and requires a mask load, so using vnsrl should improve performance on many implementations. This optimization aligns with LLVM’s current behavior.