This is an archive of the discontinued LLVM Phabricator instance.

X86 Intrinsics: _bit_scan_forward should not be under #ifdef __RDRND__
ClosedPublic

Authored by zvi on Jul 9 2017, 11:06 AM.

Details

Summary

The _bit_scan_forward and _bit_scan_reverse intrinsics were accidentally
masked under the preprocessor checks that prune intrinsics definitions for the
benefit of faster compile-time on Windows. This patch moves the
definitons out of that region.

Fixes pr33722

Event Timeline

zvi created this revision.Jul 9 2017, 11:06 AM
craig.topper added inline comments.Jul 9 2017, 11:12 AM
lib/Headers/immintrin.h
230

Looks like we now aren't removing rdrand64_step. Should we put the rdrand functions together and not have bit_scan between them?

zvi added inline comments.Jul 9 2017, 11:45 AM
lib/Headers/immintrin.h
230

Right! Thanks for pointing that out.

zvi updated this revision to Diff 105788.Jul 9 2017, 11:47 AM

rdrand64_step should be under the ifdef

zvi marked 2 inline comments as done.Jul 9 2017, 11:50 AM
This revision is now accepted and ready to land.Jul 9 2017, 11:33 PM
This revision was automatically updated to reflect the committed changes.