class SpecificBumpPtrAllocator

Declaration

template <typename T>
class SpecificBumpPtrAllocator { /* full declaration omitted */ };

Description

A BumpPtrAllocator that allows only elements of a specific type to be allocated. This allows calling the destructor in DestroyAll() and when the allocator is destroyed.

Declared at: llvm/include/llvm/Support/Allocator.h:446

Templates

T

Method Overview

Methods

T* Allocate(size_t num = 1)

Description

Allocate space for an array of objects without constructing them.

Declared at: llvm/include/llvm/Support/Allocator.h:496

Parameters

size_t num = 1

void DestroyAll()

Description

Call the destructor of each allocated object and deallocate all but the current slab and reset the current pointer to the beginning of it, freeing all memory allocated so far.

Declared at: llvm/include/llvm/Support/Allocator.h:467

SpecificBumpPtrAllocator<T>()

Declared at: llvm/include/llvm/Support/Allocator.h:450

SpecificBumpPtrAllocator<T>(
    SpecificBumpPtrAllocator<T>&& Old)

Declared at: llvm/include/llvm/Support/Allocator.h:455

Parameters

SpecificBumpPtrAllocator<T>&& Old

~SpecificBumpPtrAllocator<T>()

Declared at: llvm/include/llvm/Support/Allocator.h:457