mirror of
https://github.com/kanjitalk755/macemu.git
synced 2025-01-11 10:30:09 +00:00
fpclassify return type may vary
This commit is contained in:
parent
5c264434e7
commit
b90b67971c
@ -904,11 +904,19 @@ void powerpc_cpu::execute_fp_int_convert(uint32 opcode)
|
|||||||
* Rc Predicate to record CR1
|
* Rc Predicate to record CR1
|
||||||
**/
|
**/
|
||||||
|
|
||||||
|
#ifndef FPCLASSIFY_RETURN_T
|
||||||
|
#ifdef __MINGW32__
|
||||||
|
#define FPCLASSIFY_RETURN_T int
|
||||||
|
#else
|
||||||
|
#define FPCLASSIFY_RETURN_T uint8
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
template< class FP >
|
template< class FP >
|
||||||
void powerpc_cpu::fp_classify(FP x)
|
void powerpc_cpu::fp_classify(FP x)
|
||||||
{
|
{
|
||||||
uint32 c = fpscr() & ~FPSCR_FPRF_field::mask();
|
uint32 c = fpscr() & ~FPSCR_FPRF_field::mask();
|
||||||
uint8 fc = fpclassify(x);
|
FPCLASSIFY_RETURN_T fc = fpclassify(x);
|
||||||
switch (fc) {
|
switch (fc) {
|
||||||
case FP_NAN:
|
case FP_NAN:
|
||||||
c |= FPSCR_FPRF_FU_field::mask() | FPSCR_FPRF_C_field::mask();
|
c |= FPSCR_FPRF_FU_field::mask() | FPSCR_FPRF_C_field::mask();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user