search for: getcompileunit

Displaying 4 results from an estimated 4 matches for "getcompileunit".

2010 Nov 26
0
[LLVMdev] Next round of DWARF issues/questions
...rors in this piece of code in DwarfDebug::constructInlinedScopeDIE(): *if* (!Scope->getScopeNode()) *return* NULL; DIScope DS(Scope->getScopeNode()); DIE *ScopeDIE = *new* DIE(dwarf::DW_TAG_inlined_subroutine); DISubprogram InlinedSP = getDISubprogram(DS); CompileUnit *TheCU = getCompileUnit(InlinedSP); DIE *OriginDIE = TheCU->getDIE(InlinedSP); assert(OriginDIE && *"Unable to find Origin DIE!"*); addDIEEntry(ScopeDIE, dwarf::DW_AT_abstract_origin, *dwarf*::DW_FORM_ref4, OriginDIE); What's happening is that InlinedSP.DbgNode is NULL, which...
2011 Apr 27
1
[LLVMdev] LLVM internal getDirectory() for LexicalBlock debug information returns filename?
...a !{i32 589835, metadata !14, i32 11, i32 3, metadata !1, i32 1} ; [ DW_TAG_lexical_block ] ... In llvm/Analysis/DebugInfo.h, I see some exception code in DISubProgram for LLVMDebugVersion7: StringRef getDirectory() const { if (getVersion() == llvm::LLVMDebugVersion7) return getCompileUnit().getFilename(); return getFieldAs<DIFile>(6).getDirectory(); } The DILexicalBlock code does not include such exceptions, but even if I try to add such code, the result is still the filename iso directory. I am at a loss how to address this. Any help would be greatly appreciated!...
2010 Nov 26
3
[LLVMdev] Next round of DWARF issues/questions
On Tue, Nov 9, 2010 at 9:04 AM, Devang Patel <dpatel at apple.com> wrote: > > > On Nov 8, 2010, at 10:52 PM, Talin <viridia at gmail.com> wrote: > > On Mon, Nov 8, 2010 at 9:56 AM, Devang Patel < <dpatel at apple.com> > dpatel at apple.com> wrote: > >> >> On Nov 6, 2010, at 7:35 PM, Talin wrote: >> >> After to speaking to Devang
2011 Mar 29
0
[LLVMdev] Fwd: Accessing metadata & creating DIVariable
...I said in the first line of my original mail :) I >> am adding instrumentation code/variables to IR, and I want to add >> debuginfo for the new variables and calls I introduced. > > Sorry, I missed that. > > If you already have DISubprogram then you can use DISubprogram::getCompileUnit() to find the compile unit for the subprogram. DISubprogram is one the useful MDNode wrapper. See DebugInfo.h for more info. You also may find DebugInfoFinder from DebugInfo.h useful. > > In your case, you'll have to construct MDNodes for variables and types by hand. It is simple, take a...