answersLogoWhite

0


Best Answer
FLAGS REGISTER="h2headingh3"style="color:rgb(0,0,0);"name="flags_register">Flags Register - determines the current state of the processor. They are modified automatically by CPU after mathematical operations and allow one to determine the type of the result as well as determine conditions to transfer control to other parts of the program.

Generally you cannot access these registers directly.

  1. Carry Flag (CF) - this flag is set to 1 when there is an unsigned overflow. For example when you add bytes 255 + 1 (result is not in range 0...255). When there is no overflow this flag is set to 0.
  2. Parity Flag (PF) - this flag is set to 1 when there is even number of one bits in result, and to 0 when there is odd number of one bits.
  3. Auxiliary Flag (AF) - set to 1 when there is an unsigned overflow for low nibble (4 bits).
  4. Zero Flag (ZF) - set to 1 when result is zero. For non-zero result this flag is set to 0.
  5. Sign Flag (SF) - set to 1 when result is negative. When result is positive it is set to 0. (This flag takes the value of the most significant bit.)
  6. Trap Flag (TF) - Used for on-chip debugging.
  7. Interrupt enable Flag (IF) - when this flag is set to 1 CPU reacts to interrupts from external devices.
  8. Direction Flag (DF) - this flag is used by some instructions to process data chains, when this flag is set to 0 - the processing is done forward, when this flag is set to 1 the processing is done backward.
  9. Overflow Flag (OF) - set to 1 when there is a signed overflow. For example, when you add bytes 100 + 50 (result is not in range -128...127).
User Avatar

Wiki User

6y ago
This answer is:
User Avatar
More answers
User Avatar

Wiki User

14y ago

The FLAG register is the status register in the Intel 8086 microprocessor that contains the current state of the microprocessor.This register is 16 bits wide.

This answer is:
User Avatar

User Avatar

Wiki User

9y ago

The flag register is in an 8085 microprocessor. It is an 8-bit register which contains 5 bit positions. These flags are known as zero, sign, carry, parity and auxiliary carry.

This answer is:
User Avatar

User Avatar

Wiki User

12y ago

There are altogether 9 flag registers available and the are : carry flag,parity flag, auxillary flag,zero ,sign,trap,interrupt,direction,overflow flag.

This answer is:
User Avatar

User Avatar

Wiki User

10y ago

it eats chicken

This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: Explain 8086 flag register
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

What happens when branch instruction comes in 8086?

When a branch (or "jump") instruction is executed, the condition codes bits (in the flag register) determine whether or not the Program Counter (PC register) is changed to the Effective Address specified by the instruction; if not, then the PC is unchanged.


What is the size of flag register?

All of the 8086/8088 registers, AX, BX, CX, DX, SP, BP, SI, DI, CS, DS, SS, ES, IP, and FLAGS, are 16 bit registers. The AX, BX, CX, and DX registers may also be viewed as 8 eight bit registers AH/AL, BH/BL, CH/CL, and DH/DL.


How you can change value of flag register of 8086?

In general, the best way to change the flag register is to perform some operation that sets or clears flags. If you are careful, you can also push the flags onto the stack, manipulate the stored value, and then pop them back off. This is often the method used by a debugger to set the single step flag. When using this method, it is important to not set an inconsistent combination of flags.


What is meant by flag register and what is flag?

Flag register : specific to the x86 architecture.Flag : Mark (an item) for attention or treatment in a specified way.


When does the overflow flag in 8086 set?

In the 8086/8088, the overflow flag is set when the result of an arithmetic instruction exceeds the bounds of the signed representation of a number. This is not the same as the carry flag, which is used for the unsigned representation. Both flags get set as needed. You decide which one to pay attention to.


How do you verify content of flag register?

no answer


What is psw of 8086?

Flag Register (PSW)Status is indicated with individual bits: 0 - CF - Carry Flag2 - PF - Parity Flag4 - AF - Auxiliary carry Flag6 - ZF - Zero Flag7 - SF - Sign Flag8 - TF - Trap Flag9 - IF - Interrupt Flag10 - DF - Direcetion Flag11 - OF - Overflow Flag


Function of flag register?

The main function of flag register is show the status of result stored in accumulator after execution of an instruction. Amar oli Dang,Nepal


What is the difference between conditional and control flags in 8086 microprocessor?

Control Flag Register: The Control Flag Register (CFR), also known as the Program Status Word (PSW), is a register used to control the execution flow and behavior of the processor. It typically stores various control flags that govern different aspects of the CPU's operation. Some common flags found in the Control Flag Register include: Carry Flag (CF): Used to indicate whether an arithmetic operation generated a carry or borrow. Zero Flag (ZF): Indicates whether the result of an operation is zero. Sign Flag (SF): Indicates the sign (positive or negative) of the result. Overflow Flag (OF): Indicates whether an arithmetic operation resulted in an overflow. Interrupt Flag (IF): Determines whether interrupts are enabled or disabled. The Control Flag Register provides control over program execution, including branching, interrupt handling, and arithmetic operations. It helps determine the outcome of operations and can be used for conditional branching based on specific flag states. Conditional Flag Register: The Conditional Flag Register (CFR), also known as the Condition Code Register (CCR) or Status Register (SR), contains flags that reflect the result of the most recent arithmetic or logical operation performed by the processor. These flags are used to perform conditional branching and control the flow of instructions based on specific conditions. The flags present in the Conditional Flag Register can vary depending on the processor architecture, but some common flags include: Zero Flag (ZF): Indicates whether the result of an operation is zero. Sign Flag (SF): Indicates the sign (positive or negative) of the result. Overflow Flag (OF): Indicates whether an arithmetic operation resulted in an overflow. Carry Flag (CF): Used to indicate whether an arithmetic operation generated a carry or borrow. Auxiliary Carry Flag (AF): Indicates a carry or borrow from the lower-order nibble (4 bits) to the higher-order nibble. The Conditional Flag Register is primarily used for conditional jumps or branches, allowing the processor to alter the program flow based on the current flag states. To summarize, the Control Flag Register focuses on controlling the processor's behavior and handling interrupts, while the Conditional Flag Register reflects the outcome of arithmetic and logical operations and enables conditional branching based on flag states.


Flag registers in Pentium 2 microprpcessor?

list 8-bit register that are used for register addressing


The carry flag bit is not modified by which arithmetic operation in 8086?

increment and decrement operations ie INC and DEC


What is the use of debug in 8086 microprocessor?

The debug flag in the 8086/8088 microprocessor causes one instruction to be executed, followed immediately by a debug interrupt. The flag then gets turned off, so you get get nested debug interrupts. This is used by a debugger program to single step a process that it is debugging (the debugee, so to speak).