x86 flags after bit shifts with count = 0 (Developers)
Original Intel manual does not say explicitly that flags are left unchanged. It explains that SHR ARG, COUNT (other shift instructions are described similarly) is performed as follows:
argbefore := ARG;
temp := COUNT;
while (temp <> 0) do
begin
  CF := LowestBit(ARG);
  ARG := ARG div 2;
  temp := temp - 1;
end;
if (COUNT = 1) then
  if (HighestBit(argbefore) <> HighestBit(ARG)) then
    OF := 1
  else
    OF := 0
else
  OF := UNDEFINED;
and also says elsewhere that for all shift instructions, AF is undefined and SF, ZF and PF are set as usual.
Complete thread:
- x86 flags after bit shifts with count = 0 - mht, 22.11.2008, 15:15 ![Open in board view [Board]](img/board_d.gif) ![Open in mix view [Mix]](img/mix_d.gif) - x86 flags after bit shifts with count = 0 - Rugxulo, 25.11.2008, 06:47- x86 flags after bit shifts with count = 0 - ecm, 25.11.2008, 13:31- x86 flags after bit shifts with count = 0 - mht, 25.11.2008, 22:11
 
- x86 flags after bit shifts with count = 0 - rr, 25.11.2008, 21:21- x86 flags after bit shifts with count = 0 - mht, 25.11.2008, 21:59- x86 flags after bit shifts with count = 0 - rr, 25.11.2008, 22:10- x86 flags after bit shifts with count = 0 - mht, 28.11.2008, 07:17- x86 flags after bit shifts with count = 0 - mht, 05.12.2008, 08:55
 
 
- x86 flags after bit shifts with count = 0 - mht, 28.11.2008, 07:17
 
- x86 flags after bit shifts with count = 0 - rr, 25.11.2008, 22:10
- x86 flags after bit shifts with count = 0 - RayeR, 25.11.2008, 22:22- x86 flags after bit shifts with count = 0 - rr, 26.11.2008, 20:57- x86 flags after bit shifts with count = 0 - Rugxulo, 28.11.2008, 00:09- x86 flags after bit shifts with count = 0 - marcov, 28.11.2008, 15:41
- x86 flags after bit shifts with count = 0 - rr, 30.11.2008, 18:33- x86 flags after bit shifts with count = 0 - Rugxulo, 30.11.2008, 20:53- portable handhelds' battery life - Rugxulo, 30.11.2008, 21:06
- x86 flags after bit shifts with count = 0 - rr, 30.11.2008, 22:38
 
- x86 flags after bit shifts with count = 0 - RayeR, 30.11.2008, 22:41
 
- x86 flags after bit shifts with count = 0 - Rugxulo, 30.11.2008, 20:53
 
 
- x86 flags after bit shifts with count = 0 - Rugxulo, 28.11.2008, 00:09
 
- x86 flags after bit shifts with count = 0 - rr, 26.11.2008, 20:57
 
- x86 flags after bit shifts with count = 0 - mht, 25.11.2008, 21:59
 
- x86 flags after bit shifts with count = 0 - ecm, 25.11.2008, 13:31
 
- x86 flags after bit shifts with count = 0 - Rugxulo, 25.11.2008, 06:47
 Board view
Board view Mix view
Mix view
