search for: verifymodule

Displaying 20 results from an estimated 77 matches for "verifymodule".

2012 Jun 11
2
[LLVMdev] Why always abort in verifyFunction?
Hello everyone: I have a little question about the second argument *action* of verifyFunction. In docs: *Enumerator: * *AbortProcessAction* verifyModule will print to stderr and abort() *PrintMessageAction* verifyModule will print to stderr and return true *ReturnStatusAction* verifyModule will just return true But it still abort when I pass PrintMessageAction/ReturnStatusAction to function. Log: Basic Block in function 'jit...
2007 Feb 22
3
[LLVMdev] opt -verify
I followed what you said and called verifyModule() with the AbortProcessAction option. verifyModule() returns false, but does not abort and does not print out any information about what caused the verification to fail. Chris Lattner wrote: > On Wed, 21 Feb 2007, Ryan M. Lefever wrote: >> I am writing an interprocedural compiler pass...
2007 Feb 22
0
[LLVMdev] opt -verify
I also tried iterating through the functions of the module and calling verifyFunction(), which also returns false, but does not cause an abort or report anything to stderr about what caused the verification to fail. From the doxygen for verifyFunction() and verifyModule(), it seems like they both should print information to stderr if the verification fails and should abort opt if AbortProcessAction is passed as parameter. Is this a bug? Ryan M. Lefever wrote: > I followed what you said and called verifyModule() with the > AbortProcessAction option. v...
2007 Feb 22
1
[LLVMdev] opt -verify
I think I misread the doxygen. verifyFunction & verifyModule return false if no errors are detected. However, my question now becomes why does the code produced by my transform pass verification, but it causes an assertion failure in the byte reader when it (the code produced by my transform) is passed to another invocation of opt? Ryan M. Lefever wrot...
2012 Jun 11
0
[LLVMdev] Why always abort in verifyFunction?
...t if you so wish. Joey On 11 June 2012 09:41, Guowei Xu <myesis at gmail.com> wrote: > Hello everyone: > > I have a little question about the second argument *action* of > verifyFunction. > > In docs: > > *Enumerator: * *AbortProcessAction* > > verifyModule will print to stderr and abort() > *PrintMessageAction* > > verifyModule will print to stderr and return true > *ReturnStatusAction* > > verifyModule will just return true > > But it still abort when I pass > PrintMessageAction/ReturnStatusAction to function. &gt...
2017 Jun 24
1
musttail & alwaysinline interaction
...ret void } attributes #0 = { alwaysinline } Clearly, if this is processed with opt -alwaysinline, it will lead to a correct tail call since the call to "tobeinlined" will be inlined. However, because opt checks for the correctness of the module when it is being loaded, it fails the verifyModule() check with: cannot guarantee tail call due to mismatched parameter counts musttail call fastcc void @tailcallee(i32 3) opt: prelude.inlined.ll: error: input module is broken! These are just experiment, but I suspect that I will have the same problem when I am constructing IR with the LLVM AP...
2017 Mar 12
2
What does it mean by a "DICompileUnit missing from llvm.dgs.cu" ? | Where is the error ?
...wing error, > > DICompileUnit not listed in llvm.dbg.cu > > !11 = distinct !DICompileUnit(language: DW_LANG_C89, file: !3, producer: > > "julia", isOptimized: true, runtimeVersion: 0,emissionKind: FullDebug, > > enums: !12) > > > > This was generated by verifyModule(*GPUModule,&(llvm::errs())From whithin > > PPCGCodeGeneration.cpp in Polly. > > > > From <llvm_src>/test/Verifier/dbg-orphaned-compileunit.ll, I understand > > that the debug info, of a compile unit, represented by !11 is missing from > > llvm.dbg.cu. > &g...
2007 Dec 26
2
[LLVMdev] Instantiating modules from .bc files
...de: MemoryBuffer* memBuf = MemoryBuffer::getFile(filename, sizeof filename, &errStr); printf("errStr: %s\n", errStr.c_str()); BitcodeReader::BitcodeReader bcReader(memBuf); Module* Mod = bcReader.materializeModule(&errInfo); printf("errInfo: %s\n", errInfo.c_str()); verifyModule(*Mod, PrintMessageAction); The errStr and the errInfo strings were empty, but I got a crash on the verifyModule call. The filename was produced by running "llvm-gcc -c -emit-llvm tmp.cpp" on the file tmp.cpp, which just contains: #include <stdio.h> typedef struct _whatever {...
2013 Jun 27
2
[LLVMdev] Problem with linking modules which use a shared type
...); FunctionType* ft = FunctionType::get( Type::getVoidTy( context ), types, false ); // m1 Function* f = Function::Create( ft, GlobalValue::ExternalLinkage, "f", m1 ); b = BasicBlock::Create( context, "b", f ); ReturnInst::Create( context, b ); verifyModule(*m1); // m2 Function* fDecl = Function::Create( ft, GlobalValue::ExternalLinkage, "f", m2 ); Function* h = Function::Create( ft, GlobalValue::ExternalLinkage, "h", m2 ); vector<Value*> args; args.push_back( h->arg_begin() ); b = BasicBlo...
2006 May 05
1
[LLVMdev] ExecutionEngine blew the stack ?
On Fri, 5 May 2006 16:43:13 +1000 Simon Burton <simon at arrowtheory.com> wrote: > > It slows in the construction phase, so one of these calls: > M = ParseAssemblyString(AsmString, M); > verifyModule( *M ) > M->getNamedFunction(name); > EE->getPointerToFunction > > It feels like there is a linear name lookup going on somewhere. it's verifyModule (of course). As the module grows, it takes longer to verify. So, I will disable this for now. Simon. -- Simon Burton,...
2012 May 09
0
[LLVMdev] Calling C-language variadic functions
...function in the asm dump, and also in the generated code, but > the code (x86_64) doesn't seem to have enough activity going on at the > call site (and I get a possibly predictable "illegal instruction" abort > when I try to run the code). I guess that you are not using `verifyModule' before generating the native code, because the sort of declaration/call mismatch you are experiencing is detected there. Or you are calling the external vaarg function with the same number of parameters listed on the faulty declaration, in which case `verifyModule' has no reason for compla...
2012 May 09
2
[LLVMdev] Calling C-language variadic functions
Such as printf, etc., from IR created using the API (IRBuilder). Google hasn't provided much help, and I can't find anything relevant in the docs (the docs talk about how to do varargs in LLVM ASM, but not how to call an external vararg function that exists in a library that gets linked to the LLVM module). Is there something special I need to do? Simply calling
2013 Jun 28
0
[LLVMdev] Problem with linking modules which use a shared type
...:get( Type::getVoidTy( context ), > types, false ); > > // m1 > Function* f = Function::Create( ft, GlobalValue::ExternalLinkage, "f", > m1 ); > > b = BasicBlock::Create( context, "b", f ); > ReturnInst::Create( context, b ); > > verifyModule(*m1); > > // m2 > Function* fDecl = Function::Create( ft, GlobalValue::ExternalLinkage, > "f", m2 ); > Function* h = Function::Create( ft, GlobalValue::ExternalLinkage, "h", > m2 ); > > vector<Value*> args; > args.push_back( h...
2007 Dec 26
0
[LLVMdev] Instantiating modules from .bc files
...yBuffer::getFile(filename, sizeof > filename, &errStr); > printf("errStr: %s\n", errStr.c_str()); > BitcodeReader::BitcodeReader bcReader(memBuf); > Module* Mod = bcReader.materializeModule(&errInfo); > printf("errInfo: %s\n", errInfo.c_str()); > > verifyModule(*Mod, PrintMessageAction); > > The errStr and the errInfo strings were empty, but I got a crash on > the verifyModule call. Try this: #include "llvm/Bitcode/ReaderWriter.h" ... std::string &Message; llvm::Module* Mod = llvm::ParseBitcodeFile(MemBuf, &Message); if (...
2006 Apr 14
2
[LLVMdev] Re: standalone llvm
...mjit: llvmjit.o g++ llvmjit.o /home//users//simonb//lib/LLVMAsmParser.o /home//users//simonb//lib/LLVMInterpreter.o `llvm-config --ldflags` `llvm-config --libs jit` -lpthread -ldl -o llvmjit llvmjit.o: llvmjit.cpp g++ `llvm-config --cxxflags` -c llvmjit.cpp Complete source (i added a call to verifyModule): #include "llvm/Module.h" #include "llvm/Constants.h" #include "llvm/Type.h" #include "llvm/Instructions.h" #include "llvm/ModuleProvider.h" #include "llvm/ExecutionEngine/ExecutionEngine.h" #include "llvm/ExecutionEngine/JIT.h&quot...
2007 Dec 27
1
[LLVMdev] Instantiating modules from .bc files
...izeof >> filename, &errStr); >> printf("errStr: %s\n", errStr.c_str()); >> BitcodeReader::BitcodeReader bcReader(memBuf); >> Module* Mod = bcReader.materializeModule(&errInfo); >> printf("errInfo: %s\n", errInfo.c_str()); >> >> verifyModule(*Mod, PrintMessageAction); >> >> The errStr and the errInfo strings were empty, but I got a crash >> on the verifyModule call. > > > Try this: > > #include "llvm/Bitcode/ReaderWriter.h" > > ... > > std::string &Message; > llvm::Module*...
2017 Mar 11
2
What does it mean by a "DICompileUnit missing from llvm.dgs.cu" ? | Where is the error ?
...One of my Julia programs failed to execute with the following error, DICompileUnit not listed in llvm.dbg.cu !11 = distinct !DICompileUnit(language: DW_LANG_C89, file: !3, producer: "julia", isOptimized: true, runtimeVersion: 0,emissionKind: FullDebug, enums : !12) This was generated by verifyModule(*GPUModule,&(llvm::errs())From whithin PPCGCodeGeneration.cpp in Polly. >From <llvm_src>/test/Verifier/dbg-orphaned-compileunit.ll, I understand that the debug info, of a compile unit, represented by !11 is missing from llvm.dbg.cu. What does this mean ? What could have caused this p...
2006 Apr 13
0
[LLVMdev] Re: standalone llvm
Simon Burton <simon at arrowtheory.com> writes: > I'm trying to take assembly and create machine code I can execute. > How close am I ? Your test case is not complete. Besides, which version of llvm are you using? What are the commands for compiling and linking your test case? How it bombs? Do you #include "llvm/ExecutionEngine/JIT.h" ? -- Oscar
2006 May 05
2
[LLVMdev] ExecutionEngine blew the stack ?
On Fri, 5 May 2006, Simon Burton wrote: > This leads me to my next question: as I make more and more functions > with the EE, it slows down. I am re-using the Module, ExistingModuleProvider, > and ExecutionEngine, and pumping the parser like so: > M = ParseAssemblyString(AsmString, M); > ISTM that there should be a way of creating multiple modules/EEs but I ran > into trouble
2006 May 05
0
[LLVMdev] ExecutionEngine blew the stack ?
...hould be a way of creating multiple modules/EEs but I ran > > into trouble when I tried that (some time ago). > > Can you quantify what you mean? How does it "slow down"? It slows in the construction phase, so one of these calls: M = ParseAssemblyString(AsmString, M); verifyModule( *M ) M->getNamedFunction(name); EE->getPointerToFunction It feels like there is a linear name lookup going on somewhere. (will be able to do report more thorough timings later) Simon. -- Simon Burton, B.Sc. Licensed PO Box 8066 ANU Canberra 2601 Australia Ph. 61 02 6249 6940 http:...