search for: regallocloc

Displaying 20 results from an estimated 30 matches for "regallocloc".

Did you mean: regalloclocal
2008 Feb 07
1
[LLVMdev] [PATCH] fix warning: 'NumFolded' defined but not used
lib/CodeGen/RegAllocLocal.cpp:38: warning: 'NumFolded' defined but not used This has been introduced because of r46821. However, maybe removing just the variable isn't enought, because the comments in the section that got modified by 46821 are not optimal: if (PhysReg) { // Register is available, alloca...
2007 Nov 06
1
[LLVMdev] Question about register allocators
What is the status of RegAllocLocal, RegAllocBigBlock and RegAllocSimple allocators? I am considering using one of them as a basis for a course project on register allocation in my class. In particular, are those allocators in regular use and/or have they been tested recently? I am particularly interested in the code as...
2006 May 23
4
[LLVMdev] Spilling register and frame indices
...be to add a method to MRegisterInfo to spill specific virtual register. The implementation can then create code like: virtual_register = frame_pointer + offset [virtual_register] and then have 'virtual_register' allocated on next iteration of register allocator? Also, while RegAllocLocal and RegAllocSimple directly call storeRegToStackSlot, I would not found any calls to that method in RegAllocLinearScan. Am I missing something? - Volodya
2006 Aug 21
0
[LLVMdev] Recalculating live intervals
..., x add phys_1 := phys_v, phys_2 In order to insert load/store instructions, you can use the VirtRegMap class. The spiller, that is implemented in VirtRegMap.cpp will do that. For an example, see RegAllocLinearscan.cpp. Another way is to insert the load/store instructions yourself. This is done in RegAllocLocal.cpp, for example. Best, Fernando
2006 Sep 09
1
[LLVMdev] Help with pass registration
...> > errors like this one below when I write new passes: > > What does your getAnalysisUsage method look like? > Chris, I think I've figured the problem out. I have a very basic question though. What is the difference between addRequired, and addRequiredID? For instance, in RegAllocLocal.cpp, you have both: AU.addRequired<LiveVariables>(); AU.addRequiredID(PHIEliminationID); When should I use one, and when the other should be used? Thanks a lot, Fernando
2006 May 15
1
[LLVMdev] Re: MRegisterInfo::storeRegToStackSlot question
...n about the spill. In > particular, it specifies the register class to use for the copy. I'm still missing something. The 'storeRegToStackSlot' saves 'SrcReg' (already specified) to stack (which is not a register). So, what does this register class applies to? Examining RegAllocLocal.cpp suggests that the argument actually specifies the register class of the spilled virtual register. Can you give some examples how that information can be helpful? I'd like to send doc patch, but can't do that without understanding the semantics ;-) - Volodya
2006 Aug 23
1
[LLVMdev] Recalculating live intervals
...phys_2 > > In order to insert load/store instructions, you can use the VirtRegMap > class. The spiller, that is implemented in VirtRegMap.cpp will do that. > For an example, see RegAllocLinearscan.cpp. Another way is to insert > the load/store instructions yourself. This is done in RegAllocLocal.cpp, > for example. By the by, I don't remember whether you are inserting spills yourself or not, but you really should try to not do that if you are. It's much better to have an interface that knows how to spill things in a good way, and how to place code for spills, and just use th...
2006 May 23
0
[LLVMdev] Spilling register and frame indices
...virtual_register] > > and then have 'virtual_register' allocated on next iteration of register > allocator? This is one approach. Another approach is to have to spiller scavange registers, which is the subject of this enhancement request: http://llvm.org/PR768 > Also, while RegAllocLocal and RegAllocSimple directly call > storeRegToStackSlot, I would not found any calls to that method in > RegAllocLinearScan. Am I missing something? RegAllocLinearScan just does register assignment, then the code in VirtRegMap.cpp (poorly named) actually takes the register assignment and...
2006 Apr 29
2
[LLVMdev] Register allocation in LLVM
...39;05" in LLVM. This is a graph coloring algorithm that can find an optimal coloring of the interference graph in most of the cases. I've downloaded LLVM last week, and started studying the code. Basically, I have to implement: 1) A new register allocation pass, similar to the class RA in RegAllocLocal.cpp, for instance; 2) Replace the phi deconstruction algorithm, which I found in the class PNE (PHIElimination.cpp); I would like to implement an algorithm that uses XOR instructions instead of copy instructions to destroy phi functions. It is the algorithm described in "Optimal register al...
2006 Aug 21
3
[LLVMdev] Recalculating live intervals
I'm not sure about one thing: you assign stack slot to each new register you replace the spilled one with. And then you need to allocate physical registers to them. Is it possible to assign physical register to the virtual one which has a stack slot already? On 8/21/06, Fernando Magno Quintao Pereira <fernando at cs.ucla.edu> wrote: > > > > So what addIntervalsToSpills
2007 Jul 13
0
[LLVMdev] [PATCH] Re: Pluggable Register Coalescers
...vals>(); + RegisterCoalescer &coalescer = getAnalysis<RegisterCoalescer>(); + + coalescer.invoke(fn, *this); + // If this is the first function compiled, compute the related reg classes. if (RelatedRegClasses.empty()) ComputeRelatedRegClasses(); Index: llvm/lib/CodeGen/RegAllocLocal.cpp =================================================================== --- llvm/lib/CodeGen/RegAllocLocal.cpp (revision 58818) +++ llvm/lib/CodeGen/RegAllocLocal.cpp (working copy) @@ -21,6 +21,7 @@ #include "llvm/CodeGen/MachineFrameInfo.h" #include "llvm/CodeGen/LiveVariables....
2006 May 01
0
[LLVMdev] Register allocation in LLVM
...n optimal coloring > of the interference graph in most of the cases. I've downloaded LLVM last > week, and started studying the code. Cool, that looks like a nice algorithm! > Basically, I have to implement: > > 1) A new register allocation pass, similar to the class RA in > RegAllocLocal.cpp, for instance; Yup. > 2) Replace the phi deconstruction algorithm, which I found in the class > PNE (PHIElimination.cpp); I would like to implement an algorithm that > uses XOR instructions instead of copy instructions to destroy phi > functions. It is the algorithm described in...
2007 Jul 11
3
[LLVMdev] Pluggable Register Coalescers
On Jul 11, 2007, at 11:39 AM, David Greene wrote: > On Wednesday 11 July 2007 12:41, Tanya M. Lattner wrote: > >> I think the coalescer should be flexible enough to be run >> independent of >> the register allocator. For example, you may want to expose the >> copies >> induced by transforming out of SSA to the scheduler. If the >> scheduler is
2006 Aug 14
2
[LLVMdev] Folding instructions
Dear LLVMers, I am trying to fold memory operands in the way that is done in RegAllocLocal.cpp, or in LiveIntervalAnalysis.cpp, but I am getting errors that I don't know how to fix. Could someone tell me which steps should I take in order to correctly fold memory operands? The code that I am using is: const TargetMachine & target_machine = this->machine_function->getTarg...
2006 May 01
0
[LLVMdev] Re: Question about modifying LLVM
...a wrote: > I am trying to use LLVM to implement one register allocation > algorithm. I think I understand the code, and I've started my > implementation. But I am having a problem, mostly due to my ignorance of > C++. I am basically modifying the code of > llvm/lib/CodeGen/RegAllocLocal.cpp. But if I type 'gmake' in that > directory, the changes are not reflected in the llc tool, even though > the LLVMCodeGen.o library is updated. In order to see my changes, You need to relink llc to see the changes. > what I am doing is to go to llvm/ , and then to 'gma...
2006 May 13
2
[LLVMdev] MRegisterInfo::storeRegToStackSlot question
Hi, in LLVM CVS the afore-mentioned function has 'const TargetRegisterClass*' parameter, that is not documented. Can somebody explain what does it mean? Thanks, Volodya
2006 May 14
0
[LLVMdev] MRegisterInfo::storeRegToStackSlot question
On Sat, 13 May 2006, Vladimir Prus wrote: > in LLVM CVS the afore-mentioned function has 'const TargetRegisterClass*' > parameter, that is not documented. > > Can somebody explain what does it mean? Basically, it gives the target more information about the spill. In particular, it specifies the register class to use for the copy. The target can choose to ignore this if it
2006 May 24
1
[LLVMdev] Re: Spilling register and frame indices
...is one approach. Another approach is to have to spiller scavange > registers, which is the subject of this enhancement request: > http://llvm.org/PR768 Can you given some references for this "scavange" thing? Google and ResearchIndex are silent on the topic. >> Also, while RegAllocLocal and RegAllocSimple directly call >> storeRegToStackSlot, I would not found any calls to that method in >> RegAllocLinearScan. Am I missing something? > > RegAllocLinearScan just does register assignment, then the code in > VirtRegMap.cpp (poorly named) actually takes the reg...
2006 Sep 09
2
[LLVMdev] Help with pass registration
Dear guys, I have updated my LLVM to the top of CVS, and now I am getting errors like this one below when I write new passes: "llc: PassManagerT.h:387: void llvm::PassManagerT<Trait>::markPassUsed(const llvm::PassInfo*, llvm::Pass*) [with Trait = llvm::FTraits]: Assertion `getAnalysisOrNullUp(P) && dynamic_cast<ImmutablePass*>(getAnalysisOrNullUp(P)) &&
2006 Sep 09
0
[LLVMdev] Help with pass registration
On Fri, 8 Sep 2006, Fernando Magno Quintao Pereira wrote: > I have updated my LLVM to the top of CVS, and now I am getting > errors like this one below when I write new passes: What does your getAnalysisUsage method look like? -Chris > "llc: PassManagerT.h:387: void > llvm::PassManagerT<Trait>::markPassUsed(const llvm::PassInfo*, > llvm::Pass*) [with Trait =