[all-commits] [llvm/llvm-project] a1e396: [RISCV] Use switches for opcode checks in RISCVIns...
Luke Lau via All-commits
all-commits at lists.llvm.org
Wed Sep 23 04:15:16 PDT 2026
Branch: refs/heads/users/lukel97/riscv/predicate-switch
Home: https://github.com/llvm/llvm-project
Commit: a1e396f7df0b81299ca01759c98b1990d3bfc413
https://github.com/llvm/llvm-project/commit/a1e396f7df0b81299ca01759c98b1990d3bfc413
Author: Luke Lau <luke at igalia.com>
Date: 2026-09-23 (Wed, 23 Sep 2026)
Changed paths:
M llvm/lib/Target/RISCV/RISCVInstrPredicates.td
Log Message:
-----------
[RISCV] Use switches for opcode checks in RISCVInstrPredicates.td. NFC
CheckOpcode expands out to a linear search which is slow when there's lots of opcodes in the list. Using a switch statement allows a jump table to be emitted which improves compile time, since these predicates are hammered quite frequently.
Measured to reduce geomean -1.15% instructions retired on CTMark w/ a stage2 rva23u64 -O3 Clang build.
Assisted-By: Opus 5.5
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list