Volume 4: Base IA-32 Instruction Reference
4:199
FYL2X—Compute y
log
2
x
Description
Calculates (ST(1)
log
2
(ST(0))), stores the result in resister ST(1), and pops the FPU
register stack. The source operand in ST(0) must be a non-zero positive number.
The following table shows the results obtained when taking the log of various classes of
numbers, assuming that neither overflow nor underflow occurs.
Notes:
Fmeans finite-real number.
*indicates floating-point invalid-operation (#IA) exception.
**indicates floating-point zero-divide (#Z) exception.
If the divide-by-zero exception is masked and register ST(0) contains
0, the
instruction returns
with a sign that is the opposite of the sign of the source operand in
register ST(1).
The FYL2X instruction is designed with a built-in multiplication to optimize the
calculation of logarithms with an arbitrary positive base (b):
log
b
x = (log
2
b)
-1
log
2
x
Operation
ST(1)
ST(1)
log
2
ST(0);
PopRegisterStack;
FPU Flags Affected
C1
Set to 0 if stack underflow occurred.
Indicates rounding direction if the inexact-result exception (#P) is
generated: 0 = not roundup; 1 = roundup.
C0, C2, C3
Undefined.
Opcode
Instruction
Description
D9 F1
FYL2X
Replace ST(1) with (ST(1)
log
2
ST(0)) and pop the register
stack
Table 2-11.
FYL2X Zeros and NaNs
ST(0)
F
0
0
F
+
NaN
*
*
+
+
+
NaN
ST(1)
F
*
*
**
**
F
NaN
0
*
*
*
*
0
*
NaN
0
*
*
*
*
0
*
NaN
F
*
*
**
**
F
+
NaN
+
*
*
+
NaN
NaN
NaN
NaN
NaN
NaN
NaN
NaN
NaN
Содержание ITANIUM ARCHITECTURE
Страница 1: ......
Страница 7: ...402 Intel Itanium Architecture Software Developer s Manual Rev 2 3 ...
Страница 199: ...4 192 Volume 4 Base IA 32 Instruction Reference FWAIT Wait See entry for WAIT ...
Страница 269: ...4 262 Volume 4 Base IA 32 Instruction Reference LES Load Full Pointer See entry for LDS LES LFS LGS LSS ...
Страница 270: ...Volume 4 Base IA 32 Instruction Reference 4 263 LFS Load Full Pointer See entry for LDS LES LFS LGS LSS ...
Страница 273: ...4 266 Volume 4 Base IA 32 Instruction Reference LGS Load Full Pointer See entry for LDS LES LFS LGS LSS ...
Страница 288: ...Volume 4 Base IA 32 Instruction Reference 4 281 LSS Load Full Pointer See entry for LDS LES LFS LGS LSS ...
Страница 352: ...Volume 4 Base IA 32 Instruction Reference 4 345 ROL ROR Rotate See entry for RCL RCR ROL ROR ...
Страница 368: ...Volume 4 Base IA 32 Instruction Reference 4 361 SHL SHR Shift Instructions See entry for SAL SAR SHL SHR ...
Страница 373: ...4 366 Volume 4 Base IA 32 Instruction Reference SIDT Store Interrupt Descriptor Table Register See entry for SGDT SIDT ...
Страница 589: ...4 582 Volume 4 IA 32 SSE Instruction Reference ...
Страница 590: ...Index Intel Itanium Architecture Software Developer s Manual Rev 2 3 Index ...
Страница 591: ...Index Intel Itanium Architecture Software Developer s Manual Rev 2 3 ...
Страница 603: ...INDEX Index 12 Index for Volumes 1 2 3 and 4 ...
Страница 604: ......