sll

Shift left logical Undocumented

Shifts a register or memory byte left one bit, copying bit 7 to C and putting one into bit 0.

SZHP/VNC ●●0●0●
  • ● set from the result
  • 0 always 0

Forms

  • The contents of r are shifted left one bit position. The contents of bit 7 are put into the carry flag and a one is put into bit 0.

  • sll 2 bytes · 15 cycles

    The contents of (HL) are shifted left one bit position. The contents of bit 7 are put into the carry flag and a one is put into bit 0.

  • The contents of the memory location pointed to by IX plus dd are shifted left one bit position. The contents of bit 7 are put into the carry flag and a one is put into bit 0. The result is then stored in r.

  • The contents of the memory location pointed to by IX plus dd are shifted left one bit position. The contents of bit 7 are put into the carry flag and a one is put into bit 0.

Operands

r
An 8-bit register: a, b, c, d, e, h or l.
(hl)
The byte in memory at the address stored in hl. More
(ix+dd)
The byte in memory at ix + dd, where dd is a signed displacement from -128 to 127, for example (ix+5) or (ix-3). (iy+dd) works the same way. More
        .org 0x8000
        ld b, 3
        sll b
        halt