search for: yipeefn

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

Did you mean: yipee
2010 Aug 17
4
[LLVMdev] clang: call extern function using JIT
hi, im creating a music application(image below). At the moment im using tcc compiler but im moving across to clang because of the improved compiler warnings. Can anyone please explain and show code so I can use clang's JIT to call functions in my application? Thanks. http://old.nabble.com/file/p29449300/51709341.jpeg -- View this message in context:
2010 Aug 18
0
[LLVMdev] clang: call extern function using JIT
...t32Ty (llvm::getGlobalContext()), std::vector<const llvm::Type*>(0, llvm::Type::getInt32Ty (llvm::getGlobalContext())), false); llvm::Function* f = llvm::Function::Create(ft, llvm::Function::ExternalLinkage, "yipee", Mod); EE->addGlobalMapping(f, yipee); llvm::Function *YipeeFn = Mod->getFunction("yipee"); if (!YipeeFn) { llvm::errs() << "'yipee' function not found in module.\n"; return 255; } // end code I have added ------------------------------------------------------------------------------------------- -- llvm::Functi...
2010 Aug 18
1
[LLVMdev] clang: call extern function using JIT
...:getInt32Ty(llvm::getGlobalContext()), std::vector<const llvm::Type*>(0, llvm::Type::getInt32Ty(llvm::getGlobalContext())), false); llvm::Function* f = llvm::Function::Create(ft, llvm::Function::ExternalLinkage, "yipee", Mod); EE->addGlobalMapping(f, yipee); llvm::Function *YipeeFn = Mod->getFunction("yipee"); if (!YipeeFn) { llvm::errs() << "'yipee' function not found in module.\n"; return 255; } // end code I have added --------------------------------------------------------------------------------------------- llvm::Function *...
2010 Aug 18
1
[LLVMdev] clang: call extern function using JIT
...:getGlobalContext()), std::vector<const llvm::Type*>(1, llvm::Type::getInt32Ty(llvm::getGlobalContext())), false); llvm::Function* F = llvm::Function::Create(ft, llvm::Function::ExternalLinkage, "yipee", Mod); EE->addGlobalMapping(F, (void*)(intptr_t)yipee); llvm::Function *YipeeFn = Mod->getFunction("yipee"); if (!YipeeFn) { llvm::errs() << "'yipee' function not found in module.\n"; return 255; } // end code I have added --------------------------------------------------------------------------------------------- llvm::Function *...
2010 Aug 17
0
[LLVMdev] clang: call extern function using JIT
On Aug 17, 2010, at 1:56 PM, gafferuk wrote: > > hi, im creating a music application(image below). > > At the moment im using tcc compiler but im moving across to clang because of > the improved compiler warnings. > Can anyone please explain and show code so I can use clang's JIT to call > functions in my application? You'll probably want to take a look at the
2010 Aug 18
0
[LLVMdev] clang: call extern function using JIT
I tried what you said, now I get: LLVM ERROR: Program used external function 'yipee' which could not be resolved! Stack dump: 0. Running pass 'X86 Machine Code Emitter' on function '@main' did not even get as far as a breakpoint. Óscar Fuentes wrote: > > gafferuk <gafferuk at gmail.com> writes: > >> Im confused. The function i wish to call is
2010 Aug 18
2
[LLVMdev] clang: call extern function using JIT
gafferuk <gafferuk at gmail.com> writes: > Im confused. The function i wish to call is a return type of int. > Im calling it with int dd = yipee(1); > > What's wrong? Declare the function: int yipee(int); int main() { int dd = yipee(1); return 0; } If that still crashes, put a breakpoint on `yipee' and see if the execution gets there, if the argument is