Relative Content

Tag Archive for assemblymathbit-manipulationbitwise-operatorsbit-shift

Logical shift right without instruction

I am working with an assembly language that does not contain either multiply, divide, or bit-shift instructions. I am aware that a left bit-shift can be achieved by just adding the same number to itself – add A, A – but I am unsure about a right bit-shift. How would I go about implementing a right bit-shift with instructions such as add, sub, not, and and or?