-
Notifications
You must be signed in to change notification settings - Fork 12
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
VirtualAlloc and affinity settings #71
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add some tests for these new functions.
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: only 1 trailing blank newline
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: only 1 trailing blank newline
inline | ||
BOOLEAN | ||
CxPlatSetThreadNodeAffinity( | ||
LONG NodeAffinity |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's not use Windows style all caps types like LONG
.
LONG NodeAffinity | |
uint32_t NodeAffinity |
GROUP_AFFINITY group = {0}; | ||
|
||
group.Mask = CpuAffinity; | ||
group.Group = (USHORT)GroupNumber; | ||
|
||
KeSetSystemGroupAffinityThread(&group, NULL); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
GROUP_AFFINITY group = {0}; | |
group.Mask = CpuAffinity; | |
group.Group = (USHORT)GroupNumber; | |
KeSetSystemGroupAffinityThread(&group, NULL); | |
GROUP_AFFINITY group = { (KAFFINITY)CpuAffinity, GroupNumber, 0 }; | |
KeSetSystemGroupAffinityThread(&group, NULL); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And make the similar changes to user mode.
Move from xdp-for-windows to here