From: Gabe Black Date: Wed, 5 Aug 2009 09:56:12 +0000 (-0700) Subject: X86: Fix how the parity flag is computed. X-Git-Tag: Calvin_Submission~185 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=df2c862a078e4060017b150656a473b2fb84598e;p=gem5.git X86: Fix how the parity flag is computed. It's only for the lowest order byte, and I had the polarity wrong. --- diff --git a/src/arch/x86/insts/microregop.cc b/src/arch/x86/insts/microregop.cc index 2edd3ba87..5982dff7a 100644 --- a/src/arch/x86/insts/microregop.cc +++ b/src/arch/x86/insts/microregop.cc @@ -78,7 +78,7 @@ namespace X86ISA if(subtract) flags ^= (flagMask & (ECFBit | CFBit)); } - if(flagMask & PFBit && findParity(dataSize*8, _dest)) + if(flagMask & PFBit && !findParity(8, _dest)) flags |= PFBit; if(flagMask & AFBit) {