Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -568,9 +568,17 @@ class AsyncFunctionHandler
params_.logger, !affinity_result.first,
"Could not set CPU affinity for the async worker thread. Error: %s",
affinity_result.second.c_str());

std::string cores_list_print = "[";
for (size_t i = 0; i < params_.cpu_affinity_cores.size(); ++i) {
cores_list_print += std::to_string(params_.cpu_affinity_cores[i]) +
(i < params_.cpu_affinity_cores.size() - 1 ? ", " : "");
}
cores_list_print += "]";

RCLCPP_WARN_EXPRESSION(
params_.logger, affinity_result.first,
"Async worker thread is successfully pinned to the requested CPU cores!");
"Async worker thread successfully pinned to Cores: %s", cores_list_print.c_str());
Comment thread
Nibanovic marked this conversation as resolved.
}
if (!params_.thread_name.empty()) {
const auto rename_result = realtime_tools::set_current_thread_name(params_.thread_name);
Expand Down
Loading