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

Support for NUMA syscalls #937

Open
krh opened this issue Nov 19, 2023 · 3 comments
Open

Support for NUMA syscalls #937

krh opened this issue Nov 19, 2023 · 3 comments
Labels
enhancement New feature or request

Comments

@krh
Copy link

krh commented Nov 19, 2023

Any plans for adding support for NUMA syscalls?

extern long get_mempolicy(int *mode, unsigned long *nmask,
                        unsigned long maxnode, void *addr, unsigned flags);
extern long mbind(void *start, unsigned long len, int mode,
        const unsigned long *nmask, unsigned long maxnode, unsigned flags);
extern long set_mempolicy(int mode, const unsigned long *nmask,
                          unsigned long maxnode);
extern long migrate_pages(int pid, unsigned long maxnode,
                          const unsigned long *frommask,
                          const unsigned long *tomask);

extern long move_pages(int pid, unsigned long count,
                void **pages, const int *nodes, int *status, int flags);

I could write up a MR for this, unless it's something that's been deemed out of scope?

@sunfishcode sunfishcode added the enhancement New feature or request label Nov 19, 2023
@sunfishcode
Copy link
Member

It's in scope, just not implemented yet. An MR would be welcome!

krh added a commit to krh/rustix that referenced this issue Nov 20, 2023
…ealliance#937)

This adds support for the `mbind`, `set_mempolicy` and `get_mempolicy`
NUMA syscalls.  The `get_mempolicy` syscall has a few different modes
of operation, depending on the flags, which is demultiplexed into
`get_mempolicy_node` and `get_mempolicy_next_node` for now.  There's a
couple of other modes that writes into the variable length bit array,
which aren't implemented for now.
@krh
Copy link
Author

krh commented Nov 20, 2023

Ok, #938 is a start, but doesn't add all the syscalls, or even all the modes of get_mempolicy. It also dependes on a PR for linux-raw-sys.

@krh
Copy link
Author

krh commented Nov 20, 2023

krh added a commit to krh/rustix that referenced this issue Nov 29, 2023
…ealliance#937)

This adds support for the `mbind`, `set_mempolicy` and `get_mempolicy`
NUMA syscalls.  The `get_mempolicy` syscall has a few different modes
of operation, depending on the flags, which is demultiplexed into
`get_mempolicy_node` and `get_mempolicy_next_node` for now.  There's a
couple of other modes that writes into the variable length bit array,
which aren't implemented for now.
krh added a commit to krh/rustix that referenced this issue Nov 29, 2023
…ealliance#937)

This adds support for the `mbind`, `set_mempolicy` and `get_mempolicy`
NUMA syscalls.  The `get_mempolicy` syscall has a few different modes
of operation, depending on the flags, which is demultiplexed into
`get_mempolicy_node` and `get_mempolicy_next_node` for now.  There's a
couple of other modes that writes into the variable length bit array,
which aren't implemented for now.
krh added a commit to krh/rustix that referenced this issue Nov 29, 2023
…ealliance#937)

This adds support for the `mbind`, `set_mempolicy` and `get_mempolicy`
NUMA syscalls.  The `get_mempolicy` syscall has a few different modes
of operation, depending on the flags, which is demultiplexed into
`get_mempolicy_node` and `get_mempolicy_next_node` for now.  There's a
couple of other modes that writes into the variable length bit array,
which aren't implemented for now.
krh added a commit to krh/rustix that referenced this issue Nov 30, 2023
…ealliance#937)

This adds support for the `mbind`, `set_mempolicy` and `get_mempolicy`
NUMA syscalls.  The `get_mempolicy` syscall has a few different modes
of operation, depending on the flags, which is demultiplexed into
`get_mempolicy_node` and `get_mempolicy_next_node` for now.  There's a
couple of other modes that writes into the variable length bit array,
which aren't implemented for now.
krh added a commit to krh/rustix that referenced this issue Nov 30, 2023
…ealliance#937)

This adds support for the `mbind`, `set_mempolicy` and `get_mempolicy`
NUMA syscalls.  The `get_mempolicy` syscall has a few different modes
of operation, depending on the flags, which is demultiplexed into
`get_mempolicy_node` and `get_mempolicy_next_node` for now.  There's a
couple of other modes that writes into the variable length bit array,
which aren't implemented for now.
krh added a commit to krh/rustix that referenced this issue Nov 30, 2023
…ealliance#937)

This adds support for the `mbind`, `set_mempolicy` and `get_mempolicy`
NUMA syscalls.  The `get_mempolicy` syscall has a few different modes
of operation, depending on the flags, which is demultiplexed into
`get_mempolicy_node` and `get_mempolicy_next_node` for now.  There's a
couple of other modes that writes into the variable length bit array,
which aren't implemented for now.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants