Fix build
All checks were successful
Tests / Clang total: 1533, passed: 1533
Clang |Total|New|Outstanding|Fixed|Trend
|:-:|:-:|:-:|:-:|:-:
|0|0|0|0|:clap:
Tests / Debug total: 1531, passed: 1531
Tests / SIMD fallback total: 1533, passed: 1533
Tests / Release [gcc] total: 1533, passed: 1533
GNU C Compiler (gcc) |Total|New|Outstanding|Fixed|Trend
|:-:|:-:|:-:|:-:|:-:
|0|0|0|0|:clap:
Tests / Release [gcc,aarch64] total: 1144, passed: 1144
Tests / Coverage total: 1151, passed: 1151
Code Coverage #### Project Overview
No changes detected, that affect the code coverage.
* Line Coverage: 98.71% (1680/1702)
* Branch Coverage: 64.50% (1508/2338)
* Complexity Density: 0.00
* Lines of Code: 1702
#### Quality Gates Summary
Output truncated.
weaselab/conflict-set/pipeline/head This commit looks good
All checks were successful
Tests / Clang total: 1533, passed: 1533
Clang |Total|New|Outstanding|Fixed|Trend
|:-:|:-:|:-:|:-:|:-:
|0|0|0|0|:clap:
Tests / Debug total: 1531, passed: 1531
Tests / SIMD fallback total: 1533, passed: 1533
Tests / Release [gcc] total: 1533, passed: 1533
GNU C Compiler (gcc) |Total|New|Outstanding|Fixed|Trend
|:-:|:-:|:-:|:-:|:-:
|0|0|0|0|:clap:
Tests / Release [gcc,aarch64] total: 1144, passed: 1144
Tests / Coverage total: 1151, passed: 1151
Code Coverage #### Project Overview
No changes detected, that affect the code coverage.
* Line Coverage: 98.71% (1680/1702)
* Branch Coverage: 64.50% (1508/2338)
* Complexity Density: 0.00
* Lines of Code: 1702
#### Quality Gates Summary
Output truncated.
weaselab/conflict-set/pipeline/head This commit looks good
This commit is contained in:
@@ -1715,17 +1715,17 @@ struct SearchStepWise {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
void onPointRead(ConflictSet::Impl *impl);
|
thread_local double accume_point_read = 0;
|
||||||
void onPrefixRead(ConflictSet::Impl *impl);
|
thread_local double accume_prefix_read = 0;
|
||||||
void onRangeRead(ConflictSet::Impl *impl);
|
thread_local double accume_range_read = 0;
|
||||||
void onCheckMaxBetween(ConflictSet::Impl *impl);
|
thread_local double accume_max_between = 0;
|
||||||
|
|
||||||
// Logically this is the same as performing firstGeq and then checking against
|
// Logically this is the same as performing firstGeq and then checking against
|
||||||
// point or range version according to cmp, but this version short circuits as
|
// point or range version according to cmp, but this version short circuits as
|
||||||
// soon as it can prove that there's no conflict.
|
// soon as it can prove that there's no conflict.
|
||||||
bool checkPointRead(Node *n, const std::span<const uint8_t> key,
|
bool checkPointRead(Node *n, const std::span<const uint8_t> key,
|
||||||
InternalVersionT readVersion, ConflictSet::Impl *impl) {
|
InternalVersionT readVersion, ConflictSet::Impl *impl) {
|
||||||
onPointRead(impl);
|
++accume_point_read;
|
||||||
#if DEBUG_VERBOSE && !defined(NDEBUG)
|
#if DEBUG_VERBOSE && !defined(NDEBUG)
|
||||||
fprintf(stderr, "Check point read: %s\n", printable(key).c_str());
|
fprintf(stderr, "Check point read: %s\n", printable(key).c_str());
|
||||||
#endif
|
#endif
|
||||||
@@ -1803,7 +1803,7 @@ downLeftSpine:
|
|||||||
// short circuits as soon as it can prove that there's no conflict.
|
// short circuits as soon as it can prove that there's no conflict.
|
||||||
bool checkPrefixRead(Node *n, const std::span<const uint8_t> key,
|
bool checkPrefixRead(Node *n, const std::span<const uint8_t> key,
|
||||||
InternalVersionT readVersion, ConflictSet::Impl *impl) {
|
InternalVersionT readVersion, ConflictSet::Impl *impl) {
|
||||||
onPrefixRead(impl);
|
++accume_prefix_read;
|
||||||
#if DEBUG_VERBOSE && !defined(NDEBUG)
|
#if DEBUG_VERBOSE && !defined(NDEBUG)
|
||||||
fprintf(stderr, "Check prefix read: %s\n", printable(key).c_str());
|
fprintf(stderr, "Check prefix read: %s\n", printable(key).c_str());
|
||||||
#endif
|
#endif
|
||||||
@@ -2045,6 +2045,7 @@ scan16(const InternalVersionT *vs, int begin, int end,
|
|||||||
template <bool kAVX512>
|
template <bool kAVX512>
|
||||||
bool checkMaxBetweenExclusive(Node *n, int begin, int end,
|
bool checkMaxBetweenExclusive(Node *n, int begin, int end,
|
||||||
InternalVersionT readVersion) {
|
InternalVersionT readVersion) {
|
||||||
|
++accume_max_between;
|
||||||
assume(-1 <= begin);
|
assume(-1 <= begin);
|
||||||
assume(begin <= 256);
|
assume(begin <= 256);
|
||||||
assume(-1 <= end);
|
assume(-1 <= end);
|
||||||
@@ -2319,7 +2320,6 @@ bool checkRangeStartsWith(Node *n, std::span<const uint8_t> key, int begin,
|
|||||||
#endif
|
#endif
|
||||||
auto remaining = key;
|
auto remaining = key;
|
||||||
if (remaining.size() == 0) {
|
if (remaining.size() == 0) {
|
||||||
onCheckMaxBetween(impl);
|
|
||||||
return checkMaxBetweenExclusive<kAVX512>(n, begin, end, readVersion);
|
return checkMaxBetweenExclusive<kAVX512>(n, begin, end, readVersion);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2416,7 +2416,6 @@ template <bool kAVX512> struct CheckRangeLeftSide {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (searchPathLen >= prefixLen) {
|
if (searchPathLen >= prefixLen) {
|
||||||
onCheckMaxBetween(impl);
|
|
||||||
if (!checkMaxBetweenExclusive<kAVX512>(n, remaining[0], 256,
|
if (!checkMaxBetweenExclusive<kAVX512>(n, remaining[0], 256,
|
||||||
readVersion)) {
|
readVersion)) {
|
||||||
ok = false;
|
ok = false;
|
||||||
@@ -2547,7 +2546,6 @@ template <bool kAVX512> struct CheckRangeRightSide {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
onCheckMaxBetween(impl);
|
|
||||||
if (!checkMaxBetweenExclusive<kAVX512>(n, -1, remaining[0],
|
if (!checkMaxBetweenExclusive<kAVX512>(n, -1, remaining[0],
|
||||||
readVersion)) {
|
readVersion)) {
|
||||||
ok = false;
|
ok = false;
|
||||||
@@ -2645,7 +2643,7 @@ template <bool kAVX512>
|
|||||||
bool checkRangeReadImpl(Node *n, std::span<const uint8_t> begin,
|
bool checkRangeReadImpl(Node *n, std::span<const uint8_t> begin,
|
||||||
std::span<const uint8_t> end,
|
std::span<const uint8_t> end,
|
||||||
InternalVersionT readVersion, ConflictSet::Impl *impl) {
|
InternalVersionT readVersion, ConflictSet::Impl *impl) {
|
||||||
onRangeRead(impl);
|
++accume_range_read;
|
||||||
int lcp = longestCommonPrefix(begin.data(), end.data(),
|
int lcp = longestCommonPrefix(begin.data(), end.data(),
|
||||||
std::min(begin.size(), end.size()));
|
std::min(begin.size(), end.size()));
|
||||||
if (lcp == int(begin.size()) && end.size() == begin.size() + 1 &&
|
if (lcp == int(begin.size()) && end.size() == begin.size() + 1 &&
|
||||||
@@ -3060,11 +3058,6 @@ Node *firstGeqPhysical(Node *n, const std::span<const uint8_t> key) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
thread_local double accume_point_read = 0;
|
|
||||||
thread_local double accume_prefix_read = 0;
|
|
||||||
thread_local double accume_range_read = 0;
|
|
||||||
thread_local double accume_max_between = 0;
|
|
||||||
|
|
||||||
struct __attribute__((visibility("hidden"))) ConflictSet::Impl {
|
struct __attribute__((visibility("hidden"))) ConflictSet::Impl {
|
||||||
|
|
||||||
void check(const ReadRange *reads, Result *result, int count) {
|
void check(const ReadRange *reads, Result *result, int count) {
|
||||||
@@ -3369,11 +3362,6 @@ InternalVersionT maxVersion(Node *n, ConflictSet::Impl *impl) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void onPointRead(ConflictSet::Impl *impl) { ++impl->accume_point_read; }
|
|
||||||
void onPrefixRead(ConflictSet::Impl *impl) { ++impl->accume_prefix_read; }
|
|
||||||
void onRangeRead(ConflictSet::Impl *impl) { ++impl->accume_range_read; }
|
|
||||||
void onCheckMaxBetween(ConflictSet::Impl *impl) { ++impl->accume_max_between; }
|
|
||||||
|
|
||||||
void setMaxVersion(Node *n, ConflictSet::Impl *impl, InternalVersionT newMax) {
|
void setMaxVersion(Node *n, ConflictSet::Impl *impl, InternalVersionT newMax) {
|
||||||
int index = n->parentsIndex;
|
int index = n->parentsIndex;
|
||||||
n = n->parent;
|
n = n->parent;
|
||||||
|
Reference in New Issue
Block a user