[issue8368] Memory leak on multi-threaded PyObject_CallObject

2010-04-11 Thread Martin v . Löwis
Martin v. Löwis added the comment: Ok, it consumes more memory - why do you think there is a leak? -- ___ Python tracker ___ ___ Pytho

[issue8368] Memory leak on multi-threaded PyObject_CallObject

2010-04-11 Thread Krauzi
Krauzi added the comment: ah no you misunderstood me. Please add a system("pause") and a system("pause") at the beginning of the while(1)-loop and one at the end. Then compare the memory usage of the program at the beginning (lets say it's 2,6 MB) with the usage at the second pause. In may ca

[issue8368] Memory leak on multi-threaded PyObject_CallObject

2010-04-11 Thread Martin v . Löwis
Martin v. Löwis added the comment: I can't reproduce the problem on Windows, either. The attached project runs the thread creation in a loop (leaving the 3s sleep in the code). I see (in process viewer) that the Commit Size varies between 13MB and 14MB; there is no indication of a leak.

[issue8368] Memory leak on multi-threaded PyObject_CallObject

2010-04-11 Thread Krauzi
Krauzi added the comment: oh no then it's a windows bug. Now i understand why many devs use linux instead of windows.. -- ___ Python tracker ___

[issue8368] Memory leak on multi-threaded PyObject_CallObject

2010-04-11 Thread Antoine Pitrou
Antoine Pitrou added the comment: Thanks Martin. I see no leak here either (Linux with Python 2.6 and 2.7). -- ___ Python tracker ___

[issue8368] Memory leak on multi-threaded PyObject_CallObject

2010-04-11 Thread Martin v . Löwis
Martin v. Löwis added the comment: I've ported the program to Linux (see attached tar file). I cannot observe any memory leak here - even if I let the program run for a long time (linking with Python 2.6). Memory usage in top goes up and down, but never over some upper limit. The only change

[issue8368] Memory leak on multi-threaded PyObject_CallObject

2010-04-11 Thread Krauzi
Changes by Krauzi : Removed file: http://bugs.python.org/file16868/Python Bug.zip ___ Python tracker ___ ___ Python-bugs-list mailing list Unsu

[issue8368] Memory leak on multi-threaded PyObject_CallObject

2010-04-11 Thread Krauzi
Krauzi added the comment: kay updated the code. Please use this: http://paste.pocoo.org/show/200484/ smaller code but problem still the same. -- ___ Python tracker ___ __

[issue8368] Memory leak on multi-threaded PyObject_CallObject

2010-04-11 Thread Krauzi
Krauzi added the comment: i think the PyObject_Call* is the problem because when i comment it out, i do not longer get leaks. The arguments are also correctly decremented because i also can use NULL as argument and i get the same mem leaks like before. --

[issue8368] Memory leak on multi-threaded PyObject_CallObject

2010-04-11 Thread Antoine Pitrou
Antoine Pitrou added the comment: Why do you think PyObject_CallObject() is the culprit? There could be any number of reasons for a memory leak: - cyclic references needing to be cleared (have you tried calling PyGC_Collect()?) - reference leak(s) in your own internal logic - inefficiencies in

[issue8368] Memory leak on multi-threaded PyObject_CallObject

2010-04-11 Thread Krauzi
New submission from Krauzi : Hi guys, i think this is a bug and Matt from h...@python.org suggested me to report it here: I attached a sample project where the memory leak occurs.I created a sample project where the memory leak occurs. It's a visual studio 2008 project and uses windows threads