Simplify slightly in checkMaxBetweenExclusive
Some checks failed
Tests / Clang total: 2500, passed: 2500
Clang |Total|New|Outstanding|Fixed|Trend |:-:|:-:|:-:|:-:|:-: |0|0|0|0|:clap:
weaselab/conflict-set/pipeline/head There was a failure building this commit

This commit is contained in:
2024-08-17 14:28:36 -07:00
parent a3cc14c807
commit 3634b6a59b

View File

@@ -2340,10 +2340,8 @@ bool checkMaxBetweenExclusiveImpl(Node *n, int begin, int end,
int c = self->bitSet.firstSetGeq(begin + 1);
if (c >= 0 && c < end) {
auto *child = self->children[self->index[c]];
if (child->entryPresent) {
if (!(child->entry.rangeVersion <= readVersion)) {
return false;
};
if (child->entryPresent && child->entry.rangeVersion > readVersion) {
return false;
}
begin = c;
} else {
@@ -2376,10 +2374,8 @@ bool checkMaxBetweenExclusiveImpl(Node *n, int begin, int end,
int c = self->bitSet.firstSetGeq(begin + 1);
if (c >= 0 && c < end) {
auto *child = self->children[c];
if (child->entryPresent) {
if (!(child->entry.rangeVersion <= readVersion)) {
return false;
};
if (child->entryPresent && child->entry.rangeVersion > readVersion) {
return false;
}
begin = c;
} else {
@@ -2422,9 +2418,7 @@ bool checkMaxBetweenExclusiveImpl(Node *n, int begin, int end,
}
}
// Check inner pages
const int innerPageBegin = (begin >> Node256::kMaxOfMaxShift) + 1;
const int innerPageEnd = (end - 1) >> Node256::kMaxOfMaxShift;
return scan16<kAVX512>(self->maxOfMax, innerPageBegin, innerPageEnd,
return scan16<kAVX512>(self->maxOfMax, firstPage + 1, lastPage,
readVersion);
}
default: // GCOVR_EXCL_LINE