Some fixes for compiling on Sparc.
This commit is contained in:
parent
a0994a7d42
commit
c43b5c8f11
|
@ -65,12 +65,12 @@ typedef struct _MSVCRT_EXCEPTION_FRAME
|
||||||
#define TRYLEVEL_END 0xffffffff /* End of trylevel list */
|
#define TRYLEVEL_END 0xffffffff /* End of trylevel list */
|
||||||
|
|
||||||
#if defined(__GNUC__) && defined(__i386__)
|
#if defined(__GNUC__) && defined(__i386__)
|
||||||
|
|
||||||
inline static void call_finally_block( void *code_block, void *base_ptr )
|
inline static void call_finally_block( void *code_block, void *base_ptr )
|
||||||
{
|
{
|
||||||
__asm__ __volatile__ ("movl %1,%%ebp; call *%%eax" \
|
__asm__ __volatile__ ("movl %1,%%ebp; call *%%eax" \
|
||||||
: : "a" (code_block), "g" (base_ptr));
|
: : "a" (code_block), "g" (base_ptr));
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
static DWORD MSVCRT_nested_handler(PEXCEPTION_RECORD rec,
|
static DWORD MSVCRT_nested_handler(PEXCEPTION_RECORD rec,
|
||||||
struct __EXCEPTION_FRAME* frame,
|
struct __EXCEPTION_FRAME* frame,
|
||||||
|
@ -82,7 +82,6 @@ static DWORD MSVCRT_nested_handler(PEXCEPTION_RECORD rec,
|
||||||
*dispatch = frame;
|
*dispatch = frame;
|
||||||
return ExceptionCollidedUnwind;
|
return ExceptionCollidedUnwind;
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
/*********************************************************************
|
/*********************************************************************
|
||||||
|
|
|
@ -572,7 +572,12 @@ unsigned int _control87(unsigned int newval, unsigned int mask)
|
||||||
*/
|
*/
|
||||||
unsigned int _controlfp(unsigned int newval, unsigned int mask)
|
unsigned int _controlfp(unsigned int newval, unsigned int mask)
|
||||||
{
|
{
|
||||||
|
#ifdef __i386__
|
||||||
return _control87( newval, mask & ~_EM_DENORMAL );
|
return _control87( newval, mask & ~_EM_DENORMAL );
|
||||||
|
#else
|
||||||
|
FIXME(":Not Implemented!\n");
|
||||||
|
return 0;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
/*********************************************************************
|
/*********************************************************************
|
||||||
|
@ -699,7 +704,13 @@ LONGLONG MSVCRT_div(int num, int denom)
|
||||||
*/
|
*/
|
||||||
MSVCRT_div_t MSVCRT_div(int num, int denom)
|
MSVCRT_div_t MSVCRT_div(int num, int denom)
|
||||||
{
|
{
|
||||||
return div(num,denom);
|
div_t dt = div(num,denom);
|
||||||
|
MSVCRT_div_t ret;
|
||||||
|
ret.quot = dt.quot;
|
||||||
|
ret.rem = dt.rem;
|
||||||
|
|
||||||
|
return ret;
|
||||||
|
|
||||||
}
|
}
|
||||||
#endif /* ifdef __i386__ */
|
#endif /* ifdef __i386__ */
|
||||||
|
|
||||||
|
@ -725,7 +736,13 @@ ULONGLONG MSVCRT_ldiv(long num, long denom)
|
||||||
*/
|
*/
|
||||||
MSVCRT_ldiv_t MSVCRT_ldiv(long num, long denom)
|
MSVCRT_ldiv_t MSVCRT_ldiv(long num, long denom)
|
||||||
{
|
{
|
||||||
return ldiv(num,denom);
|
ldiv_t result = ldiv(num,denom);
|
||||||
|
|
||||||
|
MSVCRT_ldiv_t ret;
|
||||||
|
ret.quot = result.quot;
|
||||||
|
ret.rem = result.rem;
|
||||||
|
|
||||||
|
return ret;
|
||||||
}
|
}
|
||||||
#endif /* ifdef __i386__ */
|
#endif /* ifdef __i386__ */
|
||||||
|
|
||||||
|
|
|
@ -410,7 +410,7 @@ __ASM_GLOBAL_FUNC( SNOOP_Return,
|
||||||
".long " __ASM_NAME("SNOOP_DoReturn") ",0" );
|
".long " __ASM_NAME("SNOOP_DoReturn") ",0" );
|
||||||
|
|
||||||
#else /* !__i386__ */
|
#else /* !__i386__ */
|
||||||
void SNOOP_RegisterDLL(HMODULE hmod,LPCSTR name,DWORD nrofordinals) {
|
void SNOOP_RegisterDLL(HMODULE hmod,LPCSTR name,DWORD nrofordinals, DWORD dw) {
|
||||||
if (!TRACE_ON(snoop)) return;
|
if (!TRACE_ON(snoop)) return;
|
||||||
FIXME("snooping works only on i386 for now.\n");
|
FIXME("snooping works only on i386 for now.\n");
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue