search for: getcurrentdebugloc

Displaying 5 results from an estimated 5 matches for "getcurrentdebugloc".

2015 Nov 03
3
how to add the location debug info for each instruction
Hello, For some reason, I have to stick on llvm 3.3 for a language compiler, I find that the location debug info is attached to each instruction using !dbg, however, I found some of that information is mis-attched and need to be changed, so I want to *know what functions(I checked all funcs in DIBuilder.h but didn't find a appropriate one) are used to attach those !dbg nodes to each
2015 Nov 04
2
how to add the location debug info for each instruction
...n ? It would be even better if you can points to the places that clang uses to create those nodes. >> > > Have a look at IRBuilder instead: > > void SetCurrentDebugLocation (DebugLoc L) > Set location information used by debugging information. > const DebugLoc & getCurrentDebugLocation () const > Get location information used by debugging information. > > -- adrian > > PS: Isn’t it nice how we consistently name accessor functions? > > > > > -- > Best regards > > > Hui Zhang > > > > -- > Best regards &gt...
2015 Jul 13
2
[LLVMdev] Problem with InsertPointGuard ABI?
...rtPointGuard constructor it shows different data layout. LLDB also crashes after step out and printing the guard again. 195 public: 196 InsertPointGuard(IRBuilderBase &B) 197 : Builder(B), Block(B.GetInsertBlock()), Point(B.GetInsertPoint()), -> 198 DbgLoc(B.getCurrentDebugLocation()) {} 199 200 ~InsertPointGuard() { 201 Builder.restoreIP(InsertPoint(Block, Point)); (lldb) p *this (llvm::IRBuilderBase::InsertPointGuard) $6 = { Builder = 0x00007fff5fbf4440 Block = { llvm::ValueHandleBase = { PrevPair = (Value = 4337803886) Next = 0x0...
2017 Nov 06
2
[RFC] Setting the current debug loc when the insertion point changes
...If so, I think that's workable, but it presents a difficult migration problem. There's an overload of SetInsertPoint which accepts a BasicBlock::iterator, so we'd have to detect that and write this in-line: IRB.SetInsertPoint(BB, IP, (IP != BB->end()) ? IP->getDebugLoc() : IBR.getCurrentDebugLocation()) I do like that this approach forces clients of IRBuilder to be intentional about setting debug locs, but it looks like it could get messy. Wdyt of adopting parts of both solutions? I.e, we'd have the following methods: // Transition API - SetInsertPointAndDebugLoc(BasicBlock *) - Set...
2017 Nov 06
2
[RFC] Setting the current debug loc when the insertion point changes
> On Nov 6, 2017, at 2:32 PM, Adrian Prantl <aprantl at apple.com> wrote: > > >> On Nov 6, 2017, at 2:19 PM, Vedant Kumar <vsk at apple.com> wrote: >> >> Hi everybody, >> >> I'm investigating some correctness issues with debug line table information in optimized code. I've noticed something problematic in IRBuilder. Setting the