Right Shift Signed
Bitwise arithmetic right shift operation. Shifts all bits of the input binary number to the right by a configurable amount, filling vacant leftmost positions with copies of the sign bit (MSB). Preserves sign for two’s complement numbers. Pure combinational logic (zero latency).
Introduction
This block performs an arithmetic right shift operation on standard (non-TM) data streams. The vacant leftmost positions are filled with copies of the sign bit (MSB), making it suitable for signed two’s complement arithmetic.
Pin Description
Properties
Set the input word size in bits
Default: 16
Range: 2 – 16384
Number of bit to be shifted
Number of bit positions to shift right. Range: 0 – 127.Default: 1
Range: 0 – 16384
Select if output should have same size of input or should be INPUT_SIZE-SHIFT
SAME SIZE→ Output width = Input widthSHIFTED SIZE→ Output width = Input width - Shift
Default: SAME SIZE
Options: SAME SIZE SHIFTED SIZE
Functional description
The arithmetic right shift operation shifts bits right and replicates the MSB (sign bit):
$$ y = \text{sign_extend}(\lfloor x / 2^S \rfloor) $$
Output size modes
- SAME SIZE: Output width = Input width
- SHIFTED SIZE: Output width = Input width - Shift
Timing
Purely combinational with zero latency.