Traverses the scope chain rooted at RootScope until it hits a Subprogram, recreating the chain with "NewSP" instead.

Synopsis

Declared in <llvm/IR/DebugInfoMetadata.h>

static
DILocalScope*
cloneScopeForSubprogram(
    DILocalScope& RootScope,
    DISubprogram& NewSP,
    LLVMContext& Ctx,
    DenseMap<MDNode const*, MDNode*>& Cache);

Return Value

traverses the scope chain rooted at RootScope until it hits a Subprogram,.

Parameters

Name

Description

RootScope

Root local scope to clone.

NewSP

Subprogram that owns the cloned scope chain.

Ctx

LLVM context for newly created scope nodes.

Cache

Map from old scopes to already‐cloned scopes.

Created with MrDocs