search for: machinefuncionpass

Displaying 4 results from an estimated 4 matches for "machinefuncionpass".

Did you mean: machinefunctionpass
2015 Feb 28
2
[LLVMdev] Getting basic block address offset from its parent function
Hi John Thanks for your suggestions, they all sound reasonable to me. The way I'm thinking right now is to write a MachineFuncionPass that iterate through each MachinBasicBlock, for each MBB, adds up the instructions counts of previous MBBs, that number multiply by 4 should be the offset of that MBB from its MachineFunction. In order to correctly count the instructions, this pass should be inserted after the last transform pass ....
2015 Mar 01
1
[LLVMdev] Getting basic block address offset from its parent function
On Sat, Feb 28, 2015 at 7:39 AM, Ziqiang Patrick Huang < ziqiang.huang1001 at gmail.com> wrote: > Hi John > > Thanks for your suggestions, they all sound reasonable to me. The way I'm > thinking right now is to write a MachineFuncionPass that iterate through > each MachinBasicBlock, for each MBB, adds up the instructions counts of > previous MBBs, that number multiply by 4 should be the offset of that MBB > from its MachineFunction. In order to correctly count the instructions, > this pass should be inserted after the l...
2015 Feb 28
0
[LLVMdev] Getting basic block address offset from its parent function
On 2/27/15 6:30 PM, Ziqiang Patrick Huang wrote: > Hi, all > > Is there a way of getting the basic block offset from its parent > function ? At the LLVM IR level, no. At the code generator layer (MachineFunctionPass layer or the MC layer), probably yes. > > What I'm trying to do is to get an execution count of each basic > blocks, so I need to know the starting
2015 Feb 27
2
[LLVMdev] Getting basic block address offset from its parent function
Hi, all Is there a way of getting the basic block offset from its parent function ? What I'm trying to do is to get an execution count of each basic blocks, so I need to know the starting address of each basic blocks. Obviously we can't get the absolute address before linking the program, but the offset relative to parent function should be available so I can take it and get the function