mirror of
https://github.com/mhx/dwarfs.git
synced 2025-09-13 22:40:03 -04:00
fix: use correct worker pool, otherwise we can stall
This commit is contained in:
parent
5579b35a52
commit
18cd20ea03
@ -691,18 +691,15 @@ void scanner_<LoggerPolicy>::scan(
|
|||||||
|
|
||||||
auto cc = fsw.get_compression_constraints(category.value(), meta);
|
auto cc = fsw.get_compression_constraints(category.value(), meta);
|
||||||
|
|
||||||
wg_ordering.add_job([this, catmgr, blockmgr, category, cat_size, meta, cc,
|
wg_blockify.add_job([this, catmgr, blockmgr, category, cat_size, meta, cc,
|
||||||
&prog, &fsw, &im, &wg_ordering, &wg_blockify] {
|
&prog, &fsw, &im, &wg_ordering] {
|
||||||
wg_blockify.add_job(
|
auto span = im.ordered_span(category, wg_ordering);
|
||||||
[this, catmgr, blockmgr, category, cat_size, meta, cc, &prog, &fsw,
|
|
||||||
span = im.ordered_span(category, wg_ordering)]() mutable {
|
|
||||||
auto tv = LOG_CPU_TIMED_VERBOSE;
|
auto tv = LOG_CPU_TIMED_VERBOSE;
|
||||||
|
|
||||||
auto seg = segmenter_factory_->create(
|
auto seg = segmenter_factory_->create(
|
||||||
category, cat_size, cc, blockmgr,
|
category, cat_size, cc, blockmgr,
|
||||||
[category, meta, &fsw](auto block) {
|
[category, meta, &fsw](auto block) {
|
||||||
return fsw.write_block(category.value(), std::move(block),
|
return fsw.write_block(category.value(), std::move(block), meta);
|
||||||
meta);
|
|
||||||
});
|
});
|
||||||
|
|
||||||
for (auto ino : span) {
|
for (auto ino : span) {
|
||||||
@ -733,7 +730,6 @@ void scanner_<LoggerPolicy>::scan(
|
|||||||
|
|
||||||
tv << category_prefix(catmgr, category) << "segmenting finished";
|
tv << category_prefix(catmgr, category) << "segmenting finished";
|
||||||
});
|
});
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
LOG_INFO << "waiting for segmenting/blockifying to finish...";
|
LOG_INFO << "waiting for segmenting/blockifying to finish...";
|
||||||
|
Loading…
x
Reference in New Issue
Block a user