You are here : vhdlstd_logic_arithshift-functions

shift functions - std_logic_arith

The bit shifting operations shift left (shl) and shift right (shr) are defined on the unsigned and signed types.

They shift arg in the given direction by count places.


Syntax

function shl(arg: unsigned; count: unsigned) return unsigned;
function shl(arg: signed; count: unsigned) return signed;
function shr(arg: unsigned; count: unsigned) return unsigned;
function shr(arg: signed; count: unsigned) return signed;


Example


Output / Return Value


Limitations


Alternatives / See Also


Reference