SOF = 0b01001
SIF = 0b10000 # 10011 also works no idea why yet
-if __name__ == '__main__':
- for SBF in range(32):
- print("mode", bin(SBF))
- m = 0b11000011
- v3 = 0b10010100 # vmsbf.m v2, v3
- v2 = 0b01000011 # v2
- RT = bmask(SBF, v3, m, zero=True)
- print(bin(v3), bin(v2), bin(RT))
- v3 = 0b10010100 # vmsbf.m v2, v3
- v2 = 0b00000011 # v2 contents
- RT = bmask(SBF, v3)
- print(bin(v3), bin(v2), bin(RT))
- v3 = 0b10010101 # vmsbf.m v2, v3
- v2 = 0b00000000 # v2
- RT = bmask(SBF, v3)
- print(bin(v3), bin(v2), bin(RT))
- v3 = 0b00000000 # vmsbf.m v2, v3
- v2 = 0b11111111 # v2
- RT = bmask(SBF, v3)
- print(bin(v3), bin(v2), bin(RT))
- print()
--- /dev/null
+from bmask import bmask
+
+if __name__ == '__main__':
+ for SBF in range(32):
+ print("mode", bin(SBF))
+ m = 0b11000011
+ v3 = 0b10010100 # vmsbf.m v2, v3
+ v2 = 0b01000011 # v2
+ RT = bmask(SBF, v3, m, zero=True)
+ print(bin(v3), bin(v2), bin(RT))
+ v3 = 0b10010100 # vmsbf.m v2, v3
+ v2 = 0b00000011 # v2 contents
+ RT = bmask(SBF, v3)
+ print(bin(v3), bin(v2), bin(RT))
+ v3 = 0b10010101 # vmsbf.m v2, v3
+ v2 = 0b00000000 # v2
+ RT = bmask(SBF, v3)
+ print(bin(v3), bin(v2), bin(RT))
+ v3 = 0b00000000 # vmsbf.m v2, v3
+ v2 = 0b11111111 # v2
+ RT = bmask(SBF, v3)
+ print(bin(v3), bin(v2), bin(RT))
+ print()