search for: shucai

Displaying 6 results from an estimated 6 matches for "shucai".

Did you mean: shuai
2016 Sep 05
2
How to insert instructions before each function calls?
...ction). Hope this helps. -- Dean > On 5 Sep 2016, at 00:23, Ryan Taylor via llvm-dev <llvm-dev at lists.llvm.org> wrote: > > Personally I would add a new pass that iterates, looks for the call you want then inserts the new instruction. > > > On Sep 4, 2016 10:20, "SHUCAI YAO" <yaos4 at mcmaster.ca> wrote: > > > On Sun, Sep 4, 2016 at 7:44 AM, Ryan Taylor <ryta1203 at gmail.com> wrote: > Mehdi, > > Sorry, I misread his original post. > > So something like: > > XXXInsrtInfo *XII; // target instruction info &...
2016 Sep 03
2
How to insert instructions before each function calls?
...allee_name I am a newbie to LLVM. I tried to use buildMI() to insert the instructions in the lowercall() function. But I couldn't put these instructions in the right positions. Is there a way to locate the position by using MachineBasicBlock iterator? Any suggestions are appreciated. Thanks! Shucai -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20160903/7a2f1c87/attachment.html>
2016 Sep 04
2
How to insert instructions before each function calls?
...rNewInstruction = builder.CreateInstructionClass(.....); // InstructionClass = type of instruction you are inserting -Ryan On Sat, Sep 3, 2016 at 6:04 PM, Ryan Taylor <ryta1203 at gmail.com> wrote: > Take a look at IRBuilder and SetInsertPoint(). > > On Sep 3, 2016 18:02, "SHUCAI YAO via llvm-dev" <llvm-dev at lists.llvm.org> > wrote: > >> I'm trying to insert some instructions before each function calls (before >> arguments push): >> lea %EAX, label ----- new instructions >> mov [ESP+stacksize], %EAX...
2016 Sep 04
1
How to insert instructions before each function calls?
...tParent()); >> Builder.SetInsertPoint(CallInst); >> InstructionClass *YourNewInstruction = builder.CreateInstructionClass(.....); >> // InstructionClass = type of instruction you are inserting >> >> >> I’m not sure how the IRBuilder would work at the MI level, as Shucai was >> asking. >> >> >> >> >> On Sat, Sep 3, 2016 at 6:04 PM, Ryan Taylor <ryta1203 at gmail.com> wrote: >> >>> Take a look at IRBuilder and SetInsertPoint(). >>> >>> On Sep 3, 2016 18:02, "SHUCAI YAO via llvm-dev"...
2016 Sep 06
2
How to insert instructions before each function calls?
> On 5 Sep 2016, at 16:14, SHUCAI YAO <yaos4 at mcmaster.ca> wrote: > > > Hi Dean, > > Do you have any example for this? I would like have a look at how you handle this in XRay if it is possible. > Yes, this is all upstream -- if you look in lib/CodeGen/XRayInstrument.cpp and the associated lowering c...
2016 Sep 05
2
How to insert instructions before each function calls?
> On 5 Sep 2016, at 11:49, SHUCAI YAO <yaos4 at mcmaster.ca> wrote: > > For the function call lowering, do you mean lowercall function? I did insert the instruction before the stack adjustments, but the inserted code appears in the prologue of the function, other than before the function call. Maybe I did something wro...