LLVM 22.0.0git
AllocToken.h File Reference
#include "llvm/ADT/SmallString.h"
#include "llvm/ADT/StringRef.h"
#include <cstdint>
#include <optional>

Go to the source code of this file.

Classes

 Metadata about an allocation used to generate a token ID. More...

Namespaces

namespace  llvm
 This is an optimization pass for GlobalISel generic memory operations.

Enumerations

enum class  llvm::AllocTokenMode { llvm::Increment , llvm::Random , llvm::TypeHash , llvm::TypeHashPointerSplit }
 Modes for generating allocation token IDs. More...

Functions

LLVM_ABI std::optional< AllocTokenModellvm::getAllocTokenModeFromString (StringRef Name)
 Returns the AllocTokenMode from its canonical string name; if an invalid name was provided returns nullopt.
LLVM_ABI std::optional< uint64_tllvm::getAllocToken (AllocTokenMode Mode, const AllocTokenMetadata &Metadata, uint64_t MaxTokens)
 Calculates stable allocation token ID.

Variables

constexpr AllocTokenMode llvm::DefaultAllocTokenMode
 The default allocation token mode.