In my little understanding, it is the performance factor that drives programming for multi-threading
in most cases but not all. (irrespective of Java or Python).
I was reading this enlightening article on GIL
in SO. The article summarizes that python adopts GIL
mechanism; i.e only a single Thread
can execute python byte code
at any given time.
This makes single thread
application really faster.
My question is as follows:
Since if only one Thread
is served at a given point, does multiprocessing
or thread
module provides a way to overcome this limitation imposed by GIL? If not, what features does they provide for doing a real multi-task
work
There was a question asked in the comments section of the above post in the accepted answer,but no answer has been made? I had this question in my mind too
^so at any time point of time, only one thread will be serving content to client...
so no point of actually using multithreading to improve performance. right?