summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/llvm/Support/Allocator.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/llvm/Support/Allocator.h b/include/llvm/Support/Allocator.h
index 916413247b..06413225a9 100644
--- a/include/llvm/Support/Allocator.h
+++ b/include/llvm/Support/Allocator.h
@@ -255,7 +255,7 @@ private:
// size threshold. That will be fixed in a subsequent commit to make the
// growth even more predictable.
size_t AllocatedSlabSize =
- SlabSize * (1 << std::min<size_t>(30, NumSlabs / 128));
+ SlabSize * ((size_t)1 << std::min<size_t>(30, NumSlabs / 128));
MemSlab *NewSlab = Allocator.Allocate(AllocatedSlabSize);
NewSlab->NextPtr = CurSlab;