Hi,all:
        Could someone explan the python thread to me?
        When I  use the python thread,I find some problems.If I run many
(such as 100) python threads ,then all thread are blocked.Below is the code:
        import thread,time
        def f():
                print 'f()'
                 
         def loop():
                  while True:
                                   f()

        for i in xrange(100):
                t=threading.Thread(target=loop)
          t.start()

        time.sleep(100000000)
        
        I run this program on red hat linux.The  intersting thing is that
the program sometimes works,but somtimes blocks(no output at all). 

-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to