windows & zig returning of 128bit values

This commit is contained in:
Luke Boswell 2023-08-05 21:48:53 +10:00 committed by Folkert
parent 0f5ea7eeb8
commit 5cff9ac981
No known key found for this signature in database
GPG key ID: 1F17F6FFD112B97C
2 changed files with 25 additions and 3 deletions

View file

@ -985,7 +985,8 @@ impl<
let dst_reg = self.storage_manager.claim_float_reg(&mut self.buf, dst);
ASM::mov_freg64_freg64(&mut self.buf, dst_reg, CC::FLOAT_RETURN_REGS[0]);
}
LayoutRepr::I128 | LayoutRepr::U128 => {
// Note that on windows there is only 1 general return register so we can't use this optimisation
LayoutRepr::I128 | LayoutRepr::U128 if CC::GENERAL_RETURN_REGS.len() > 1 => {
let offset = self.storage_manager.claim_stack_area(dst, 16);
ASM::mov_base32_reg64(&mut self.buf, offset, CC::GENERAL_RETURN_REGS[0]);