HackerTrans
TopNewTrendsCommentsPastAskShowJobs

pablogsal

no profile record

Submissions

Intent to approve PEP 703: making the GIL optional

discuss.python.org
478 points·by pablogsal·3 ปีที่แล้ว·499 comments

comments

pablogsal
·2 ปีที่แล้ว·discuss
Have you tried aggregated capture files? https://bloomberg.github.io/memray/run.html#aggregated-captu...

With that option the files are much much smaller and much easier to analyse
pablogsal
·4 ปีที่แล้ว·discuss
One thing to note is that we support tracking forked/child processes as well!

>> - Much lower overhead, sounds like.

I actually think Fil has the potential to be faster in some situations because it seems that aggregates the flamegraph in memory. Memray needs to do a ton of I/O to disk holding a lock so if is under very heavy pressure it will be a bit slow.

Here are some non-very scientific tests running the "test_list" file from the CPython test suite:

* With pymalloc active (not a lot of heavy presure):

$ fil-profile run -m test test_list ... Total duration: 278 ms

$ memray3.10 run -m test test_list ... Total duration: 128 ms

* With pymalloc not active (heavy presure):

$ PYTHONMALLOC=malloc fil-profile run -m test test_list ... Total duration: 278 ms

$ PYTHONMALLOC=malloc memray3.10 run -m test test_list

Total duration: 344 ms

So as you can see Fil is 20% faster than memray in this scenario. This means that Fil is doing a fantastic job! We spent a lot of time optimizing memray and the fact that Fil can beat it is a testament to Fil's quality :)
pablogsal
·4 ปีที่แล้ว·discuss
Yeah, please hook me in! You know my email :)
pablogsal
·4 ปีที่แล้ว·discuss
Nice! Fil looks like an awesome profiler and is fantastic that works in other platforms. I am super excited to see more cool features and https://pythonspeed.com/sciagraph/ looks fantastic :)
pablogsal
·4 ปีที่แล้ว·discuss
It does much more than that! It tracks every single allocation and dumps it to a file that can later be analysed in many ways. Currently our reporters report peak memory (and leaked memory at the end of the execution) but technically any other reporter can be used. For example, we plan to allow to generate flame-graphs at arbitrary points in the execution and much more!