ashr

Group: bits

Perform a arithmetic shift right.

Syntax

ashr out:r-op source:r-op offset:r-op
ashr void source:r-op offset:r-op
    

Semantics

Bits in source value are shifted to the right by the number specifier by the integer from the offset operand. Value of the most significant bit is used to pad the bit string from the left. The source value is modified in-place. The bits that were shifted out are put in the "out" register, if it is not void.

Examples

.function: example/0
    return
.end
    

Related instructions

bits, shl, shr, ashl.