Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR is a distilled port of Igalia#341 to Snabb master, adding a couple of interfaces to ljsyscall, pulling in a getcpu() bugfix from @kbara, and then adding a Snabb module that lets you do
numa.bind_to_cpu(CPU)
in Snabb. That will bind the current thread to that CPU, bind the memory for that thread to that CPU's NUMA node, and migrate all memory to that NUMA node. It's ideal for hooking up to a--cpu
command-line argument, with notaskset
/numactl
shenanigans, and with the additional benefit of migrating pages. (That's what we do in the lwaftr; this commit is from Igalia/lwaftr and something we need to land upstream before merging upstream.)The ljsyscall change is going upstream here: justincormack/ljsyscall#193. Embarassingly I can't yet run docker on this guixsd machine so I haven't been able to add/fix the tests upstream yet :P However this patch does run in production, so there's that.