assembly to compare two numbers

前端 未结 8 1973
情书的邮戳
情书的邮戳 2020-12-10 02:35

What is the assembler syntax to determine which of two numbers is greater?

What is the lower level (machine code) for it? Can we go even lower? Once we get to the bi

8条回答
  •  暗喜
    暗喜 (楼主)
    2020-12-10 03:08

    First a CMP (comparison) instruction is called then one of the following:

    jle - jump to line if less than or equal to
    jge - jump to line if greater than or equal to

    The lowest assembler works with is bytes, not bits (directly anyway). If you want to know about bit logic you'll need to take a look at circuit design.

提交回复
热议问题