search for: getlazyirfilemodule

Displaying 8 results from an estimated 8 matches for "getlazyirfilemodule".

2011 Nov 11
2
[LLVMdev] Argument's types mismatch when creating CallInst.
Hello. I have an .bc, which defines @foo(%type* arg1, %type* arg2, %type* arg3). Firstly, i do this: runtimeModule = getLazyIRFileModule("runtime.bc", smd, llctx); then this: fooFunction = runtimeModule->getFunction("foo"); myType = runtimeModule->getTypeByName("type"); After that, i'm creating another module: myModule = new Module("My Module", llctx); and create some AllocaInst...
2017 Jun 19
2
JIT, LTO and @llvm.global_ctors: Looking for advise
...3. The resulting LLVM module is compiled and dynamically loaded. We are currently using the MCJIT API, but are planning to move to ORC very soon. Our LLVM module linking code goes roughly as follows: Linker linker(jittedModule); std::unique_ptr<llvm::Module> moduleToLink( getLazyIRFileModule(bcFileName, error, context)); linker.linkInModule(std::move(module), Linker::LinkOnlyNeeded | Linker::InternalizeLinkedSymbol); Our issue is with the Linker::LinkOnlyNeeded flag. Using it has a huge positive impact on link and compilation time :-). But...
2016 Sep 14
2
setDataLayout segfault
...the builder's constructor and use the copy later on. It is confusing to require a unique_ptr. Frank On 09/14/2016 12:11 PM, Frank Winter via llvm-dev wrote: > I am constructing the engine builder in the following way: > > llvm::SMDiagnostic Err; > unique_ptr<Module> Mod = getLazyIRFileModule("f.ll", Err, TheContext); > llvm::EngineBuilder engineBuilder(std::move(Mod)); > > However, after moving the pointer to the constructor it is no longer > retrievable from the unique_ptr object. > > Mod.get()->dump(); // this segfaults after the move, but not before...
2016 Sep 14
4
setDataLayout segfault
I get a segfault with this code when setting the data layout: int main(int argc, char** argv) { llvm::InitializeNativeTarget(); llvm::LLVMContext TheContext; unique_ptr<Module> Mod(new Module("A",TheContext)); llvm::EngineBuilder engineBuilder(std::move(Mod)); std::string mcjit_error; engineBuilder.setMCPU(llvm::sys::getHostCPUName());
2017 Jun 20
2
JIT, LTO and @llvm.global_ctors: Looking for advise
...compiled and dynamically loaded. We > are currently using the MCJIT API, but are planning to move to ORC > very soon. > >Our LLVM module linking code goes roughly as follows: > > Linker linker(jittedModule); > std::unique_ptr<llvm::Module> moduleToLink( > getLazyIRFileModule(bcFileName, error, context)); > linker.linkInModule(std::move(module), > Linker::LinkOnlyNeeded | > Linker::InternalizeLinkedSymbol); > >Our issue is with the Linker::LinkOnlyNeeded flag. Using it has a huge >positive impact on link and c...
2011 Nov 11
0
[LLVMdev] Argument's types mismatch when creating CallInst.
On Fri, Nov 11, 2011 at 12:18 AM, arrowdodger <6yearold at gmail.com> wrote: > Hello. I have an .bc, which defines @foo(%type* arg1, %type* arg2, %type* > arg3). > Firstly, i do this: > > runtimeModule = getLazyIRFileModule("runtime.bc", smd, llctx); > > then this: > > fooFunction = runtimeModule->getFunction("foo"); > myType = runtimeModule->getTypeByName("type"); > > After that, i'm creating another module: > > myModule = new Module("My Module&q...
2017 Jun 20
2
JIT, LTO and @llvm.global_ctors: Looking for advise
.... We >> are currently using the MCJIT API, but are planning to move to ORC >> very soon. >> >>Our LLVM module linking code goes roughly as follows: >> >> Linker linker(jittedModule); >> std::unique_ptr<llvm::Module> moduleToLink( >> getLazyIRFileModule(bcFileName, error, context)); >> linker.linkInModule(std::move(module), >> Linker::LinkOnlyNeeded | >> Linker::InternalizeLinkedSymbol); >> >>Our issue is with the Linker::LinkOnlyNeeded flag. Using it has a huge >>posit...
2014 Dec 19
2
[LLVMdev] [Patches][RFC] What to do about bitcode streaming.
Hi Rafael, We will try out your patch and check to see how it will fit. You also talked about "It might be even possible to drop the requirement for the size to be known: Replace the call to AtEndOfStream by just trying to read more and checking if it failed, but that is a bit more than I wanted to do for this." That is to remove some calls to getSize()? Is there any expectation that