Skip to content

Commit

Permalink
add converting missing integer types
Browse files Browse the repository at this point in the history
  • Loading branch information
bhansconnect committed Jul 1, 2023
1 parent 3336201 commit caa3414
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions crates/compiler/gen_dev/src/generic64/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3910,21 +3910,21 @@ impl<
} else {
match (source, target) {
// -- CASTING UP --
(I8 | U8, U16 | U32 | U64) => {
(I8 | U8, U16 | U32 | U64) | (U8, I16 | I32 | I64) => {
// zero out the register
ASM::xor_reg64_reg64_reg64(buf, dst_reg, dst_reg, dst_reg);

// move the 8-bit integer
ASM::mov_reg_reg(buf, RegisterWidth::W8, dst_reg, src_reg);
}
(U16, U32 | U64) => {
(I16 | U16, U32 | U64) | (U16, I32 | I64) => {
// zero out the register
ASM::xor_reg64_reg64_reg64(buf, dst_reg, dst_reg, dst_reg);

// move the 16-bit integer
ASM::mov_reg_reg(buf, RegisterWidth::W16, dst_reg, src_reg);
}
(U32, U64) => {
(I32 | U32, U64) | (U32, I64) => {
// zero out the register
ASM::xor_reg64_reg64_reg64(buf, dst_reg, dst_reg, dst_reg);

Expand Down

0 comments on commit caa3414

Please sign in to comment.