search for: addglobaladdress

Displaying 7 results from an estimated 7 matches for "addglobaladdress".

2018 Apr 13
0
How to create and insert a call MachineInstr?
...d to pass and return parameters. If you writie a .ll file that makes a call you should be able to see all these components in the generated MIR. > Therefore how can I set the callee function and the arguments of the function? For a direct call, you'd normally use MachineInstrBuilder's addGlobalAddress to set the callee. You have to emit separate moves and stores before the call to put the arguments in the correct registers and stack slots. Be careful not to clobber live registers! We can probably give a few more details (like the call instruction to use, and which registers pass parameters; may...
2018 Apr 13
2
How to create and insert a call MachineInstr?
Hi all, I am working on a project which needs to create and insert a MachineInstr which calls a function. But I don't know how to build it. The function has been declared in IR. I have used BuildMI to build a MachineInstr. But it seems that a call MachineInstr only has one parameter which is a register(%physreg44<imp-use>?). Therefore how can I set the callee function and the arguments
2018 Apr 13
2
How to create and insert a call MachineInstr?
...If you writie a .ll file that makes a call you should be able to see > all these components in the generated MIR. > > > Therefore how can I set the callee function and the arguments of the > function? > > For a direct call, you'd normally use MachineInstrBuilder's > addGlobalAddress to set the callee. You have to emit separate moves > and stores before the call to put the arguments in the correct > registers and stack slots. Be careful not to clobber live registers! > > We can probably give a few more details (like the call instruction to > use, and which regist...
2010 Nov 17
1
[LLVMdev] [llvm-commits] [patch] ARM/MC/ELF add new stub for movt/movw in ARMFixupKinds
+llvmdev -llvmcommits On Fri, Nov 12, 2010 at 8:03 AM, Jim Grosbach <grosbach at apple.com> wrote: > Sorta. getBinaryCodeForInst() is auto-generated by tablegen, so shouldn't be modified directly. The target can register hooks for instruction operands for any special encoding needs, including registering fixups, using the EncoderMethod string. For an example, have a look at the
2018 Sep 22
3
Quick question: How to BuildMI mov64mi32 arbitrary MMB address to memory
Dear Mr. Northover, Thank you for the quick reply. You are correct about the address-mode operands :) . I guess an important detail left out was that the basic block (call it A) that wants to calculate the address of the target stationary trampoline basic block (call it B) will be moved around in memory during run-time. Our earlier solution, before the feature was implemented to move around (A)
2018 Apr 17
0
How to create and insert a call MachineInstr?
...at makes a call you should be able to see >> all these components in the generated MIR. >> >> > Therefore how can I set the callee function and the arguments of the >> function? >> >> For a direct call, you'd normally use MachineInstrBuilder's >> addGlobalAddress to set the callee. You have to emit separate moves >> and stores before the call to put the arguments in the correct >> registers and stack slots. Be careful not to clobber live registers! >> >> We can probably give a few more details (like the call instruction to >> u...
2018 Sep 22
2
Quick question: How to BuildMI mov64mi32 arbitrary MMB address to memory
...re I am trying to save the hard coded address of an arbitrary machine basic block to memory in ASM. I know the assembly needed for this but am lost at how to construct the BuildMI(). Note that these machine basic blocks are not entry's to a function. but in the middle of the function. so using addGlobalAddress or addExternalSymbol are no use to me and am trying to avoid having to make a separate jump table section. Is a jump table section with symbols associated with these new basic blocks the only option? In x86 assembly this would look something like: MOVQ 0x40044540, 0x8(%rsp) # Store address...