INSTRUCTION SET OVERVIEW
5-9
5
5.2.3.3
Shift, Rotate and Extended Shift
These shift instructions shift an operand a specified number of bits left or right:
Except for
rotate
, these instructions discard bits shifted beyond the register boundary.
shlo
shifts zeros in from the least significant bit;
shro
shifts zeros in from the most significant bit.
These instructions are equivalent to
mulo
and
divo
by the power of 2, respectively.
shli
shifts zeros in from the least significant bit. When the shift operation results in an overflow, an
integer-overflow fault is generated (when enabled). The destination register is written with the
source shifted as much as possible without overflow and an integer-overflow fault is signaled.
shri
performs a conventional arithmetic shift right operation by extending the sign bit. However,
when this instruction is used to divide a negative integer operand by the power of 2, it may produce
an incorrect quotient. (Discarding the bits shifted out has the effect of rounding the result toward
negative.)
shrdi
is provided for dividing integers by the power of 2. With this instruction, 1 is added to the
result when the bits shifted out are non-zero and the operand is negative, which produces the
correct result for negative operands.
shli
and
shrdi
are equivalent to
muli
and
divi
by the power of
2, respectively, except in cases where an overflow error occurs.
rotate
rotates operand bits to the left (toward higher significance) by a specified number of bits.
Bits shifted beyond the register’s left boundary (bit 31) appear at the right boundary (bit 0).
The
eshro
instruction performs an ordinal right shift of a source register pair (64 bits) by as much
as 32 bits and stores the result in a single (32-bit) register. This instruction is equivalent to an
extended divide by a power of 2, which produces no remainder. The instruction is also the
equivalent of a 64-bit extract of 32 bits.
shlo
shift left ordinal
shro
shift right ordinal
shli
shift left integer
shri
shift right integer
shrdi
shift right dividing integer
rotate
rotate left
eshro
extended shift right ordinal
Содержание i960 Jx
Страница 1: ...Release Date December 1997 Order Number 272483 002 i960 Jx Microprocessor Developer s Manual ...
Страница 24: ......
Страница 25: ...1 INTRODUCTION ...
Страница 26: ......
Страница 35: ...2 DATA TYPES AND MEMORY ADDRESSING MODES ...
Страница 36: ......
Страница 46: ......
Страница 47: ...3 PROGRAMMING ENVIRONMENT ...
Страница 48: ......
Страница 73: ...4 CACHE AND ON CHIP DATA RAM ...
Страница 74: ......
Страница 85: ...5 INSTRUCTION SET OVERVIEW ...
Страница 86: ......
Страница 111: ...6 INSTRUCTION SET REFERENCE ...
Страница 112: ......
Страница 195: ...INSTRUCTION SET REFERENCE 6 83 6 Opcode mov 5CCH REG movl 5DCH REG movt 5ECH REG movq 5FCH REG See Also LOAD STORE lda ...
Страница 233: ...7 PROCEDURE CALLS ...
Страница 234: ......
Страница 256: ......
Страница 257: ...8 FAULTS ...
Страница 258: ......
Страница 291: ...9 TRACING AND DEBUGGING ...
Страница 292: ......
Страница 309: ...10 TIMERS ...
Страница 310: ......
Страница 324: ......
Страница 325: ...11 INTERRUPTS ...
Страница 326: ......
Страница 369: ...12 INITIALIZATION AND SYSTEM REQUIREMENTS ...
Страница 370: ......
Страница 412: ......
Страница 413: ...13 MEMORY CONFIGURATION ...
Страница 414: ......
Страница 429: ...14 EXTERNAL BUS ...
Страница 430: ......
Страница 468: ......
Страница 469: ...15 TEST FEATURES ...
Страница 470: ......
Страница 493: ...A CONSIDERATIONS FOR WRITING PORTABLE CODE ...
Страница 494: ......
Страница 502: ......
Страница 503: ...B OPCODES AND EXECUTION TIMES ...
Страница 504: ......
Страница 515: ...C MACHINE LEVEL INSTRUCTION FORMATS ...
Страница 516: ......
Страница 523: ...D REGISTER AND DATA STRUCTURES ...
Страница 524: ......
Страница 550: ......
Страница 551: ...GLOSSARY ...
Страница 552: ......
Страница 561: ...INDEX ...
Страница 562: ......
Страница 578: ......