Append an instruction's effect to a salvaged DIExpression operand list.
Declared in <llvm/Transforms/Utils/Local.h>
Value*
salvageDebugInfoImpl(
Instruction& I,
uint64_t CurrentLocOps,
SmallVectorImpl<uint64_t>& Ops,
SmallVectorImpl<Value*>& AdditionalValues);
Given an instruction I and DIExpression DIExpr operating on it, append the effects of I to the DIExpression operand list Ops, or return nullptr if it cannot be salvaged. CurrentLocOps is the number of SSA values referenced by the incoming Ops.
/ I = add %a, i32 1
Return = %a Ops = llvm::dwarf::DW_OP_lit1 llvm::dwarf::DW_OP_add
I = add %a, %b
Return = %a Ops = llvm::dwarf::DW_OP_LLVM_arg0 llvm::dwarf::DW_OP_add AdditionalValues = %b
the first non-constant operand implicitly referred to by Ops. If I references more than one non-constant operand, any additional operands are added to AdditionalValues.
| Name | Description |
|---|---|
| I | Instruction whose effect may be appended to Ops. |
| CurrentLocOps | Number of SSA values already referenced by Ops. |
| Ops | DIExpression operand list being rewritten. |
| AdditionalValues | Extra non-constant operands referenced by I. |