Assembly - The sign flag & parity flag

前端 未结 2 1891
心在旅途
心在旅途 2021-01-29 03:35

I didn\'t understand when the sign flag is set, and when the parity.

As I know, the sign flag indicates the sign of the result of an operation, 0 for positive numbers an

2条回答
  •  天命终不由人
    2021-01-29 03:52

    the maximum number you can represent in 8 bits is 2^8-1 which is 255 thus because 127+129=256, al will hold 0, and flags: CF PF AF ZF IF would be set, PF is set as mentioned above - because PF is set if and only if the amount of bits set is even.

提交回复
热议问题