bitreverse
authorDave Watson <davejwatson@fb.com>
Tue, 5 Dec 2017 17:14:34 +0000 (09:14 -0800)
committerFacebook Github Bot <facebook-github-bot@users.noreply.github.com>
Tue, 5 Dec 2017 17:22:10 +0000 (09:22 -0800)
commitd7629090e2c23da58ffc8977b22ccb17a25ae51c
tree90c4b18d7b3cd1e1fa4268139c779e562230f461
parentd389a33028d1a8a8520bc5c85dbcf767131fd51c
bitreverse

Summary:
Adds a bitreverse function to Bits.h

AFAIK there is no great way to do this on x86, takes ~4-5ns.
arm has a single instruction we can drop in in the future.

Reviewed By: yfeldblum

Differential Revision: D6459283

fbshipit-source-id: 129db196b2fac95386f601ae57843aa87523b915
folly/Bits.h
folly/test/BitsBenchmark.cpp
folly/test/BitsTest.cpp