class DebugLoc

Declaration

class DebugLoc { /* full declaration omitted */ };

Declared at: llvm/include/llvm/IR/DebugLoc.h:33

Method Overview

Methods

DebugLoc(const llvm::DILocation* L)

Description

Construct from an \a DILocation.

Declared at: llvm/include/llvm/IR/DebugLoc.h:40

Parameters

const llvm::DILocation* L

DebugLoc(const llvm::MDNode* N)

Description

Construct from an \a MDNode. Note: if \c N is not an \a DILocation, a verifier check will fail, and accessors will crash. However, construction from other nodes is supported in order to handle forward references when reading textual IR.

Declared at: llvm/include/llvm/IR/DebugLoc.h:48

Parameters

const llvm::MDNode* N

DebugLoc()

Declared at: llvm/include/llvm/IR/DebugLoc.h:37

static llvm::DebugLoc appendInlinedAt(
    llvm::DebugLoc DL,
    llvm::DILocation* InlinedAt,
    llvm::LLVMContext& Ctx,
    int& Cache,
    bool ReplaceLast = false)

Declared at: llvm/include/llvm/IR/DebugLoc.h:88

Parameters

llvm::DebugLoc DL
llvm::DILocation* InlinedAt
llvm::LLVMContext& Ctx
int& Cache
bool ReplaceLast = false

void dump() const

Declared at: llvm/include/llvm/IR/DebugLoc.h:122

llvm::DILocation* get() const

Description

Get the underlying \a DILocation.

Declared at: llvm/include/llvm/IR/DebugLoc.h:54

static llvm::DebugLoc get(
    unsigned int Line,
    unsigned int Col,
    const llvm::MDNode* Scope,
    const llvm::MDNode* InlinedAt = nullptr,
    bool ImplicitCode = false)

Description

Create a new DebugLoc. Create a new DebugLoc at the specified line/col and scope/inline. This forwards to \a DILocation::get(). If \c !Scope, returns a default-constructed \a DebugLoc. FIXME: Remove this. Users should use DILocation::get().

Declared at: llvm/include/llvm/IR/DebugLoc.h:79

Parameters

unsigned int Line
unsigned int Col
const llvm::MDNode* Scope
const llvm::MDNode* InlinedAt = nullptr
bool ImplicitCode = false

llvm::MDNode* getAsMDNode() const

Description

Return \c this as a bar \a MDNode.

Declared at: llvm/include/llvm/IR/DebugLoc.h:113

unsigned int getCol() const

Declared at: llvm/include/llvm/IR/DebugLoc.h:94

llvm::DebugLoc getFnDebugLoc() const

Description

Find the debug info location for the start of the function. Walk up the scope chain of given debug loc and find line number info for the function. FIXME: Remove this. Users should use DILocation/DILocalScope API to find the subprogram, and then DILocation::get().

Declared at: llvm/include/llvm/IR/DebugLoc.h:110

llvm::DILocation* getInlinedAt() const

Declared at: llvm/include/llvm/IR/DebugLoc.h:96

llvm::MDNode* getInlinedAtScope() const

Description

Get the fully inlined-at scope for a DebugLoc. Gets the inlined-at scope for a DebugLoc.

Declared at: llvm/include/llvm/IR/DebugLoc.h:101

unsigned int getLine() const

Declared at: llvm/include/llvm/IR/DebugLoc.h:93

llvm::MDNode* getScope() const

Declared at: llvm/include/llvm/IR/DebugLoc.h:95

bool hasTrivialDestructor() const

Description

Check whether this has a trivial destructor.

Declared at: llvm/include/llvm/IR/DebugLoc.h:69

bool isImplicitCode() const

Description

Check if the DebugLoc corresponds to an implicit code.

Declared at: llvm/include/llvm/IR/DebugLoc.h:116

bool operator bool() const

Description

Check for null. Check for null in a way that is safe with broken debug info. Unlike the conversion to \c DILocation, this doesn't require that \c Loc is of the right type. Important for cases like \a llvm::StripDebugInfo() and\a Instruction::hasMetadata().

Declared at: llvm/include/llvm/IR/DebugLoc.h:66

llvm::DILocation* operator llvm::DILocation*()
    const

Declared at: llvm/include/llvm/IR/DebugLoc.h:55

void print(llvm::raw_ostream& OS) const

Description

prints source location /path/to/file.exe:line:col @ [inlined at]

Declared at: llvm/include/llvm/IR/DebugLoc.h:125

Parameters

llvm::raw_ostream& OS

void setImplicitCode(bool ImplicitCode)

Declared at: llvm/include/llvm/IR/DebugLoc.h:117

Parameters

bool ImplicitCode