OSDN Git Service

130a4989f0f998bf481247af509d8ae063ce84f2
[linuxjm/LDP_man-pages.git] / draft / man3 / __setfpucw.3
1 .\" Written Sat Mar  8 10:35:08 MEZ 1997 by
2 .\" J. "MUFTI" Scheurich (mufti@csv.ica.uni-stuttgart.de)
3 .\" This page is licensed under the GNU General Public License
4 .\"
5 .\" Japanese Version Copyright (c) 1998-2000 ISHIOKA Takashi and NAKANO Takeo
6 .\"         all rights reserved.
7 .\" Translated Mon May  25 10:45:50 1998
8 .\"         by ISHIOKA Takashi
9 .\" Updated Wed Sep 20 2000 by NAKANO Takeo <nakano@apm.seikei.ac.jp>
10 .\"
11 .\"WORD:        (floating-point) exception      (浮動小数点) 例外
12 .\"WORD:        rounding                        丸め
13 .\"
14 .TH __SETFPUCW 3 1997-03-08 "Linux" "Linux Programmer's Manual"
15 .\"O .SH NAME
16 .SH 名前
17 .\"O __setfpucw \- set FPU control word on i386 architecture (obsolete)
18 __setfpucw \- i386 アーキテクチャにおける FPU
19 のコントロールワードの設定 (obsolete)
20 .\"O .SH SYNOPSIS
21 .SH 書式
22 .B #include <i386/fpu_control.h>
23 .sp
24 .BI "void __setfpucw(unsigned short " control_word );
25 .\"O .SH DESCRIPTION
26 .SH 説明
27 .\"O .BR __setfpucw ()
28 .\"O transfers
29 .\"O .I control_word
30 .\"O to the registers of the FPU (floating-point unit) on the i386 architecture.
31 .\"O This was used to control floating-point precision,
32 .\"O rounding and floating-point exceptions.
33 .BR __setfpucw ()
34 は、i386アーキテクチャにおいて
35 .I control_word
36 を FPU (floating-point unit) のレジスタに転送する。
37 これは浮動小数点演算の精度、丸め方、
38 および浮動小数点例外を制御するのに使われる。
39 .\"O .SH CONFORMING TO
40 .SH 準拠
41 .\"O This function was a nonstandard GNU extension.
42 この関数は非標準で GNU 拡張である。
43 .\"O .SH NOTES
44 .SH 注意
45 .\"O As of glibc 2.1 this function does not exist anymore.
46 .\"O There are new functions from C99, with prototypes in
47 .\"O .IR <fenv.h> ,
48 .\"O to control FPU rounding modes, like
49 .\"O .IR fegetround ,
50 .\"O .IR fesetround ,
51 .\"O and the floating-point environment, like
52 .\"O .IR fegetenv ,
53 .\"O .IR feholdexcept ,
54 .\"O .IR fesetenv ,
55 .\"O .I feupdateenv
56 .\"O and FPU exception handling, like
57 .\"O .IR feclearexcept ,
58 .\"O .IR fegetexceptflag ,
59 .\"O .IR feraiseexcept ,
60 .\"O .IR fesetexceptflag ,
61 .\"O .IR fetestexcept .
62 glibc 2.1 以降では、この関数は存在しない。
63 新たな関数群が C99 から導入された。これらのプロトタイプは
64 .I <fenv.h>
65 に置かれている。 FPU の丸めモードの制御には
66 .IR fegetround ,
67 .I fesetround
68 などが、浮動小数点関連の環境には
69 .IR fegetenv ,
70 .IR feholdexcept ,
71 .IR fesetenv ,
72 .I feupdateenv
73 などが、 FPU 例外処理には
74 .IR feclearexcept ,
75 .IR fegetexceptflag ,
76 .IR feraiseexcept ,
77 .IR fesetexceptflag ,
78 .I fetestexcept
79 などが導入された。
80 .PP
81 .\"O If direct access to the FPU control word is still needed, the
82 .\"O .B _FPU_GETCW
83 .\"O and
84 .\"O .B _FPU_SETCW
85 .\"O macros from
86 .\"O .I <fpu_control.h>
87 .\"O can be used.
88 FPU のコントロールワードへどうしても直接アクセスする必要がある場合には、
89 .I <fpu_control.h>
90
91 .B _FPU_GETCW
92 マクロと
93 .B _FPU_SETCW
94 マクロを用いることは可能である。
95 .\"O .SH EXAMPLE
96 .SH 例
97 .B __setfpucw(0x1372)
98
99 .\"O Set FPU control word on the i386 architecture to
100 .\"O .br
101 .\"O      \- extended precision
102 .\"O .br
103 .\"O      \- rounding to nearest
104 .\"O .br
105 .\"O      \- exceptions on overflow, zero divide and NaN
106 は、i386アーキテクチャにおける FPU のコントロールワードを、
107 .br
108      \- 拡張精度
109 .br
110      \- 最も近い整数へ丸める、中間の場合は偶数を選択する。
111 .br
112      \- 桁溢れ、0で除算、及び無効値(NaN)ときに例外を発生
113 .br
114 に設定する。
115 .\"O .SH "SEE ALSO"
116 .SH 関連項目
117 .BR feclearexcept (3)
118 .br
119 .I <fpu_control.h>