Skip to content

Commit

Permalink
reactor: Set aio_nowait_supported once
Browse files Browse the repository at this point in the history
This variable is global and _not_ thread_local, so there's no need in
setting it in each reactor's .configure() invocation.

Signed-off-by: Pavel Emelyanov <[email protected]>
  • Loading branch information
xemul committed Jul 6, 2024
1 parent aa4dd10 commit c046992
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/core/reactor.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1578,8 +1578,6 @@ void reactor::configure(const reactor_options& opts) {
csdc.stall_detector_reports_per_minute = opts.blocked_reactor_reports_per_minute.get_value();
csdc.oneline = opts.blocked_reactor_report_format_oneline.get_value();
_cpu_stall_detector->update_config(csdc);

aio_nowait_supported = opts.linux_aio_nowait.get_value();
}

pollable_fd
Expand Down Expand Up @@ -4401,6 +4399,7 @@ void smp::configure(const smp_options& smp_opts, const reactor_options& reactor_
.no_poll_aio = !reactor_opts.poll_aio.get_value() || (reactor_opts.poll_aio.defaulted() && reactor_opts.overprovisioned),
};

aio_nowait_supported = reactor_opts.linux_aio_nowait.get_value();
std::mutex mtx;

#ifdef SEASTAR_HEAPPROF
Expand Down

0 comments on commit c046992

Please sign in to comment.