我正在使用宏来提取第n位。我想知道如何传递价值并测试这个宏?
.macro extract_nth_bit($regD, $regS, $regT)
srl $regS, $regS, $regT
and $regD, $regS, 1
# regD contains bit position ( will contain 0x0 or 0x1 depending on nth bit being 0 or 1
# regS is the bit pattern ( source bit pattern )
# regT will be 0x0 or 0x1 ( bit position n (0-31)
.end_macro