Sun Studio 12:C 用户指南

E.1.6 浮点 (G.3.6)

E.1.6.1 (6.1.2.5) The representations and sets of values of the various types of floating-point numbers(各种类型的浮点数的表示形式和值集):

表 E–2 float

float

 

位 

32 

最小值 

1.17549435E-38 

最大值 

3.40282347E+38 

Epsilon 

1.19209290E-07 

表 E–3 double

double

 

位 

64 

最小值 

2.2250738585072014E-308 

最大值 

1.7976931348623157E+308 

Epsilon 

2.2204460492503131E-16 

表 E–4 long double

long double

 

位 

128 (SPARC)

80 (x86)

最小值 

3.362103143112093506262677817321752603E-4932 (SPARC) 

3.3621031431120935062627E-4932 (x86)

最大值 

1.189731495357231765085759326628007016E+4932 (SPARC)

1.1897314953572317650213E4932 (x86)

Epsilon 

1.925929944387235853055977942584927319E-34 (SPARC)

1.0842021724855044340075E-19 (x86)

(6.2.1.3) The direction of truncation when an integral number is converted to a floating-point number that cannot exactly represent the original value(当整数转换为不能精确地表示原始值的浮点数时截断的方向):

数舍入为可以表示的最近的值。

(6.2.1.4) The direction of truncation or rounding when a floating point number is converted to a narrower floating-point number(当浮点数转换为较窄的浮点数时截断或舍入的方向):

数舍入为可以表示的最近的值。