mirror of
https://github.com/matrix-construct/construct
synced 2024-10-03 22:28:52 +02:00
ircd::db: Deinline some env::state related.
This commit is contained in:
parent
e22162f505
commit
a513ba9cf3
2 changed files with 18 additions and 11 deletions
13
include/ircd/db/database/env/state.h
vendored
13
include/ircd/db/database/env/state.h
vendored
|
@ -24,17 +24,10 @@ struct ircd::db::database::env::state
|
|||
rocksdb::Env::Priority::TOTAL
|
||||
};
|
||||
|
||||
/// Track of background tasks.
|
||||
std::array<std::deque<task>, POOLS> tasks;
|
||||
static conf::item<size_t> pool_stack_size;
|
||||
|
||||
/// The background task pools.
|
||||
std::array<ctx::pool, POOLS> pool
|
||||
{{
|
||||
// name of pool stack size initial workers
|
||||
{ "rdb bott", 128_KiB, 0 },
|
||||
{ "rdb low", 128_KiB, 0 },
|
||||
{ "rdb high", 128_KiB, 0 },
|
||||
}};
|
||||
std::array<std::deque<task>, POOLS> tasks;
|
||||
std::array<ctx::pool, POOLS> pool;
|
||||
|
||||
state(database *const &d);
|
||||
~state() noexcept;
|
||||
|
|
16
ircd/db.cc
16
ircd/db.cc
|
@ -7353,12 +7353,26 @@ noexcept
|
|||
// db/database/env/state.h
|
||||
//
|
||||
|
||||
decltype(ircd::db::database::env::state::pool_stack_size)
|
||||
ircd::db::database::env::state::pool_stack_size
|
||||
{
|
||||
{ "name", "ircd.db.env.pool.stack_size" },
|
||||
{ "default", long(128_KiB) },
|
||||
};
|
||||
|
||||
//
|
||||
// env::state
|
||||
// env::state::state
|
||||
//
|
||||
|
||||
ircd::db::database::env::state::state(database *const &d)
|
||||
:d{*d}
|
||||
,pool
|
||||
{{
|
||||
// name of pool stack size initial workers
|
||||
{ "rdb bott", size_t(pool_stack_size), 0 },
|
||||
{ "rdb low", size_t(pool_stack_size), 0 },
|
||||
{ "rdb high", size_t(pool_stack_size), 0 },
|
||||
}}
|
||||
{
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue