Commit d5897678 authored by Mark Mendell's avatar Mark Mendell Committed by Roland Levillain
Browse files

Implement CountLeadingZeros for x86



Generate Long and Integer numberOfLeadingZeros for x86 and x86_64. Uses
'bsr' instruction to find the first one bit, and then corrects the
result.

Added some more tests with constant values to test constant folding.
Also add a runtime test with 0 as the input.

Change-Id: I920b21bb00069bccf5f921f8f87a77e334114926
Signed-off-by: default avatarMark Mendell <mark.p.mendell@intel.com>
parent 8ecc1357
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment