76 Instruction-Decoding Optimizations Chapter 4
25112 Rev. 3.06 September 2005
Software Optimization Guide for AMD64 Processors
4.3 Branch Targets in Program Hot Spots
Optimization
In program “hot spots” (as determined by either profiling or loop-nesting analysis), branch targets
should be placed at or near the beginning of code windows that are 16-byte aligned. The smaller the
basic block, the more beneficial this optimization will be.
Application
This optimization applies to:
• 32-bit software
• 64-bit software
Rationale
Aligning branch targets maximizes the number of instructions in the pick window and preserves
instruction-cache space in branch-intensive code outside such hot spots.