Skip to content

Commit 2a0d386

Browse files
committed
Fix fpgetprec and fpsetprec.
1 parent 2729465 commit 2a0d386

1 file changed

Lines changed: 11 additions & 4 deletions

File tree

i387/bsd_ieeefp.h

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,10 +45,14 @@
4545
* XXX: FP*FLD and FP*OFF are undocumented pollution.
4646
*/
4747

48+
/* VBS
49+
4850
#ifndef _SYS_CDEFS_H_
4951
#error this file needs sys/cdefs.h as a prerequisite
5052
#endif
5153
54+
*/
55+
5256
/*
5357
* Rounding modes.
5458
*/
@@ -106,7 +110,8 @@ typedef enum {
106110
*/
107111
#define FP_STKY_OFF 0 /* sticky flags offset */
108112

109-
#ifdef __GNUCLIKE_ASM
113+
//VBS
114+
//#ifdef __GNUCLIKE_ASM
110115

111116
#define __fldcw(addr) __asm __volatile("fldcw %0" : : "m" (*(addr)))
112117
#define __fldenv(addr) __asm __volatile("fldenv %0" : : "m" (*(addr)))
@@ -166,7 +171,8 @@ fpsetround(fp_rnd_t _m)
166171
return (_p);
167172
}
168173

169-
static __inline fp_prec_t
174+
//static __inline fp_prec_t
175+
DLLEXPORT fp_prec_t
170176
fpgetprec(void)
171177
{
172178
unsigned short _cw;
@@ -175,7 +181,8 @@ fpgetprec(void)
175181
return ((fp_prec_t)((_cw & FP_PRC_FLD) >> FP_PRC_OFF));
176182
}
177183

178-
static __inline fp_prec_t
184+
//static __inline fp_prec_t
185+
DLLEXPORT fp_prec_t
179186
fpsetprec(fp_prec_t _m)
180187
{
181188
fp_prec_t _p;
@@ -253,6 +260,6 @@ fpresetsticky(fp_except_t _m)
253260
return (_p);
254261
}
255262

256-
#endif /* __GNUCLIKE_ASM */
263+
//#endif /* __GNUCLIKE_ASM */
257264

258265
#endif /* !_MACHINE_IEEEFP_H_ */

0 commit comments

Comments
 (0)