this post was submitted on 31 Jul 2023
36 points (90.9% liked)
Programming
17670 readers
231 users here now
Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!
Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.
Hope you enjoy the instance!
Rules
Rules
- Follow the programming.dev instance rules
- Keep content related to programming in some way
- If you're posting long videos try to add in some form of tldr for those who don't want to watch videos
Wormhole
Follow the wormhole through a path of communities [email protected]
founded 2 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
The article is about .NET async/task and a driver hardware request specifically. I find the post title and article awful.
So there are threads after all.
No, it doesn't. You can't take one specific use case and code flow analysis and extrapolate to a generic concept and universal truth. You can only make a statement for that type of thing. (And even then have to consider execution may differ for various reasons.)
But the opposite of "there is no thread anywhere ever" is not true either.
For .NET tasks as a concept, an interface, tasks may return immediately not just without thread scheduling but also without task scheduling. Tasks may be scheduled through a thread pool. Or they may be executed like OP analysis.
They completely ignored anything outside their specific case and made a broad claim as if it represented all of them.
If the actual point is that "borrowed threads are not [real] threads" then that's broadly misleading and wrong.
There is no thread waiting for the operation to complete is their point.