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

Threads #4

Open
v1gnesh opened this issue Aug 5, 2023 · 0 comments
Open

Threads #4

v1gnesh opened this issue Aug 5, 2023 · 0 comments

Comments

@v1gnesh
Copy link

v1gnesh commented Aug 5, 2023

Hello,

Thank you for sharing your work, I hope you get more time to write fun stuff about your stories with the smol-rs projects.

If you have time, could you show an example of how to use piper for this:

  • spawn a thread for reading a file to end (the blocking I/O example in piper docs)
  • spawn tasks and pass each "chunk" from the file read to the new tasks, for them to process it

In this case, is there an recommended upper limit on the task creation with easy_parallel?
Is there an internal thread pool that allows re-use of threads, rather than create one per task (of which there may be millions)?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant