Skip to content

Commit

Permalink
Added missing check _M_IX86 or _M_X64 when using __lzcnt. (#1217)
Browse files Browse the repository at this point in the history
Signed-off-by: Dirk Lemstra <dirk@lemstra.org>
  • Loading branch information
dlemstra authored Jan 14, 2022
1 parent 4cc01e5 commit 157857e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib/OpenEXRCore/internal_coding.h
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ half_to_float (uint16_t hv)
else if (hexpmant != 0)
{
uint32_t lc;
# if defined(_MSC_VER)
# if defined(_MSC_VER) && (_M_IX86 || _M_X64)
lc = __lzcnt (hexpmant);
# elif defined(__GNUC__) || defined(__clang__)
lc = (uint32_t) __builtin_clz (hexpmant);
Expand Down

0 comments on commit 157857e

Please sign in to comment.