search for: setupcost

Displaying 6 results from an estimated 6 matches for "setupcost".

2013 Mar 13
2
[LLVMdev] Suggestion About Adding Target Dependent Decision in LSR Please
...ddRecCost; if (NumIVMuls != Other.NumIVMuls) return NumIVMuls < Other.NumIVMuls; if (NumBaseAdds != Other.NumBaseAdds) return NumBaseAdds < Other.NumBaseAdds; if (ImmCost != Other.ImmCost) return ImmCost < Other.ImmCost; if (SetupCost != Other.SetupCost) return SetupCost < Other.SetupCost; return false; } If we have a case to compare Cost at 5 regs, with addrec cost 1, plus 15 base adds, plus 1 imm cost, plus 4 setup cost. Cost at 4 regs, with addrec cost 1, plus 28 base adds, plus 1 imm cost...
2013 Mar 14
3
[LLVMdev] Suggestion About Adding Target Dependent Decision in LSR Please
...eneral cost from TTI function, like virtual int getLSRFormulaCost(const unsigned NumRegs, const unsigned AddRecCost, const unsigned NumIVMuls, const unsigned NumBaseAdds, const unsigned ImmCost, const unsigned SetupCost) const; Then we do something like int thisCost = TTI->getLSRFormulaCost(NumRegs, AddRecCost, NumIVMuls, NumBaseAdds, ImmCost, SetupCost); if (thisCost >= 0) { int otherCost = TTI->getLSRFormulaCost(Other.NumRegs, Other.AddRecCost,...
2013 Mar 14
0
[LLVMdev] Suggestion About Adding Target Dependent Decision in LSR Please
...if (NumIVMuls != Other.NumIVMuls) return NumIVMuls < Other.NumIVMuls; > if (NumBaseAdds != Other.NumBaseAdds) return NumBaseAdds < Other.NumBaseAdds; > if (ImmCost != Other.ImmCost) return ImmCost < Other.ImmCost; > if (SetupCost != Other.SetupCost) return SetupCost < Other.SetupCost; > return false; > } > > If we have a case to compare > Cost at 5 regs, with addrec cost 1, plus 15 base adds, plus 1 imm cost, plus 4 setup cost. > Cost at 4 regs, with addrec cost 1, plus 28 ba...
2013 Mar 14
0
[LLVMdev] Suggestion About Adding Target Dependent Decision in LSR Please
...t; > > For case two, we can define a general cost from TTI function, like > > virtual int getLSRFormulaCost(const unsigned NumRegs, > > const unsigned AddRecCost, const unsigned NumIVMuls, > > const unsigned NumBaseAdds, const unsigned ImmCost, > > const unsigned SetupCost) const; > > Then we do something like > > int thisCost = TTI->getLSRFormulaCost(NumRegs, AddRecCost, NumIVMuls, > > NumBaseAdds, ImmCost, SetupCost); > > if (thisCost >= 0) { > > int otherCost = TTI->getLSRFormulaCost(Other.NumRegs, > Other.AddRecCost,...
2013 Mar 15
0
[LLVMdev] Problems about developing LLVM pass on windows visual studio
...virtual int getLSRFormulaCost(const unsigned NumRegs, > > const unsigned AddRecCost, const unsigned > NumIVMuls, > > const unsigned NumBaseAdds, const unsigned > ImmCost, > > const unsigned SetupCost) const; > > Then we do something like > > int thisCost = TTI->getLSRFormulaCost(NumRegs, AddRecCost, NumIVMuls, > > NumBaseAdds, ImmCost, > SetupCost); > > if (thisCost >= 0) { > > int otherCost = TTI->getL...
2018 May 01
0
LSR formula rating
...re check will disappear. There is no need to analyze these cases in LSR. In fact, completely ignoring them improves performance. Would it be reasonable to add a target hook to check if the target wants to ignore these? I suppose this could apply to other target with hardware loop support. 2. C.SetupCost What it the motivation behind this code? // Rough heuristic; favor registers which don't require extra setup // instructions in the preheader. if (!isa<SCEVUnknown>(Reg) && !isa<SCEVConstant>(Reg) && !(isa<SCEVAddRecExpr>(Reg) &&...