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

Add multithreading to FiOne #1545

Open
wants to merge 15 commits into
base: master
Choose a base branch
from

Conversation

ccuser44
Copy link
Contributor

@ccuser44 ccuser44 commented Jun 2, 2024

Add multithreading to FiOne. Officially the first ever per function multithreading implementation in Lua that works out of the box without libraries

Function is multithreaded when function name is prefixed with SUPER_SECRET_ADONIS_MULTITHREAD_PREFIX_.
Only (local)? function NAME(...) is detected, not NAME = function(...).

Only uses one different thread per function for now. Functions yields until multithreaded function returns or errors

Upval mutation, env mutations, calling closures outside threaded context, cross thread metatables, Instance interactions and cross thread table changes have all undefined behavior

Question: Why does Adonis need this?
Answer: You can't create cloned FiOne runners without hacking Adonis, this makes multithreading possible without hacking Adonis. Making some form of multithreading possible in Adonis without hacking Adonis itself is very nice

@ccuser44 ccuser44 changed the title Add multithreading to FiOne. **Officially the first ever per function multithreading implementation in Lua that works out of the box without libraries** Add multithreading to Loadstring. **Officially the first ever per function multithreading implementation in Lua that works out of the box without libraries** Jun 2, 2024
@ccuser44 ccuser44 changed the title Add multithreading to Loadstring. **Officially the first ever per function multithreading implementation in Lua that works out of the box without libraries** Add multithreading to FiOne. **Officially the first ever per function multithreading implementation in Lua that works out of the box without libraries** Jun 2, 2024
@ccuser44 ccuser44 changed the title Add multithreading to FiOne. **Officially the first ever per function multithreading implementation in Lua that works out of the box without libraries** Add multithreading to FiOne Jun 2, 2024
@Dimenpsyonal Dimenpsyonal added the ⌛needs PoF This PR is awaiting proof of functionality label Jun 5, 2024
@Epix-Incorporated Epix-Incorporated deleted a comment Jun 8, 2024
@P3tray
Copy link
Contributor

P3tray commented Jul 8, 2024

SUPER_SECRET_ADONIS_MULTITHREAD_PREFIX_

@Dimenpsyonal
Copy link
Member

Needs proof of functionality

@LolloDev5123
Copy link
Contributor

I say we do all compiler/interpreter related stuff on a separate repository which is then included here as a git module.
Here's a proof of concept: https://github.com/Indirecta-Technologies/luic

@Dimenpsyonal
Copy link
Member

just add that into adonis. ez

@P3tray
Copy link
Contributor

P3tray commented Oct 22, 2024

WOOHOO! NEW COMMITS!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
⌛needs PoF This PR is awaiting proof of functionality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants