[PATCH] Partial fix for bug 22589
david.majnemer at gmail.com
Tue Feb 17 22:08:47 PST 2015
Comment at: lib/Transforms/Utils/LoopUnrollRuntime.cpp:314
@@ -309,3 +313,3 @@
// Count is the loop unroll factor, the number of extra copies added + 1.
if ((Count & (Count-1)) != 0)
> majnemer wrote:
> > Can we use isPowerOf2_32 here?
> Is it okay to assume that `unsigned` is 32 bits long? Can it be 64 bits on a platform LLVM runs on?
This assumption is fine. If the distinction would matter, the code would be wrong on LLVM's current platforms because LLVM IR (and transforms on it) shouldn't depend on the compiler host.
More information about the llvm-commits