Skip to content

Commit

Permalink
Fixed IsFloatPositiveZero from returning 'true' on non-constant doubl…
Browse files Browse the repository at this point in the history
…e operands (dotnet#64083)

* Fixed IsFloatPositiveZero from returning 'true' on non-constant double operands

* Update src/coreclr/jit/gentree.h

Co-authored-by: Egor Bogatov <egorbo@gmail.com>

Co-authored-by: Egor Bogatov <egorbo@gmail.com>
  • Loading branch information
TIHan and EgorBo committed Jan 21, 2022
1 parent 744d96a commit 0b8204f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/coreclr/jit/gentree.h
Original file line number Diff line number Diff line change
Expand Up @@ -7661,7 +7661,7 @@ inline bool GenTree::IsSIMDZero() const
//
inline bool GenTree::IsFloatPositiveZero() const
{
return !(IsCnsNonZeroFltOrDbl());
return IsCnsFltOrDbl() && !IsCnsNonZeroFltOrDbl();
}

//-------------------------------------------------------------------
Expand Down

0 comments on commit 0b8204f

Please sign in to comment.