diff options
Diffstat (limited to 'llvm/lib/Support')
| -rw-r--r-- | llvm/lib/Support/Allocator.cpp | 4 | 
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Support/Allocator.cpp b/llvm/lib/Support/Allocator.cpp index 230c421f1fe..36da4432073 100644 --- a/llvm/lib/Support/Allocator.cpp +++ b/llvm/lib/Support/Allocator.cpp @@ -95,8 +95,8 @@ void *BumpPtrAllocator::Allocate(size_t Size, size_t Alignment) {    }    // If Size is really big, allocate a separate slab for it. -  if (Size > SizeThreshold) { -    size_t PaddedSize = Size + sizeof(MemSlab) + Alignment - 1; +  size_t PaddedSize = Size + sizeof(MemSlab) + Alignment - 1; +  if (PaddedSize > SizeThreshold) {      MemSlab *NewSlab = Allocator.Allocate(PaddedSize);      // Put the new slab after the current slab, since we are not allocating  | 

