Threads and Their Execution [closed]

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
0
down vote

favorite












Sometimes threads fell that they run long time, and they give their turns to another threads by means of thread scheduling procedure.



1) I wonder what happens if a thread does not want to stop itself, and it wants to continue running.



2) If another thread want to take the turn of the thread which do not want to stop, what happens ?







share|improve this question












closed as too broad by Michael Homer, mdpc, G-Man, Satō Katsura, Kiwy Mar 6 at 9:23


Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.


















    up vote
    0
    down vote

    favorite












    Sometimes threads fell that they run long time, and they give their turns to another threads by means of thread scheduling procedure.



    1) I wonder what happens if a thread does not want to stop itself, and it wants to continue running.



    2) If another thread want to take the turn of the thread which do not want to stop, what happens ?







    share|improve this question












    closed as too broad by Michael Homer, mdpc, G-Man, Satō Katsura, Kiwy Mar 6 at 9:23


    Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
















      up vote
      0
      down vote

      favorite









      up vote
      0
      down vote

      favorite











      Sometimes threads fell that they run long time, and they give their turns to another threads by means of thread scheduling procedure.



      1) I wonder what happens if a thread does not want to stop itself, and it wants to continue running.



      2) If another thread want to take the turn of the thread which do not want to stop, what happens ?







      share|improve this question












      Sometimes threads fell that they run long time, and they give their turns to another threads by means of thread scheduling procedure.



      1) I wonder what happens if a thread does not want to stop itself, and it wants to continue running.



      2) If another thread want to take the turn of the thread which do not want to stop, what happens ?









      share|improve this question











      share|improve this question




      share|improve this question










      asked Mar 5 at 22:33









      Goktug

      1467




      1467




      closed as too broad by Michael Homer, mdpc, G-Man, Satō Katsura, Kiwy Mar 6 at 9:23


      Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.






      closed as too broad by Michael Homer, mdpc, G-Man, Satō Katsura, Kiwy Mar 6 at 9:23


      Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.






















          1 Answer
          1






          active

          oldest

          votes

















          up vote
          2
          down vote













          In most modern operating systems, including Linux, task (process/thread) scheduling is preemptive – controlled by the kernel. A task cannot choose not to stop and cannot choose to take the turn of another task. In general, tasks are oblivious to the fact that CPU scheduling is even happening.






          share|improve this answer



























            1 Answer
            1






            active

            oldest

            votes








            1 Answer
            1






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes








            up vote
            2
            down vote













            In most modern operating systems, including Linux, task (process/thread) scheduling is preemptive – controlled by the kernel. A task cannot choose not to stop and cannot choose to take the turn of another task. In general, tasks are oblivious to the fact that CPU scheduling is even happening.






            share|improve this answer
























              up vote
              2
              down vote













              In most modern operating systems, including Linux, task (process/thread) scheduling is preemptive – controlled by the kernel. A task cannot choose not to stop and cannot choose to take the turn of another task. In general, tasks are oblivious to the fact that CPU scheduling is even happening.






              share|improve this answer






















                up vote
                2
                down vote










                up vote
                2
                down vote









                In most modern operating systems, including Linux, task (process/thread) scheduling is preemptive – controlled by the kernel. A task cannot choose not to stop and cannot choose to take the turn of another task. In general, tasks are oblivious to the fact that CPU scheduling is even happening.






                share|improve this answer












                In most modern operating systems, including Linux, task (process/thread) scheduling is preemptive – controlled by the kernel. A task cannot choose not to stop and cannot choose to take the turn of another task. In general, tasks are oblivious to the fact that CPU scheduling is even happening.







                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered Mar 5 at 23:27









                Andy Dalton

                4,7561520




                4,7561520












                    Popular posts from this blog

                    How to check contact read email or not when send email to Individual?

                    Bahrain

                    Postfix configuration issue with fips on centos 7; mailgun relay