Hi John,
I don't think its possible to add/insert an inline assembly into the LLVM
IR unless the IR interface provides some kind of stream writer into which
inline instructions can be written into.
I was thinking having an LLVM intrinsic function could be a first step
towards introducing PMU tool support in LLVM with which you can generate
code with built-in instrumentation. What do you think ?
Sathvik
On Fri, Jun 20, 2014 at 8:21 AM, John Criswell <criswell at illinois.edu>
wrote:
> On 6/19/14, 7:12 PM, sathvik wrote:
>
> I want to measure the performance of a JITed code snippet on MCJIT.
> so I was planning to inject the RDPMC inst for the code generated through
> a llvm IR builder.
>
>
> I assume the easier way to do this is to add an inline assembly call that
> uses the RDPMC instruction. I don't think there's an LLVM IR
intrinsic
> function that does it.
>
> Regards,
>
> John Criswell
>
>
> Is there a patch available ? If there's a better way to do it please
> chime in.
>
> Thanks
> sathvik
>
>
> _______________________________________________
> LLVM Developers mailing listLLVMdev at cs.uiuc.edu
http://llvm.cs.uiuc.eduhttp://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://lists.llvm.org/pipermail/llvm-dev/attachments/20140620/e1985e03/attachment.html>