llvm::GlobalVariable::getCodeModel

Get the custom code model of this global if it has one.

Synopsis

Declared in <llvm/IR/GlobalVariable.h>

std::optional<CodeModel::Model>
getCodeModel() const;

Description

If this global does not have a custom code model, the empty instance will be returned.

Return Value

The custom code model, or std::nullopt if none.