In a computer processor the negative flag or sign flag is a single bit in a system status (flag) register used to indicate whether the result of the last mathematical operation produced a value in which the most significant bit (the left most bit) was set. In a two's complement interpretation of the result, the negative flag is set if the result was negative.
For example, in an 8-bit signed number system, -37 will be represented as 1101 1011 in binary (the most significant bit, or sign bit, is 1), while +37 will be represented as 0010 0101 (the most significant bit is 0).
The negative flag is set according to the result in the x86 series processors by the following instructions (referring to the Intel 80386 manual[1]):
- All arithmetic operations except multiplication and division;
- compare instructions (equivalent to subtract instructions without storing the result);
- Logical instructions – XOR, AND, OR;
- TEST instructions (equivalent to AND instructions without storing the result).
References
🔥 Top keywords: Main PageShannen DohertySpecial:SearchCarlos AlcarazList of United States presidential assassination attempts and plotsAttempted assassination of Donald TrumpDonald TrumpRichard Simmons2024 shooting at a Donald Trump rallyLamine YamalNovak DjokovicNico WilliamsUEFA European ChampionshipWikipedia:Featured picturesThomas Matthew CrooksProject 2025Attempted assassination of Ronald ReaganUEFA Euro 2024Jacoby JonesAR-15–style rifleMukesh AmbaniLonglegsSpain national football teamKimberly CheatleKalki 2898 ADList of Wimbledon gentlemen's singles championsCole PalmerGareth SouthgateJohn Hinckley Jr.Harry KaneLuke PerryAntifa (United States)United States Secret Service.xxxDeaths in 2024Ruth WestheimerEvan VucciButler, PennsylvaniaIndian 2