[PATCH] [DebugInfo] Add debug locations to constant SD nodes continued

David Blaikie dblaikie at gmail.com
Fri May 8 13:00:51 PDT 2015


On Fri, May 8, 2015 at 12:57 PM, Sergey Dmitrouk <sdmitrouk at accesssoftek.com
> wrote:

> In http://reviews.llvm.org/D9604#169183, @dblaikie wrote:
>
> > FWIW I don't think LLVM has any rule that out/in parameters appear in
> any particular order (& even if it does' we could overload
> FindNodeOrInsertPos rather than having to add a default constructed
> DebugLoc() to so many call sites (at least at a glance it looks like a lot
> of them - what's the ratio/absolute number that are just passing the
> default?))
>
>
> 13 of 40 calls use `DebugLoc()`. I'm happy to change the calls if default
> argument/overload looks better in your opinion, just wasn't sure about
> intermixing in/out arguments.
>

How's about we just overload, then? (& assert that the right function is
called for the right kinds of things? (ie: assert that the 3 arg (the one
with DebugLoc) is called only for Constant/ConstantFP, and the 2 arg is
called for non-Constant/ConstantFP? Would that make sense))


>
>
> REPOSITORY
>   rL LLVM
>
> http://reviews.llvm.org/D9604
>
> EMAIL PREFERENCES
>   http://reviews.llvm.org/settings/panel/emailpreferences/
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150508/57031a81/attachment.html>


More information about the llvm-commits mailing list