similar to: [LLVMdev] Possible memory leak in LLVM 2.5

Displaying 20 results from an estimated 2000 matches similar to: "[LLVMdev] Possible memory leak in LLVM 2.5"

2010 May 18
0
[LLVMdev] Possible memory leak in LLVM 2.5
I'm unfamiliar with the leak you've just described, but Jeffrey Yasskin has done a lot of work cleaning up leaks for 2.7 and trunk. I was just going to mention that unless the function you are calling via runFunction has a simple prototype that's special cased in runFunction, it will generate its own stub function for every call. If you don't want to worry about that, you can call
2010 May 18
1
[LLVMdev] Possible memory leak in LLVM 2.5
Hi Reid, I guess it's not so much a memory leak, as unexpected behaviour, resulting in excessive memory use. I also call the following after EE->runFunction, which seems to clean up pretty nicely. EE->freeMachineCodeForFunction(stub); // Delete functions and IR. stub->deleteBody(); stub->eraseFromParent(); Rob. -----Original Message----- From: reid.kleckner at
2006 May 31
0
[LLVMdev] Adding an object to llc (analysis pass)
On Wed, 31 May 2006, Silken Tiger wrote: >> that requires a BasicBlockPass, it will fail the same was as when a >> ModulePass requires a FunctionPass. > void MParSchedule::getAnalysisUsage(AnalysisUsage &AU) const { > AU.setPreservesAll(); > } > > MParSchedule requires nothing and changes nothing. So hopefully the above code > represents this fact? Right
2011 Mar 15
10
[LLVMdev] Prevent unbounded memory consuption of long lived JIT processes
This series of patches address several issues causing memory usage to grow indefinetely on a long lived process. These are not convenional leaks -- memory would have been freed when the LLVM context or/and JIT engine is destroyed -- but for as long as they aren't the memory is usage effectively ubounded. The issues were found using valgrind with '--show-reachable=yes' option: 1.
2006 Jun 01
2
[LLVMdev] Adding an object to llc (analysis pass)
Hi > Right it does. However, does something *else* require MParSchedule? If > so, what? Ok, i am writing on a different backend based on the cbackend. The test usage of this pass looks like this: void getAnalysisUsage(AnalysisUsage &AU) const { AU.addRequired<LoopInfo>(); AU.addRequired<MParSchedule>(); AU.setPreservesAll(); } and then in the
2006 May 31
2
[LLVMdev] Adding an object to llc (analysis pass)
Hi Am Dienstag, 30. Mai 2006 19:21 schrieb Chris Lattner: > On Tue, 30 May 2006, Silken Tiger wrote: > > Everthing now compiles fine, but when running llc with invoking my own > > backend derived from the cbackend i get the following error: > > namespace llvm { > > class MParSchedule : public BasicBlockPass { > > public: > > > >
2004 Apr 24
0
[LLVMdev] cs326 mp help
Hi, First, please send any replies to me separately, as I am not on the list. I'm trying to run a very simple LLVM pass as a start on a class project. It compiles fine, but I get a runtime assertion when running the pass. I'll paste the error and cpp file below, but basically I'm being told that I haven't specified a required pass. However, I've looked at some example
2011 May 04
0
[LLVMdev] 2.9 segfault when requesting for both LoopInfo and DominatorTree analyses.
Hi Michael, hi Duncan, yesterday I stumbled over something that might be related. At least I could also just be doing some initialization wrong or something in this direction... In my case, I hit a segfault in PassInfo::isAnalysisGroup() after PassManager.add(myModulePass) is called. My setup seems fairly simple, the attached code should reproduce the error. Compile with g++ test.cpp
2011 May 04
1
[LLVMdev] 2.9 segfault when requesting for both LoopInfo and DominatorTree analyses.
Your constructor is not calling initializeTestMPPass(), and you're using RegisterPass which I think was deprecated in favor of INITIALIZE_PASS. You can look at, for example, lib/Transforms/Scalar/IndVarSimplify.cpp for examples of how to initialize, e.g. having "INITIALIZE_PASS_DEPENDENCY(LoopInfo)" sandwiched between BEGIN and END. Note that you'll want a forward declaration of
2008 Aug 19
0
[LLVMdev] Please help with LLVM C++ integration
Hi Kirill, Don't forget to add X86TargetMachine.obj (add to Additional Dependencies in Linker options, if you are using MSVS) otherwise LLVM will try and use Interpreter instead of JIT. Hope this helps, Rob. > -----Original Message----- > From: llvmdev-bounces at cs.uiuc.edu [mailto:llvmdev-bounces at cs.uiuc.edu] > On Behalf Of kirill havok > Sent: Wednesday, August 20, 2008
2005 Jul 29
1
[LLVMdev] How to define a pass requiring a register allocation pass?
How to define a MachineFunctionPass requireing one of the register allocation passes being executed first? Should there be a PassInfo for register allocation in Pass.h? Pass.h: namespace llvm { extern const PassInfo *PHIEliminationID; extern const PassInfo *TwoAddressInstructionPassID; extern const PassInfo *RegisterAllocationPassID; // <-- add this one? There are four
2007 Apr 25
2
[LLVMdev] ModulePass that requires FunctionPass
Hi Devang, You recently mentioned that the pass manager now allows a ModulePass to require a FunctionPass. I just tried it but ran into errors. Could you please take a look to see if I did anything wrong? Thanks! Basically I changed the HelloWorld sample pass to be a ModulePass and tried to use the LoopInfo pass inside the runOnModule routine. See below for the source code and error messages.
2008 Aug 19
7
[LLVMdev] Please help with LLVM C++ integration
Hi Gordon, I wrote a small example, but while running I get an error("Tied to execute an unknown external function"), where I am wrong? Thanks in advance. Kirill. int some_test_func( int ){ std::cout << "!!!!" << std::endl; return 8848; } int _tmain(int argc, _TCHAR* argv[]){ Module *M = new Module("test"); ExistingModuleProvider* MP = new
2013 Apr 12
2
[LLVMdev] Runtime exception in DominatorTree.getRootNode()
Hi all, I am trying to traverse a dominator tree and have encountered a weird runtime exception: Here's my simple code: virtual bool runOnFunction(Function &F) { DominatorTree& DT = getAnalysis<DominatorTree>(); * DomTreeNode* rootNode = DT.getRootNode();* return false. } Here's the documentation page:
2015 Feb 24
2
[LLVMdev] Removing contention in PassRegistry accesses to speed up compiles
Hi, We use LLVM libraries to compile C++ code and noticed slow downs when multiple threads of a process were compiling at once. *perf *indicated that most of the CPU time was spent in a spin lock, which was being locked/unlocked from llvm::PassRegistry::getPassInfo(). We read the relevant LLVM code and found out that PassRegistry is a ManagedStatic and is shared among all threads in case of a
2008 Dec 02
2
[LLVMdev] Error when using getAnalysis
Hi, I had a question about this as well. The documentation about writing a pass shows an example like what John wrote, calling a function pass within a module pass on a per function basis. However, if I code it that way, I still get the same error: opt: /x/jeffhao/llvm/llvm/include/llvm/PassAnalysisSupport.h:232: AnalysisType& llvm::Pass::getAnalysisID(const llvm::PassInfo*,
2013 Apr 12
0
[LLVMdev] Runtime exception in DominatorTree.getRootNode()
On 4/11/13 10:30 PM, Bill He wrote: > Hi all, > > I am trying to traverse a dominator tree and have encountered a weird > runtime exception: > > Here's my simple code: > > virtual bool runOnFunction(Function &F) { > DominatorTree& DT = getAnalysis<DominatorTree>(); > > * DomTreeNode* rootNode = DT.getRootNode();* > return false.
2016 Mar 23
2
Help with pass manager
Sorry in advance for the stupid question, i still don’t understand some concepts like passes. I took a piece of code from llc, and I used it to write a function that creates an object (or assembly) file from an IR module. It compiles without any problems. But program crashes when it reaches add() method of the pass manager. Can you help me figuring out what’s the problem please? here is my
2013 Apr 12
2
[LLVMdev] Runtime exception in DominatorTree.getRootNode()
Thanks for your reply, John. I am using opt to run my pass. Should opt by default link in the library? Would you please give me some idea on fixing it? Thanks! opt -load ../../../Debug+Asserts/lib/LLVMHello.dylib -hello < hello.bc > /dev/null My pass is just: #include "llvm/IR/Function.h" #include "llvm/Pass.h" #include "llvm/Support/raw_ostream.h" #include
2008 May 05
1
[LLVMdev] LoopInfo::isAnalysis() unused?
Hi, I was looking at the LoopInfo Analysis pass as an example, and found it defined the isAnalysis() method to return true. I assumed the method was overriden from some superclass (Pass, probably) and present in all analysis passes. However, a better look turns out that the method isn't really used anywhere. PassInfo does define the same method which is used, but PassInfo is not a superclass