search for: llvmprintdwarfcontext

Displaying 2 results from an estimated 2 matches for "llvmprintdwarfcontext".

2019 Apr 24
2
[DebugInfo] DWARF C API
...d ``` DEFINE_SIMPLE_CONVERSION_FUNCTIONS(DWARFContext, LLVMDWARFContextRef) ``` then defined some C functions ``` LLVMDWARFContextRef LLVMCreateDWARFContext(LLVMBinaryRef Bin) { std::unique_ptr<DWARFContext> DICtx = DWARFContext::create(*unwrap(Bin)); return wrap(DICtx.release()); } void LLVMPrintDWARFContext(LLVMDWARFContextRef C) { DIDumpOptions DumpOpts; DumpOpts.DumpType = DIDT_DebugInfo; // I only care about the .debug_info section unwrap(C)->dump(outs(), DumpOpts); } ``` However, I got a segfault when trying to dump the LLVMDWARFContextRef using the second function. More precisely, it seg...
2019 Apr 24
2
[DebugInfo] DWARF C API
...> then defined some C functions > > ``` > > LLVMDWARFContextRef LLVMCreateDWARFContext(LLVMBinaryRef Bin) { > > std::unique_ptr<DWARFContext> DICtx = > DWARFContext::create(*unwrap(Bin)); > > return wrap(DICtx.release()); > > } > > > > void LLVMPrintDWARFContext(LLVMDWARFContextRef C) { > > DIDumpOptions DumpOpts; > > DumpOpts.DumpType = DIDT_DebugInfo; // I only care about the > .debug_info section > > unwrap(C)->dump(outs(), DumpOpts); > > } > > ``` > > However, I got a segfault when trying to dump the LLVM...