AMD Typewriter x86 사용자 설명서
Index
237
22007E/0—November 1999
AMD Athlon™ Processor x86 Code Optimization
Index
Numerics
3DNow! and MMX™ Intra-Operand Swapping . . . . . . . 112
Clipping . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 122
Fast Division . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 108
Fast Square Root and Reciprocal Square Root . . . . . . . 110
FEMMS Instruction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 107
PAVGUSB for MPEG-2 Motion Compensation . . . . . . . . 123
PFCMP Instruction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 114
PFMUL Instruction. . . . . . . . . . . . . . . . . . . . . . . . . . 113
Clipping . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 122
Fast Division . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 108
Fast Square Root and Reciprocal Square Root . . . . . . . 110
FEMMS Instruction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 107
PAVGUSB for MPEG-2 Motion Compensation . . . . . . . . 123
PFCMP Instruction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 114
PFMUL Instruction. . . . . . . . . . . . . . . . . . . . . . . . . . 113
PI2FW Instruction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 113
PREFETCH and PREFETCHW Instructions . 8
PREFETCH and PREFETCHW Instructions . 8
,
A
Address Generation Interlocks . . . . . . . . . . . . . . . . . . . . . . . 72
AMD Athlon™ Processor
AMD Athlon™ Processor
Branch-Free Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58
Code Padding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40
Family. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
Microarchitecture . . . . . . . . . . . . . . . . . . . . . . . . .4
Code Padding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40
Family. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
Microarchitecture . . . . . . . . . . . . . . . . . . . . . . . . .4
,
B
Blended Code, AMD-K6 and AMD Athlon Processors
3DNow! and MMX Intra-Operand Swapping . . . . . . . . . 112
Block Copies and Block Fills . . . . . . . . . . . . . . . . . . . . . . 115
Branch Examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58
Code Padding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41
Signed Words to Floating-Point Example. . . . . . . . . . . . 113
Block Copies and Block Fills . . . . . . . . . . . . . . . . . . . . . . 115
Branch Examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58
Code Padding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41
Signed Words to Floating-Point Example. . . . . . . . . . . . 113
Branches
Align Branch Targets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36
Compound Branch Conditions . . . . . . . . . . . . . . . . . . . . . . 20
Dependent on Random Data . . . . . . . . . . . . . . . . . . . . 10
Compound Branch Conditions . . . . . . . . . . . . . . . . . . . . . . 20
Dependent on Random Data . . . . . . . . . . . . . . . . . . . . 10
,
Prediction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 132
Replace with Computation in 3DNow! Code . . . . . . . . . . 60
Replace with Computation in 3DNow! Code . . . . . . . . . . 60
C
Array-Style Over Pointer-Style Code . . . . . . . . . . . . . . . . 15
C Code to 3DNow! Code Examples . . . . . . . . . . . . . . . 61
C Code to 3DNow! Code Examples . . . . . . . . . . . . . . . 61
,
,
CALL and RETURN Instructions . . . . . . . . . . . . . . . . . . . . . 59
Code Padding Using Neutral Code Fillers . . . . . . . . . . . . . . 39
Code Sample Analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 152
Complex Number Arithmetic . . . . . . . . . . . . . . . . . . . . . . . 126
Const Type Qualifier. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
Constant Control Code, Multiple . . . . . . . . . . . . . . . . . . . . . 23
Code Padding Using Neutral Code Fillers . . . . . . . . . . . . . . 39
Code Sample Analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 152
Complex Number Arithmetic . . . . . . . . . . . . . . . . . . . . . . . 126
Const Type Qualifier. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
Constant Control Code, Multiple . . . . . . . . . . . . . . . . . . . . . 23
D
Data Cache . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 134
Decoding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
Decoding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
,
Decoder. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 133
DirectPath Over VectorPath Instructions . . . . . . 9
DirectPath Over VectorPath Instructions . . . . . . 9
,
Displacements, 8-Bit Sign-Extended . . . . . . . . . . . . . . . . . . 39
Division . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77
Division . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77
,
E
Event and Time-Stamp Monitoring Software . . . . . . . . . . 168
Execution Unit Resources. . . . . . . . . . . . . . . . . . . . . . . . . . 148
Extended-Precision Data. . . . . . . . . . . . . . . . . . . . . . . . . . . . 99
Execution Unit Resources. . . . . . . . . . . . . . . . . . . . . . . . . . 148
Extended-Precision Data. . . . . . . . . . . . . . . . . . . . . . . . . . . . 99
F
Far Control Transfer Instructions. . . . . . . . . . . . . . . . . . . . . 65
Fetch and Decode Pipeline Stages . . . . . . . . . . . . . . . . . . . 141
FFREEP Macro . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98
Floating-Point
Fetch and Decode Pipeline Stages . . . . . . . . . . . . . . . . . . . 141
FFREEP Macro . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98
Floating-Point
Compare Instructions . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98
Divides and Square Roots . . . . . . . . . . . . . . . . . . . . . . . . . 29
Execution Unit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 137
Optimizations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97
Pipeline Operations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 150
Pipeline Stages. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 146
Scheduler . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 136
Subexpression Elimination . . . . . . . . . . . . . . . . . . . . . . . 103
To Integer Conversions . . . . . . . . . . . . . . . . . . . . . . . . . . 100
Variables and Expressions are Type Float . . . . . . . . . . . 13
Divides and Square Roots . . . . . . . . . . . . . . . . . . . . . . . . . 29
Execution Unit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 137
Optimizations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97
Pipeline Operations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 150
Pipeline Stages. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 146
Scheduler . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 136
Subexpression Elimination . . . . . . . . . . . . . . . . . . . . . . . 103
To Integer Conversions . . . . . . . . . . . . . . . . . . . . . . . . . . 100
Variables and Expressions are Type Float . . . . . . . . . . . 13
FRNDINT Instruction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 100
FSINCOS Instruction. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 105
FXCH Instruction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99
FSINCOS Instruction. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 105
FXCH Instruction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99
,
G
I
If Statement . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
Immediates, 8-Bit Sign-Extended . . . . . . . . . . . . . . . . . . . . . 38
Inline Functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71
Immediates, 8-Bit Sign-Extended . . . . . . . . . . . . . . . . . . . . . 38
Inline Functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71
,