Compare commits
4 Commits
4113183155
...
ca804f28c0
| Author | SHA1 | Date | |
|---|---|---|---|
| ca804f28c0 | |||
| 3898cb596a | |||
| b8edd92698 | |||
| 8e480528d5 |
+22
-16
@@ -720,16 +720,18 @@ struct ReadContext {
|
||||
struct WriteContext {
|
||||
|
||||
struct Accum {
|
||||
int64_t entries_erased = 0;
|
||||
int64_t insert_iterations = 0;
|
||||
int64_t entries_inserted = 0;
|
||||
int64_t nodes_allocated = 0;
|
||||
int64_t nodes_released = 0;
|
||||
int64_t point_writes = 0;
|
||||
int64_t range_writes = 0;
|
||||
int64_t write_bytes = 0;
|
||||
int64_t entries_erased;
|
||||
int64_t insert_iterations;
|
||||
int64_t entries_inserted;
|
||||
int64_t nodes_allocated;
|
||||
int64_t nodes_released;
|
||||
int64_t point_writes;
|
||||
int64_t range_writes;
|
||||
int64_t write_bytes;
|
||||
} accum;
|
||||
|
||||
WriteContext() { memset(&accum, 0, sizeof(accum)); }
|
||||
|
||||
template <class T> T *allocate(int c) {
|
||||
++accum.nodes_allocated;
|
||||
if constexpr (std::is_same_v<T, Node0>) {
|
||||
@@ -1967,6 +1969,9 @@ downLeftSpine:
|
||||
return n->entry.rangeVersion <= readVersion;
|
||||
}
|
||||
|
||||
// Only one of these is ever exercised. I'm not worried about somehow not
|
||||
// calling one of these though.
|
||||
// GCOVR_EXCL_START
|
||||
#ifdef HAS_AVX
|
||||
uint32_t compare16_32bit(const InternalVersionT *vs, InternalVersionT rv) {
|
||||
uint32_t compared = 0;
|
||||
@@ -1986,14 +1991,14 @@ uint32_t compare16_32bit(const InternalVersionT *vs, InternalVersionT rv) {
|
||||
|
||||
__attribute__((target("avx512f"))) uint32_t
|
||||
compare16_32bit_avx512(const InternalVersionT *vs, InternalVersionT rv) {
|
||||
__m512i w;
|
||||
memcpy(&w, vs, sizeof(w));
|
||||
uint32_t r;
|
||||
memcpy(&r, &rv, sizeof(r));
|
||||
return _mm512_cmpgt_epi32_mask(_mm512_sub_epi32(w, _mm512_set1_epi32(r)),
|
||||
_mm512_setzero_epi32());
|
||||
return _mm512_cmpgt_epi32_mask(
|
||||
_mm512_sub_epi32(_mm512_loadu_epi32(vs), _mm512_set1_epi32(r)),
|
||||
_mm512_setzero_epi32());
|
||||
}
|
||||
#endif
|
||||
// GCOVR_EXCL_STOP
|
||||
|
||||
// Returns true if v[i] <= readVersion for all i such that begin <= is[i] < end
|
||||
// Preconditions: begin <= end, end - begin < 256
|
||||
@@ -2048,9 +2053,9 @@ bool scan16(const InternalVersionT *vs, const uint8_t *is, int begin, int end,
|
||||
|
||||
uint32_t compared = 0;
|
||||
if constexpr (kAVX512) {
|
||||
compared = compare16_32bit_avx512(vs, readVersion);
|
||||
compared = compare16_32bit_avx512(vs, readVersion); // GCOVR_EXCL_LINE
|
||||
} else {
|
||||
compared = compare16_32bit(vs, readVersion);
|
||||
compared = compare16_32bit(vs, readVersion); // GCOVR_EXCL_LINE
|
||||
}
|
||||
return !(compared & mask);
|
||||
|
||||
@@ -2076,10 +2081,11 @@ bool scan16(const InternalVersionT *vs, const uint8_t *is, int begin, int end,
|
||||
// Returns true if v[i] <= readVersion for all i such that begin <= i < end
|
||||
//
|
||||
// always_inline So that we can optimize when begin or end is a constant.
|
||||
// gcovr exclude annotation necessary because of always_inline?
|
||||
template <bool kAVX512>
|
||||
inline __attribute__((always_inline)) bool
|
||||
scan16(const InternalVersionT *vs, int begin, int end,
|
||||
InternalVersionT readVersion) {
|
||||
scan16(const InternalVersionT *vs, int begin, int end, // GCOVR_EXCL_LINE
|
||||
InternalVersionT readVersion) { // GCOVR_EXCL_LINE
|
||||
assert(0 <= begin && begin < 16);
|
||||
assert(0 <= end && end <= 16);
|
||||
assert(begin <= end);
|
||||
|
||||
BIN
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user