mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-13 04:38:24 +00:00
[SimplifyCFG] Be more aggressive
Up the phi node folding threshold from a cheap "1" to a meagre "2". Update tests for extra added selects and slight code churn. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@229099 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -53,9 +53,13 @@ using namespace PatternMatch;
|
||||
|
||||
#define DEBUG_TYPE "simplifycfg"
|
||||
|
||||
// Chosen as 2 so as to be cheap, but still to have enough power to fold
|
||||
// a select, so the "clamp" idiom (of a min followed by a max) will be caught.
|
||||
// To catch this, we need to fold a compare and a select, hence '2' being the
|
||||
// minimum reasonable default.
|
||||
static cl::opt<unsigned>
|
||||
PHINodeFoldingThreshold("phi-node-folding-threshold", cl::Hidden, cl::init(1),
|
||||
cl::desc("Control the amount of phi node folding to perform (default = 1)"));
|
||||
PHINodeFoldingThreshold("phi-node-folding-threshold", cl::Hidden, cl::init(2),
|
||||
cl::desc("Control the amount of phi node folding to perform (default = 2)"));
|
||||
|
||||
static cl::opt<bool>
|
||||
DupRet("simplifycfg-dup-ret", cl::Hidden, cl::init(false),
|
||||
|
Reference in New Issue
Block a user