The offset part of an address is given on the form base + index*scale + displacement
. There are only certain values that are allowed for the scale
part of the offset. These are 1
(the default), 2
, 4
and 8
.
This is described in Intel's Software Developers Manual Vol 1 (the section named Specifying an Offset):
The offset part of a memory address can be specified directly as a static value (called a displacement) or through an address computation made up of one or more of the following components:
• Displacement — An 8-, 16-, or 32-bit value.
• Base — The value in a general-purpose register.
• Index — The value in a general-purpose register.
• Scale factor — A value of 2, 4, or 8 that is multiplied by the index value.
(The above quote is for 32-bit mode, but the same limitation on the scale factor applies in 64-bit mode)