mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-10-17 16:30:30 +02:00
riscv: Implement count leading zeros.
This commit is contained in:
1 parent
a5671bc716
commit
70ff18a463
1 file changed
+7
-1
@@ -254,7 +254,13 @@ void RiscVJit::CompIR_Bits(IRInst inst) {
|
||||
break;
|
||||
|
||||
case IROp::Clz:
|
||||
CompIR_Generic(inst);
|
||||
if (cpu_info.RiscV_Zbb) {
|
||||
gpr.MapDirtyIn(inst.dest, inst.src1, MapType::AVOID_LOAD_MARK_NORM32);
|
||||
// This even sets to 32 when zero, perfect.
|
||||
CLZW(gpr.R(inst.dest), gpr.R(inst.src1));
|
||||
} else {
|
||||
CompIR_Generic(inst);
|
||||
}
|
||||
break;
|
||||
|
||||
default:
|
||||
|
||||
Reference in new issue
Block a user