Reputation: 1
I know that there aren't parameter 'pid' at set_mempolicy() so, I couldn't set mempolicy by pid on running process. (like numactl interleave, membind, etc)
Is there any way to set mempolicy by pid on running process?
I tried to confirm numactl mempolicy code and setting conditions but I couldn' get answer.
Upvotes: 0
Views: 110
Reputation: 941
I am not sure if it works, but you could try to attach the external process to yours using ptrace()
and then use set_mempolicy
.
Something like this:
Upvotes: 0