similar to: [LLVMdev] redundant checking of terminator in Verifier?

Displaying 20 results from an estimated 2000 matches similar to: "[LLVMdev] redundant checking of terminator in Verifier?"

2010 Mar 17
1
[LLVMdev] is structtyp a firstclass typ?
Hi LLVM, In lib/VMCare/Verifier.cpp::visitInstruction, we have such code 1287 // Check that the return value of the instruction is either void or a legal 1288 // value type. 1289 Assert1(I.getType() == Type::getVoidTy(I.getContext()) || 1290 I.getType()->isFirstClassType() 1291 || ((isa<CallInst>(I) || isa<InvokeInst>(I)) 1292 &&
2012 Dec 19
3
[LLVMdev] LLVM segmentation fault / need use Instruction instead of Instruction*
Hello everyone, I have a segmentation fault while running an LLVM pass. I need to use BBterminators array outside the iterating "for" loop for basic blocks. It seems that LLVM does not protect the addresses ( note: TerminatorInst *BasicBlock::getTerminator() ) when iterating through the loop, so I need to keep in BBterminators "Instruction" type elements, not
2011 Oct 14
0
[LLVMdev] BasicBlock succ iterator
Hi I have checked all blocks, each block have a Terminator instruction and each blocks belongs to a function. I'm really confused. I guess the problem is caused by the removal of the Loop,The code is as follows: * //every block to header (except the ones in the loop), will now redirect to newblock for (pred_iterator PI = pred_begin(header); PI != pred_end(header); ++PI) {
2012 Dec 17
0
[LLVMdev] BasicBlock back()
On 12/17/12 10:34 AM, Alexandru Ionut Diaconescu wrote: > Hello, > > I am a beginner of LLVM. I am trying to move among the instructions of > a BasicBlock and I cannot. In this particular example, I try to get > the previous instruction of the end instruction. I am trying 2 methods: > > > > 1. I have the following sequence of code: > > bool
2011 Oct 13
6
[LLVMdev] BasicBlock succ iterator
Hi, All I want to implement DSWP Which is used for parallelization of loops. For this purpose, the loop was replaced with a new basic block in main function. And new functions were created and basic blocks of Loop assigned to them.I have checked blocks and branches for Succ and Pred relation and I have not found any problems. However I get the following error: * **opt:
2012 Dec 18
1
[LLVMdev] BasicBlock back()
PS: I works when I use Instruction* prev = current->getPrevNode(); But then I have runtime error Stack dump that is very frequent... On Mon, Dec 17, 2012 at 6:20 PM, John Criswell <criswell at illinois.edu>wrote: > On 12/17/12 10:34 AM, Alexandru Ionut Diaconescu wrote: > > Hello, > > I am a beginner of LLVM. I am trying to move among the instructions of a >
2012 Nov 10
1
[LLVMdev] error: terminator in the middle of basic block
Hello, I modified the PathProfiling.cpp and run opt -inesrt-path-profiling. it works correctly ,but after path-profile is complete in Verifier::visitTerminatorInst it prints "Terminator found in the middle of a basic block!" . error is I added two basic blocks after return basic block and return has br label %newprint when printed in pathprofile module but in
2012 Dec 17
4
[LLVMdev] BasicBlock back()
Hello, I am a beginner of LLVM. I am trying to move among the instructions of a BasicBlock and I cannot. In this particular example, I try to get the previous instruction of the end instruction. I am trying 2 methods: 1. I have the following sequence of code: bool patternDC::runOnBasicBlock(BasicBlock &BB) { ... if (BB.getTerminator()) { Instruction* current =
2018 May 17
0
RFC: Removing TerminatorInst, simplifying calls
Hi, I'm curious how it would affect the getTerminator() method of a basic block? I.e., how would one find the terminating instruction in that case? By iterating over all of them or ...? Cheers, Alex. > On 17. May 2018, at 11:03, Chandler Carruth via llvm-dev <llvm-dev at lists.llvm.org> wrote: > > Going to keep this RFC short and to the point: > > TerminatorInst
2003 Nov 20
3
[LLVMdev] Basic Block Chaining
Newbie Question .. (sorry if its redundant/silly) .. As I've started to develop Stacker, I had assumed that simply adding BasicBlocks to a function in sequence would imply that there is an implicit unconditional branch from the end of one basic block to the start of the next block. Based on the assertion checks that I get when I tried this, I assume that it is required to place a terminating
2006 May 31
1
[LLVMdev] InstVisitor: RetType
Hi, the docs for InstVisitor say that if RetType != void, one has to override visitInstruction. What is the reason for that? It's valid to define visitInstruction like that: RetTy visitInstruction(Instruction &I) { return RetTy(); } so assuming RetTy has a sensible default constructor, user won't need to override visitInstruction. Note that the above will work when RetTy ==
2009 Jul 14
0
[LLVMdev] Profiling in LLVM Patch Followup 1
Hi Andreas, Thanks for breaking things up. I applied two pieces of this patch in separate no-functionality-change commits, here: http://llvm.org/viewvc/llvm-project?view=rev&revision=75623 and here: http://llvm.org/viewvc/llvm-project?view=rev&revision=75625 I merged in my changes to your patch, which results in the attached patch. There may be some missed merge errors. The main
2010 May 20
1
[LLVMdev] crash in 2.7: SCCPSolver::ResolvedUndefsIn
Are there any known issues with the ResolvedUndefsIn in 2.7? We've hit this particular stack a couple times now in the JIT. I've copied the failing bitcode to disk and doesn't crash opt or llc. It doesn't repro easily in the JIT either, but the stack is always the same... hoping it's a known issue. Thanks! TerminatorInst *TI = BB->getTerminator(); >>>>if
2015 Jan 19
2
[LLVMdev] [INCOMPLETE] [GC] Support wrapping vararg functions in statepoint
I actually need this feature quite badly in my untyped language compiler: since I support first-class functions, I've made the types of all functions a standard vararg (so I can box them). The implementation crashes when I try to read out the value of gc.result. Hints as to what might be wrong? Signed-off-by: Ramkumar Ramachandra <artagnon at gmail.com> ---
2009 May 08
0
[LLVMdev] Splitting a basic block, replacing it's terminator
On May 8, 2009, at 4:02 PM, Nick Johnson wrote: > I want to insert a conditional branch in the middle of a basic block. > To that end, I am doing these steps: > > (1) Split the basic block: > bb->splitBasicBlock() > > (2) Remove the old terminator: > succ->removePredecessor(bb) > bb->getTerminator()->getParent() Assuming that the new block will still be a
2005 Feb 13
1
[LLVMdev] Undefined references
Hi LLVMers, I can't figure out why these errors exits: ------------------------- llvm[2]: Linking Debug executable opt c:/projects/build/MinGW/llvm-4-1/Debug/lib/LLVMProfilePaths.o(.text$_ZN4llvm10BranchInstC1EPNS_10BasicBlockES2_+0x52): In function `ZN9__gnu_cxx13new_allocatorISt13_Rb_tree_nodeISt4pairIKPN4llvm8FunctionEPNS3_5GraphEEEE10deallocateEPSA_j':
2009 May 08
2
[LLVMdev] Splitting a basic block, replacing it's terminator
Hi, I want to insert a conditional branch in the middle of a basic block. To that end, I am doing these steps: (1) Split the basic block: bb->splitBasicBlock() (2) Remove the old terminator: succ->removePredecessor(bb) bb->getTerminator()->getParent() (3) Adding a new terminator: BranchInst::Create(ifTrue, ifFalse, cnd, "", bb); That seems to work, but later passes
2014 Mar 10
2
[LLVMdev] GlobalValues appear in their own use lists?
In the following IR module: – define i8 @foo() #0 { entry: %call0 = call i8 @bar() ret i8 %call0 } declare i8 @bar() #1 – @bar() gets marked as its own user in top-of-tree LLVM. I patched the Verifier to check it (but didn’t commit the patch): – Index: lib/IR/Verifier.cpp =================================================================== --- lib/IR/Verifier.cpp (revision 203468) +++
2019 Jan 02
2
Missing TerminatorInst in the trunk no. 350084
I stumbled upon a baffling error while compiling my pass. I was moving my development environment and updated LLVM to the trunk number 350084 in the meantime. [ 11%] Building CXX object lib/Transforms/TimePred/CMakeFiles/TimePred.dir/Common/Formatter.cpp.o /home/gwangmu/opt/llvm/lib/Transforms/TimePred/Common/Formatter.cpp:182:24: error: ‘TerminatorInst’ was not declared in this scope void
2018 May 17
15
RFC: Removing TerminatorInst, simplifying calls
Going to keep this RFC short and to the point: TerminatorInst doesn't pull its weight in the type system. There is essentially a single relevant API -- iterating successors. There is no other interesting aspect shared -- the interface itself just dispatches to specific instructions to be implemented. On the flip side, CallInst and InvokeInst have *massive* amounts of code shared and struggle