mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-03 15:53:54 -06:00
bsd port (Markus Niemisto)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@800 c046a42c-6fe2-441c-8c8c-71466251a162
This commit is contained in:
parent
fd872598d8
commit
7d3505c55a
9 changed files with 111 additions and 16 deletions
|
@ -1938,6 +1938,24 @@ void OPPROTO op_fldcw_A0(void)
|
|||
int rnd_type;
|
||||
env->fpuc = lduw((void *)A0);
|
||||
/* set rounding mode */
|
||||
#ifdef _BSD
|
||||
switch(env->fpuc & RC_MASK) {
|
||||
default:
|
||||
case RC_NEAR:
|
||||
rnd_type = FP_RN;
|
||||
break;
|
||||
case RC_DOWN:
|
||||
rnd_type = FP_RM;
|
||||
break;
|
||||
case RC_UP:
|
||||
rnd_type = FP_RP;
|
||||
break;
|
||||
case RC_CHOP:
|
||||
rnd_type = FP_RZ;
|
||||
break;
|
||||
}
|
||||
fpsetround(rnd_type);
|
||||
#else
|
||||
switch(env->fpuc & RC_MASK) {
|
||||
default:
|
||||
case RC_NEAR:
|
||||
|
@ -1954,6 +1972,7 @@ void OPPROTO op_fldcw_A0(void)
|
|||
break;
|
||||
}
|
||||
fesetround(rnd_type);
|
||||
#endif
|
||||
}
|
||||
|
||||
void OPPROTO op_fclex(void)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue