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

smaller mutex and condition variables #64

Open
graphitemaster opened this issue Jun 21, 2021 · 0 comments
Open

smaller mutex and condition variables #64

graphitemaster opened this issue Jun 21, 2021 · 0 comments
Assignees
Labels

Comments

@graphitemaster
Copy link
Member

Currently Rex uses OS primitives to implement Mutex and ConditionVariable, each being 64 bytes in size! This overhead is not appreciable. Rex also implements a WordLock which is a thinner Mutex type taking just a word of storage made possible by managing it's own per-thread data structures and thread parking as borrowed from WebKit. We should reimplement the full user-space parking-lot API to get single byte Mutex and ConditionVariables, this way we may introduce a word-size Promise (which require both a mutex and condvar) implementation for asynchronous background work.

@graphitemaster graphitemaster self-assigned this Jun 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant