crc32: Remove unnecessary masking
This commit is contained in:
parent
bcde135c23
commit
bb203429c6
1 changed files with 4 additions and 4 deletions
|
@ -57,18 +57,18 @@ bool CRC32Variant(ArmTranslatorVisitor& v, Cond cond, Imm<2> sz, Reg n, Reg d, R
|
||||||
if (type == CRCType::ISO) {
|
if (type == CRCType::ISO) {
|
||||||
switch (sz.ZeroExtend()) {
|
switch (sz.ZeroExtend()) {
|
||||||
case 0b00:
|
case 0b00:
|
||||||
return v.ir.CRC32ISO8(accumulator, v.ir.And(data, v.ir.Imm32(0xFF)));
|
return v.ir.CRC32ISO8(accumulator, data);
|
||||||
case 0b01:
|
case 0b01:
|
||||||
return v.ir.CRC32ISO16(accumulator, v.ir.And(data, v.ir.Imm32(0xFFFF)));
|
return v.ir.CRC32ISO16(accumulator, data);
|
||||||
case 0b10:
|
case 0b10:
|
||||||
return v.ir.CRC32ISO32(accumulator, data);
|
return v.ir.CRC32ISO32(accumulator, data);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
switch (sz.ZeroExtend()) {
|
switch (sz.ZeroExtend()) {
|
||||||
case 0b00:
|
case 0b00:
|
||||||
return v.ir.CRC32Castagnoli8(accumulator, v.ir.And(data, v.ir.Imm32(0xFF)));
|
return v.ir.CRC32Castagnoli8(accumulator, data);
|
||||||
case 0b01:
|
case 0b01:
|
||||||
return v.ir.CRC32Castagnoli16(accumulator, v.ir.And(data, v.ir.Imm32(0xFFFF)));
|
return v.ir.CRC32Castagnoli16(accumulator, data);
|
||||||
case 0b10:
|
case 0b10:
|
||||||
return v.ir.CRC32Castagnoli32(accumulator, data);
|
return v.ir.CRC32Castagnoli32(accumulator, data);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue