Displaying 5 results from an estimated 5 matches for "asm_arguments".
2009 Aug 01
2
[LLVMdev] Inserting Instructions (pass)
Thank you Chris,
for your hint, but I am still too stupid. I tried two versions
asm_arguments.push_back(Type::VoidTy);
FunctionType *asm_type = FunctionType::get(Type::VoidTy, asm_arguments,
false);
Alternatively
FunctionType *asm_type = FunctionType::get(Type::VoidTy, std::vector<const
Type*>(), false);
. Can you give me a snippet of example code, or somebody else?
Tha...
2009 Jul 31
2
[LLVMdev] Inserting Instructions (pass)
...in my pass, which
FunctionType do I need for Inlineasm?
If I understand it right, I need a call instruction to insert the new
produced InlineAsm?
Thanks for help,
Michael
for (BasicBlock::iterator bi = i->begin(), be = i->end(); bi != be; ++bi){
std::vector<const Type*> asm_arguments;
FunctionType *asm_type = FunctionType::get(Type::VoidTy,
asm_arguments, false);
InlineAsm* au = new InlineAsm(asm_type ???,
"isync","~{dirflag},~{fpsr},~{flags}",true);
//CallInst* ae = new CallInst(au ??);
//Works fine...
2009 Jul 31
0
[LLVMdev] Inserting Instructions (pass)
...ot;()
nounwind
The thing your calling has type "void()*". You just pass "void()"
into the InlineAsm ctor.
-Chris
> ,
>
> Michael
>
> for (BasicBlock::iterator bi = i->begin(), be = i->end(); bi != be; +
> +bi){
> std::vector<const Type*> asm_arguments;
> FunctionType *asm_type =
> FunctionType::get(Type::VoidTy, asm_arguments, false);
> InlineAsm* au = new InlineAsm(asm_type ???,
> "isync","~{dirflag},~{fpsr},~{flags}",true);
> //CallInst* ae = new CallI...
2009 Aug 01
0
[LLVMdev] Inserting Instructions (pass)
On Jul 31, 2009, at 5:04 PM, Michael Graumann wrote:
> Thank you Chris,
> for your hint, but I am still too stupid. I tried two versions
>
> asm_arguments.push_back(Type::VoidTy);
> FunctionType *asm_type = FunctionType::get(Type::VoidTy,
> asm_arguments, false);
>
> Alternatively
>
> FunctionType *asm_type = FunctionType::get(Type::VoidTy,
> std::vector<const Type*>(), false);
>
> . Can you give me a snippet of e...
2009 Aug 01
1
[LLVMdev] Inserting Instructions (pass)
...ftrag von Chris Lattner
Gesendet: Samstag, 1. August 2009 07:24
An: LLVM Developers Mailing List
Betreff: Re: [LLVMdev] Inserting Instructions (pass)
On Jul 31, 2009, at 5:04 PM, Michael Graumann wrote:
Thank you Chris,
for your hint, but I am still too stupid. I tried two versions
asm_arguments.push_back(Type::VoidTy);
FunctionType *asm_type = FunctionType::get(Type::VoidTy, asm_arguments,
false);
Alternatively
FunctionType *asm_type = FunctionType::get(Type::VoidTy, std::vector<const
Type*>(), false);
. Can you give me a snippet of example code, or somebody else?
Than...