How does global value mutation used for thread-safety?



How does global value mutation used for thread-safety?..

Answer / chaitanya

The global interpreter lock is used to allow the running of the thread one at a time. This is internal to the program only and used to distribute the functionality along all the virtual machines that are used. Python allows the switching between the threads to be performed by using the byte code instructions that are used to provide platform-independence. The sys.setcheckinterval() method is used that allow the switching to occur during the implementation of the program and the instruction. This provides the understanding in the field of accounting to use the byte code implementation that makes it portable to use. The atomicity can be provided such that the shared variables can be given as built-in data types.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Python Interview Questions

What is the maximum possible length of an identifier?

0 Answers  


Is yield a keyword in python?

0 Answers  


What is the difference between locals() and globals ()?

0 Answers  


Which ide is best for python on windows?

0 Answers  


Short description of the scoping rules?

0 Answers  


How to remove spaces from a string in Python?

2 Answers  


What are the runtime errors?

0 Answers  


What is Dict and List comprehensions are?

0 Answers  


Which database is best for python?

0 Answers  


Can you build web apps with python?

0 Answers  


Explain inheritance in python with example?

0 Answers  


What are the rules for global and local variables in python?

0 Answers  


Categories