clzw

Counts the number of 0's before the first 1 starting at bit 31 and progressing to bit 0. Accordingly, if the least-significant word is 0, the output is 32, and if the most-significant bit of the word (_i.e._, bit 31) is a 1, the output is 0.

Synopsis

clzw xd, xs1

Encoding

Type:

067111214151920310011011xd001xs1011000000000
funct7: 0110000
funct3: 001
opcode: 0011011

RISC-V Instruction Encoder/Decoder

open clzw in rvcodecjs

Availability