Both lines are part of the encoding of the jmp

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: ferent control constructs of C are implemented with them. 3.6.1 Condition Codes In addition to the integer registers, the CPU maintains a set of single-bit condition code registers describing attributes of the most recent arithmetic or logical operation. These registers can then be tested to perform conditional branches. The most useful condition codes are: CF: Carry Flag. The most recent operation generated a carry out of the most significant bit. Used to detect overflow for unsigned operations. This instruction is called cdq in the Intel documentation, one of the few cases where the GAS name for an instruction bears no relation to the Intel name. 1 3.6. CONTROL ZF: Zero Flag. The most recent operation yielded zero. SF: Sign Flag. The most recent operation yielded a negative value. 111 OF: Overflow Flag. The most recent operation caused a two’s complement overflow—either negative or positive. For example, suppose we used the addl instruction to perform the equivalent of the C expression t=a+b, where variables a...
View Full Document

This note was uploaded on 09/02/2010 for the course ELECTRICAL 360 taught by Professor Schultz during the Spring '10 term at BYU.

Ask a homework question - tutors are online