Page MenuHomePhabricator

Win32 does not have popcnt64 function and fix bug with defines in ctz function

Authored by danlark on Feb 10 2019, 8:05 PM.


Diff Detail

Event Timeline

danlark created this revision.Feb 10 2019, 8:05 PM
EricWF accepted this revision.Feb 10 2019, 10:48 PM
EricWF added a subscriber: EricWF.

LGTM other than inline nits.


This check seems redundant since _LIBCPP_HAS_BITSCAN is defined by those very same conditions.

This revision is now accepted and ready to land.Feb 10 2019, 10:48 PM

LGTM other than inline nits.

I don't have commit rights, I believe

mclow.lists requested changes to this revision.Feb 11 2019, 8:30 AM
mclow.lists added inline comments.

We like our own defines in our files; we try to avoid using things like _M_IX86 (what does that even mean?)

If we need a new macro that says "We are a 32 bit windows environment", then we should define one.

This revision now requires changes to proceed.Feb 11 2019, 8:30 AM

This is all pretty much a lost cause on Windows anyway, since none of the compiler intrinsics are constexpr, and with the (upcoming) adoption of P0553 and P0556 these routines will have to be constexpr.

danlark abandoned this revision.May 28 2020, 7:07 AM