Remove version-pruning criteria based on pushed node count
This commit is contained in:
parent
fcffd4b732
commit
f93f78ef2d
2 changed files with 3 additions and 9 deletions
|
|
@ -2,7 +2,6 @@
|
|||
|
||||
static const unsigned MAX_COST_DIFFERENCE = 16 * ERROR_COST_PER_SKIPPED_TREE;
|
||||
static const unsigned MAX_PUSH_COUNT_WITH_COUNT_DIFFERENCE = 24;
|
||||
static const unsigned MAX_PUSH_COUNT_TO_ALLOW_MULTIPLE = 32;
|
||||
static const unsigned MAX_DEPTH_TO_ALLOW_MULTIPLE = 12;
|
||||
|
||||
ErrorComparison error_status_compare(ErrorStatus a, ErrorStatus b, bool are_mergeable) {
|
||||
|
|
@ -45,17 +44,11 @@ ErrorComparison error_status_compare(ErrorStatus a, ErrorStatus b, bool are_merg
|
|||
}
|
||||
|
||||
if (a.count > 0) {
|
||||
if (a.push_count > MAX_PUSH_COUNT_TO_ALLOW_MULTIPLE ||
|
||||
b.push_count > MAX_PUSH_COUNT_TO_ALLOW_MULTIPLE ||
|
||||
a.depth > MAX_DEPTH_TO_ALLOW_MULTIPLE ||
|
||||
if (a.depth > MAX_DEPTH_TO_ALLOW_MULTIPLE ||
|
||||
b.depth > MAX_DEPTH_TO_ALLOW_MULTIPLE) {
|
||||
return a.depth <= b.depth ?
|
||||
ErrorComparisonTakeLeft :
|
||||
ErrorComparisonTakeRight;
|
||||
} else {
|
||||
return a.depth <= b.depth ?
|
||||
ErrorComparisonPreferLeft :
|
||||
ErrorComparisonPreferRight;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -30,8 +30,9 @@ h i j k;
|
|||
|
||||
(program
|
||||
(if_statement
|
||||
(ERROR (identifier) (identifier))
|
||||
(ERROR (identifier))
|
||||
(identifier)
|
||||
(ERROR (identifier))
|
||||
(statement_block
|
||||
(expression_statement
|
||||
(identifier)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue