| |||
| Home > ARM and Thumb Instructions > Packing and unpacking instructions > BFC and BFI | |||
Bit Field Clear and Bit Field Insert. Clear adjacent bits in a register, or Insert adjacent bits from one register into another.
BFC{cond} Rd, #lsb, #width
BFI{cond} Rd, Rn, #lsb, #width
where:
condis an optional condition code (see Conditional execution).
Rdis the destination register. must
not be r15.Rd
Rnis the source register. must
not be r15.Rn
lsbis the least significant bit that is to be cleared or copied.
widthis the number of bits to be cleared or copied. must
not be 0, and (width+width)
must be less than 32.lsb
bits in width,
starting at Rd, are
replaced by lsb bits
from width, starting
at bit[0]. Other bits in Rn are
unchanged.Rd