mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 543144 - Typechecker causes assertions in softfloat. r=stejohns,dschaffe.
--HG-- extra : convert_revision : 7d2cd297ad03f3a9d1d7722027dbb1284dd49add
This commit is contained in:
parent
4d134396af
commit
87ea71a72d
@ -944,15 +944,15 @@ namespace nanojit
|
||||
#ifndef NANOJIT_64BIT
|
||||
NanoAssert(op != LIR_qcall); // qcall should only be possible on 64-bit arch
|
||||
#endif
|
||||
#if defined(NANOJIT_ARM)
|
||||
// SoftFloat: convert LIR_fcall to LIR_icall.
|
||||
if (!_config.arm_vfp && op == LIR_fcall)
|
||||
op = LIR_icall;
|
||||
#endif
|
||||
|
||||
int32_t argc = ci->count_args();
|
||||
NanoAssert(argc <= (int)MAXARGS);
|
||||
|
||||
#if defined(NANOJIT_ARM)
|
||||
if (!_config.arm_vfp && op == LIR_fcall)
|
||||
op = LIR_callh;
|
||||
#endif
|
||||
|
||||
// Allocate space for and copy the arguments. We use the same
|
||||
// allocator as the normal LIR buffers so it has the same lifetime.
|
||||
// Nb: this must be kept in sync with arg().
|
||||
@ -962,11 +962,7 @@ namespace nanojit
|
||||
// Allocate and write the call instruction.
|
||||
LInsC* insC = (LInsC*)_buf->makeRoom(sizeof(LInsC));
|
||||
LIns* ins = insC->getLIns();
|
||||
#ifndef NANOJIT_64BIT
|
||||
ins->initLInsC(op==LIR_callh ? LIR_icall : op, args2, ci);
|
||||
#else
|
||||
ins->initLInsC(op, args2, ci);
|
||||
#endif
|
||||
return ins;
|
||||
}
|
||||
|
||||
@ -2534,8 +2530,10 @@ namespace nanojit
|
||||
break;
|
||||
|
||||
case LIR_callh:
|
||||
checkLInsHasOpcode(op, 1, a, LIR_fcall);
|
||||
formals[0] = LTy_F64;
|
||||
// The operand of a LIR_callh is LIR_icall, even though the
|
||||
// function being called has a return type of LTy_F64.
|
||||
checkLInsHasOpcode(op, 1, a, LIR_icall);
|
||||
formals[0] = LTy_I32;
|
||||
break;
|
||||
|
||||
case LIR_file:
|
||||
|
@ -104,9 +104,10 @@ OPDEF(jtbl, 23, Jtbl, Void) // jump to address in table
|
||||
OPDEF(int, 24, I, I32) // constant 32-bit integer
|
||||
OPDEF(cmov, 25, Op3, I32) // conditional move
|
||||
// LIR_callh is a hack that's only used on 32-bit platforms that use SoftFloat.
|
||||
// Its operand is always a LIR_fcall, and it indicates that the 64-bit float
|
||||
// return value is being returned via two 32-bit registers. The result is
|
||||
// always used as the first operand of a LIR_qjoin.
|
||||
// Its operand is always a LIR_icall, but one that specifies a function that
|
||||
// returns a 64-bit float. It indicates that the 64-bit float return value is
|
||||
// being returned via two 32-bit integer registers. The result is always used
|
||||
// as the second operand of a LIR_qjoin.
|
||||
OPDEF(callh, 26, Op1, I32)
|
||||
|
||||
// feq though fge must only be used on float arguments. They return integers.
|
||||
|
Loading…
Reference in New Issue
Block a user