[PATCH] Add profile writing capabilities for sampling profiles.
Diego Novillo
dnovillo at google.com
Wed Oct 29 17:54:35 PDT 2014
On Wed, Oct 29, 2014 at 3:03 PM, Justin Bogner <mail at justinbogner.com>
wrote:
>
> >> + /// LLVM context for diagnostics. If this is nil, messages are
> emitted
> >> + /// to errs().
> >> + const Module *M;
> >> Again, why do we need the errs() behaviour? Also, AFAICT (and according
> >> to the comment) M is only used for M.getContext() - why not store the
> >> "const LLVMContext &" instead?
> >
> > Yeah, using LLVMContext is a better alternative. My concern is
> > similar, however. Will I have an LLVMContext in llvm-profdata?
>
> I think you can just getGlobalContext() in llvm-profdata and pass that
> in. Other tools do something similar.
>
>
Thanks. That's useful. Done.
Diego.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20141029/09f5d47c/attachment.html>
More information about the llvm-commits
mailing list