What is the difference between RCR and ROR?

前端 未结 2 1707
南方客
南方客 2021-01-04 22:32

I understand the from the terms that RCR would rotate the bit from the right to left, taking the bit from the carry while ROR will

2条回答
  •  半阙折子戏
    2021-01-04 23:06

    RCR includes the carry flag in the rotation, so it's effectively an N+1 bit rotate, whereas ROR does not include the carry flag, so it's just an N bit rotate.

    Some nice diagrams from www.c-jump.com:

    enter image description here

    enter image description here

提交回复
热议问题