Integer Execution Unit
Integer Scheduler
Floating-Point Scheduler
12 to
Floating-Point Execution Unit
Load/Store Unit
Load-Store Unit LSU
AMD Athlon System Bus
L2 Cache Controller
Write Combining
140 AMD Athlon Processor Microarchitecture
Fetch and Decode Pipeline Stages
Pipeline and Execution Unit Resources Overview
C T L R O M
Cycle 2-SCAN
Cycle 1-FETCH
Cycle 3 DirectPath
Cycle 3 VectorPath
Integer Pipeline Stages
Integer Pipeline Stages
Cycle 8-EXEC
Cycle 7-SCHED
Cycle 9-ADDGEN
Cycle 10 -DCACC
Floating-Point Pipeline Stages
Floating-Point Pipeline Stages
Cycle 8-REGREN
Cycle 7-STKREN
Cycle 9-SCHEDW
Cycle 10 -SCHED
Terminology
Execution Unit Resources
Operands
Results
Integer Decode Types
Integer Pipeline Operations
Integer Pipeline Operation Types
Floating-Point Decode Types
Floating-Point Pipeline Operations
Floating-Point Pipeline Operation Types
Stage 1 Cycle Stage 2 Cycle Stage 3 Cycle
Load/Store Pipeline Operations
Load/Store Unit Stages
Code Sample Analysis
INC EBX ADD ESI, EDX
Imul EAX, ECX INC ESI MOV
ADD EDI, EBX SHL
SAR
Sample 2 Integer Register and Memory Load Operations
DEC EDX MOV EDI, ECX SUB
Implementation Write Combining
Appendix C
Programming Details
What is Write Combining?
Write-Combining Definitions and Abbreviations
Write-Combining Operations
INIT, Halt
Write Combining Completion Events
Sending Write-Buffer Data to the System
AMD Athlon System Bus Commands Generation Rules
160 Write-Combining Operations
Performance Counter Usage
Performance-Monitoring Counters
PerfEvtSel30 Registers
PerfEvtSel30 MSRs MSR Addresses C0010000h-C0010003h
Performance Counter Usage 163
Performance-Monitoring Counters
73h
65h
Snoop hits
74h
Waited to use the L2
Event Source Event Description
Instruction cache fetches
Instruction cache misses
PerfCtr30 MSRs MSR Addresses C0010004h-C0010007h
Starting and Stopping the Performance-Monitoring Counters
Event and Time-Stamp Monitoring Software
Monitoring Counter Overflow
170 Monitoring Counter Overflow
Memory Type Range Register Mtrr Mechanism
Programming the Mtrr
172 Memory Type Range Register Mtrr Mechanism
100000h Kbytes each Fixed Ranges C0000h 80000h
Fixed Ranges
FFFFFFFFh
Memory Type Encodings
Memory Types
Mtrr Capability
Register Format
Memory Type Range Register Mtrr Mechanism 175
Standard Mtrr Types and Properties
Attribute Table MSR 277h
Attribute Table PAT
PATi 3-Bit Encodings
PAT Entry Reset Value
MTRRs and PAT
PATi
PAT Memory Type Mtrr Memory Type
Effective Memory Type Based on PAT and MTRRs
Input Memory Type
Final Output Memory Types
Attribute Table PAT 181
9FFFF 9BFFF 97FFF 93FFF 8FFFF 8BFFF 87FFF 83FFF
7FFFF 6FFFF 5FFFF 4FFFF 3FFFF 2FFFF 1FFFF 0FFFF
Bffff Bbfff B7FFF B3FFF Affff Abfff A7FFF A3FFF
C7FFF C6FFF C5FFF C4FFF C3FFF C2FFF C1FFF C0FFF
Attribute Table PAT 183
MTRRphysMaskn Register Format
MTRR-Related Model-Specific Register MSR Map
186
Instruction Dispatch Execution Resources
Appendix F
AAA
Integer Instructions
AAD
AAM
ADC mreg8, reg8
ModR/M Decode Byte
ADC mem8, reg8
ADC mreg16/32, reg16/32
Bswap EAX
Bound
Bswap ECX
Bswap EDX
CLC
CBW/CWDE
CLD
CLI
CMOVE/CMOVZ reg16/32, mem16/32 0Fh
CMOVE/CMOVZ reg16/32, reg16/32 0Fh
CMOVG/CMOVNLE reg16/32, reg16/32 0Fh
CMOVG/CMOVNLE reg16/32, mem16/32 0Fh
CWD/CDQ
Cpuid
DAA
DAS
AL, DX
Enter
AX, DX
EAX, DX
Invlpg
Invd
Leave
Lahf
LOOPNE/LOOPNZ disp8 E0h
LOOPE/LOOPZ disp8 E1h
LSL reg16/32, mreg16/32 0Fh 03h
LSL reg16/32, mem16/32 0Fh 03h
NOP Xchg EAX, EAX
OUT DX, AX
OUT DX, AL
OUT DX, EAX
POP ES
POP ESP
POP EBX
POP EBP
POP ESI
Rdtsc
Rdmsr
Rdpmc
Sahf
SBB mem16/32, reg16/32
SBB mreg16/32, reg16/32
SBB reg8, mreg8
SBB reg8, mem8
Sets mem8
Sets mreg8
Setns mreg8
Setns mem8
STI
STC
STD
Sysenter
Syscall
Sysexit
Sysret
Xchg EAX, ECX
Xchg EAX, EAX
Xchg EAX, EDX
Xchg EAX, EBX
Emms
MMX Instructions
DFh
Pandn mmreg1, mmreg2
Pandn mmreg, mem64
Pcmpeqb mmreg1, mmreg2
FADD/FMUL
FPU
MMX Extensions
Floating-Point Instructions
Fdecstp
Fcompp
Fcos
FLD1
Fincstp
Finit
FLDL2T
FLDL2E
FLDLG2
FLDLN2
Ftst
Fstsw AX
Fucom
Fucomp
Femms
DNow! Instructions
DNow! Extensions
DirectPath Instructions
DirectPath versus VectorPath Instructions
CBW/CWDE CLC CMC
DirectPath Integer Instructions
BT mreg16/32, reg16/32 BT mreg16/32, imm8 BT mem16/32, imm8
INC mreg8 INC mem8 INC mreg16/32 INC mem16/32 JO short disp8
DEC mreg8 DEC mem8 DEC mreg16/32 DEC mem16/32
222 DirectPath Instructions
DirectPath Instructions 223
224 DirectPath Instructions
Wait Xchg EAX, EAX
226 DirectPath Instructions
DirectPath MMX Instructions
DirectPath MMX Extensions
Fcompp Fdecstp
DirectPath Floating-Point Instructions
Fist mem16int
FLD1 FLDL2E FLDL2T FLDLG2 FLDLN2 Fldpi Fldz
Ftst Fucom Fucomp Fucompp Fwait Fxch
VectorPath Integer Instructions
VectorPath Instructions
AAA AAD AAM AAS
CLD CLI Clts
AL, DX AX, DX EAX, DX Invd Invlpg
Instruction Mnemonic DIV EAX, mem16/32
Push mreg16/32 Push mem16/32
POP mreg 16/32 POP mem 16/32
PUSHA/PUSHAD PUSHF/PUSHFD
Rdmsr Rdpmc Rdtsc
VectorPath MMX Extensions
VectorPath MMX Instructions
Syscall Sysenter Sysexit Sysret
Wbinvd Wrmsr
Fptan Fpatan Frndint
VectorPath Floating-Point Instructions
Fscale Fsin Fsincos
Fxam Fxtract FYL2X FYL2XP1
236
Index
238 Index
Index 239
240 Index