You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Wikipedia article on threads says: "In computer science, a thread of execution is the smallest sequence of programmed instructions that can be managed independently by a scheduler, which is typically a part of the operating system."
What does 'smallest' mean here? And if it has some normal meaning, then why wouldn't the smallest such sequence have only one instruction in it (or even zero instructions)? Is it somehow the case that, when a sequence gets sufficiently small, its execution cannot be handled by a scheduler?
The text was updated successfully, but these errors were encountered:
I believe that what the Wikipedia entry means is that a scheduler may be aware of a hierarchy of instruction sequences, so a thread is contained in a process, a process may be part of some group of processes defined by the scheduler.
The thread is the "smallest" unit in the sense that the scheduler can't break it up into smaller pieces to run concurrently. That doesn't mean that it's the smallest sequence of instructions that can exist on the hardware, just the scheduler is not able to divide it up into smaller "streams" of instructions that can run independently. Whereas a process can be running on more than one core (or be run "out of order" on a single core) if it has more than one thread in it.
gadamico
changed the title
Threads as
Threads as smallest sequences?
Apr 29, 2016
The Wikipedia article on threads says: "In computer science, a thread of execution is the smallest sequence of programmed instructions that can be managed independently by a scheduler, which is typically a part of the operating system."
What does 'smallest' mean here? And if it has some normal meaning, then why wouldn't the smallest such sequence have only one instruction in it (or even zero instructions)? Is it somehow the case that, when a sequence gets sufficiently small, its execution cannot be handled by a scheduler?
The text was updated successfully, but these errors were encountered: