Rotate And Shift Instructions - Xilinx Virtex-II Pro PPC405 User Manual

Platform fpga developer's kit
Table of Contents

Advertisement

Rotate and Shift Instructions

Table C-14: Simplified Mnemonics for CR-Logical Instructions (Continued)
Operation
Condition Register Clear
Condition Register Move
Condition Register Not
Rotate and Shift Instructions
Although the rotate and shift instructions provide powerful and general ways to
manipulate register contents, they can be difficult to understand. The simplified
mnemonics in
Table C-15: Simplified Mnemonics for Rotate and Shift Instructions
Operation
Extract and Left Justify Immediate
Extract and Right Justify Immediate
Insert from Left Immediate
Insert from Right Immediate
Rotate Left Immediate
Rotate Right Immediate
Rotate Left
Shift Left Immediate
Shift Right Immediate
March 2002 Release
Virtex-II Pro™ Platform FPGA Documentation
Table C-15
are provided for the following types of operations:
Extract—Select a field of n bits starting at bit position b from the source register. Left or
right justify this field in the target register. Clear all other bits of the target register.
Insert—Select a left-justified or right-justified field of n bits from the source register.
Insert this field in the target register starting at bit position b, leaving all other bits in
the target register unchanged.
Rotate—Rotate the contents of a register right or left by n bits without masking.
Shift—Shift the contents of a register right or left by n bits, clearing vacated bits
(logical shift).
Clear—Clear the left-most or right-most n bits of a register.
Clear left and shift left—Clear the left-most b bits of a register and shift the register left
by n bits. This operation can be used to scale a known non-negative array index by the
width of an element.
www.xilinx.com
1-800-255-7778
Simplified Mnemonic
crclr bx
crmove bx, by
crnot bx, by
Simplified Mnemonic
extlwi rA, rS, n, b (n > 0)
extlwi. rA, rS, n, b (n > 0)
extrwi rA, rS, n, b (n > 0)
extrwi. rA, rS, n, b (n > 0)
inslwi rA, rS, n, b (n > 0)
inslwi. rA, rS, n, b (n > 0)
insrwi rA, rS, n, b (n > 0)
insrwi. rA, rS, n, b (n > 0)
rotlwi rA, rS, n
rotlwi. rA, rS, n
rotrwi rA, rS, n
rotrwi. rA, rS, n
rotlw rA, rS, rB
rotlw. rA, rS, rB
slwi rA, rS, n (n < 32)
slwi. rA, rS, n (n < 32)
srwi rA, rS, n (n < 32)
srwi. rA, rS, n (n < 32)
Equivalent Mnemonic
crxor bx, bx, bx
cror bx, by, by
crnor bx, by, by
Equivalent Mnemonic
rlwinm rA, rS, b, 0, n−1
rlwinm. rA, rS, b, 0, n−1
rlwinm rA, rS, b+n, 32−n, 31
rlwinm. rA, rS, b+n, 32−n, 31
rlwimi rA, rS, 32−b, b, (b+n)−1
rlwimi. rA, rS, 32−b, b, (b+n)−1
rlwimi rA, rS, 32−(b+n), b, (b+n)−1
rlwimi. rA, rS, 32−(b+n), b, (b+n)−1
rlwinm rA, rS, n, 0, 31
rlwinm. rA, rS, n, 0, 31
rlwinm rA, rS, 32−n, 0, 31
rlwinm. rA, rS, 32−n, 0, 31
rlwnm rA, rS, rB, 0, 31
rlwnm. rA, rS, rB, 0, 31
rlwinm rA, rS, n, 0, 31−n
rlwinm. rA, rS, n, 0, 31−n
rlwinm rA, rS, 32−n, n, 31
rlwinm. rA, rS, 32−n, n, 31
829
R

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the Virtex-II Pro PPC405 and is the answer not in the manual?

Subscribe to Our Youtube Channel

Table of Contents