summaryrefslogtreecommitdiff
path: root/src/block
diff options
context:
space:
mode:
Diffstat (limited to 'src/block')
-rw-r--r--src/block/block_ext.c6
-rw-r--r--src/block/block_open.c16
-rw-r--r--src/block/block_read.c10
-rw-r--r--src/block/block_vrfy.c2
-rw-r--r--src/block/block_write.c10
5 files changed, 23 insertions, 21 deletions
diff --git a/src/block/block_ext.c b/src/block/block_ext.c
index 8a4d2b08bef..b02fea8707d 100644
--- a/src/block/block_ext.c
+++ b/src/block/block_ext.c
@@ -485,7 +485,7 @@ __block_extend(
*offp = block->size;
block->size += size;
- WT_STAT_FAST_DATA_INCR(session, block_extension);
+ WT_STAT_DATA_INCR(session, block_extension);
__wt_verbose(session, WT_VERB_BLOCK,
"file extend %" PRIdMAX "B @ %" PRIdMAX,
(intmax_t)size, (intmax_t)*offp);
@@ -507,7 +507,7 @@ __wt_block_alloc(
/* Assert we're maintaining the by-size skiplist. */
WT_ASSERT(session, block->live.avail.track_size != 0);
- WT_STAT_FAST_DATA_INCR(session, block_alloc);
+ WT_STAT_DATA_INCR(session, block_alloc);
if (size % block->allocsize != 0)
WT_RET_MSG(session, EINVAL,
"cannot allocate a block size %" PRIdMAX " that is not "
@@ -590,7 +590,7 @@ __wt_block_free(WT_SESSION_IMPL *session,
uint32_t checksum, size;
WT_UNUSED(addr_size);
- WT_STAT_FAST_DATA_INCR(session, block_free);
+ WT_STAT_DATA_INCR(session, block_free);
/* Crack the cookie. */
WT_RET(
diff --git a/src/block/block_open.c b/src/block/block_open.c
index e369d013437..4d15942709a 100644
--- a/src/block/block_open.c
+++ b/src/block/block_open.c
@@ -382,21 +382,19 @@ err: __wt_scr_free(session, &buf);
void
__wt_block_stat(WT_SESSION_IMPL *session, WT_BLOCK *block, WT_DSRC_STATS *stats)
{
- WT_UNUSED(session);
-
/*
* Reading from the live system's structure normally requires locking,
* but it's an 8B statistics read, there's no need.
*/
- WT_STAT_WRITE(stats, allocation_size, block->allocsize);
- WT_STAT_WRITE(
+ WT_STAT_WRITE(session, stats, allocation_size, block->allocsize);
+ WT_STAT_WRITE(session,
stats, block_checkpoint_size, (int64_t)block->live.ckpt_size);
- WT_STAT_WRITE(stats, block_magic, WT_BLOCK_MAGIC);
- WT_STAT_WRITE(stats, block_major, WT_BLOCK_MAJOR_VERSION);
- WT_STAT_WRITE(stats, block_minor, WT_BLOCK_MINOR_VERSION);
- WT_STAT_WRITE(
+ WT_STAT_WRITE(session, stats, block_magic, WT_BLOCK_MAGIC);
+ WT_STAT_WRITE(session, stats, block_major, WT_BLOCK_MAJOR_VERSION);
+ WT_STAT_WRITE(session, stats, block_minor, WT_BLOCK_MINOR_VERSION);
+ WT_STAT_WRITE(session,
stats, block_reuse_bytes, (int64_t)block->live.avail.bytes);
- WT_STAT_WRITE(stats, block_size, block->size);
+ WT_STAT_WRITE(session, stats, block_size, block->size);
}
/*
diff --git a/src/block/block_read.c b/src/block/block_read.c
index c6005b1f60a..1eeabd63d92 100644
--- a/src/block/block_read.c
+++ b/src/block/block_read.c
@@ -28,7 +28,7 @@ __wt_bm_preload(
block = bm->block;
- WT_STAT_FAST_CONN_INCR(session, block_preload);
+ WT_STAT_CONN_INCR(session, block_preload);
/* Crack the cookie. */
WT_RET(
@@ -86,8 +86,8 @@ __wt_bm_read(WT_BM *bm, WT_SESSION_IMPL *session,
ret = handle->fh_map_preload(handle, (WT_SESSION *)session,
buf->data, buf->size,bm->mapped_cookie);
- WT_STAT_FAST_CONN_INCR(session, block_map_read);
- WT_STAT_FAST_CONN_INCRV(session, block_byte_map_read, size);
+ WT_STAT_CONN_INCR(session, block_map_read);
+ WT_STAT_CONN_INCRV(session, block_byte_map_read, size);
return (ret);
}
@@ -164,8 +164,8 @@ __wt_block_read_off(WT_SESSION_IMPL *session, WT_BLOCK *block,
"off %" PRIuMAX ", size %" PRIu32 ", checksum %" PRIu32,
(uintmax_t)offset, size, checksum);
- WT_STAT_FAST_CONN_INCR(session, block_read);
- WT_STAT_FAST_CONN_INCRV(session, block_byte_read, size);
+ WT_STAT_CONN_INCR(session, block_read);
+ WT_STAT_CONN_INCRV(session, block_byte_read, size);
/*
* Grow the buffer as necessary and read the block. Buffers should be
diff --git a/src/block/block_vrfy.c b/src/block/block_vrfy.c
index 58b62247044..94824ad19f8 100644
--- a/src/block/block_vrfy.c
+++ b/src/block/block_vrfy.c
@@ -352,7 +352,7 @@ __wt_block_verify_addr(WT_SESSION_IMPL *session,
WT_RET(
__wt_block_buffer_to_addr(block, addr, &offset, &size, &checksum));
- /* Add to the per-file list. */
+ /* Add to the per-file list. */
WT_RET(
__verify_filefrag_add(session, block, NULL, offset, size, false));
diff --git a/src/block/block_write.c b/src/block/block_write.c
index 032f72d551b..d08aba45920 100644
--- a/src/block/block_write.c
+++ b/src/block/block_write.c
@@ -236,6 +236,10 @@ __block_write_off(WT_SESSION_IMPL *session, WT_BLOCK *block,
uint32_t checksum;
bool local_locked;
+ *offsetp = 0; /* -Werror=maybe-uninitialized */
+ *sizep = 0; /* -Werror=maybe-uninitialized */
+ *checksump = 0; /* -Werror=maybe-uninitialized */
+
fh = block->fh;
/*
@@ -363,10 +367,10 @@ __block_write_off(WT_SESSION_IMPL *session, WT_BLOCK *block,
/* Optionally discard blocks from the buffer cache. */
WT_RET(__wt_block_discard(session, block, align_size));
- WT_STAT_FAST_CONN_INCR(session, block_write);
- WT_STAT_FAST_CONN_INCRV(session, block_byte_write, align_size);
+ WT_STAT_CONN_INCR(session, block_write);
+ WT_STAT_CONN_INCRV(session, block_byte_write, align_size);
if (checkpoint_io)
- WT_STAT_FAST_CONN_INCRV(
+ WT_STAT_CONN_INCRV(
session, block_byte_write_checkpoint, align_size);
__wt_verbose(session, WT_VERB_WRITE,