Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed segfault in Nexus::Nexus when there are offline CPUs #36

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
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
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ CMakeScripts
Makefile
Testing
CTestTestfile.cmake
cmake-build*

# gdb
.gdb_history
Expand All @@ -66,3 +67,4 @@ gdb_history
*.swp
src/config.h
.ycm_extra_conf.py
.idea
6 changes: 3 additions & 3 deletions src/nexus_impl/nexus.cc
Original file line number Diff line number Diff line change
Expand Up @@ -58,11 +58,11 @@ Nexus::Nexus(std::string local_uri, size_t numa_node, size_t num_bg_threads)
sm_thread_ctx.reg_hooks_lock = &reg_hooks_lock;

// Bind the session management thread to the last lcore on numa_node
size_t sm_thread_lcore_index = num_lcores_per_numa_node() - 1;
auto lcores = get_lcores_for_numa_node(numa_node);
ERPC_INFO("eRPC Nexus: Launching session management thread on core %zu.\n",
get_lcores_for_numa_node(numa_node).at(sm_thread_lcore_index));
lcores.back());
sm_thread = std::thread(sm_thread_func, sm_thread_ctx);
bind_to_core(sm_thread, numa_node, sm_thread_lcore_index);
bind_to_core(sm_thread, numa_node, lcores.size() - 1);

ERPC_INFO("eRPC Nexus: Created with management UDP port %u, hostname %s.\n",
sm_udp_port, hostname.c_str());
Expand Down