News for hackers. Stuff that matters.
Re:Scalene: A high-performance, high-precision CPU, GPU, mem... by motbus3 on Tuesday October 22, 2024 @06:04AM (#41912800)
I used many times and sometimes I used py-spy. That helped me to improve several projects where people told me there were network problems but it was actually not
Re:Scalene: A high-performance, high-precision CPU, GPU, mem... by alfons_foobar on Tuesday October 22, 2024 @06:46AM (#41913010)
kudos for actually looking what the problem is.

As a (former) NetEng, it bothers me to no end that so many people claim "it's the network" when their application is slow / broken, without understanding the actual problem.

Re:Scalene: A high-performance, high-precision CPU, GPU, mem... by embeng4096 on Tuesday October 22, 2024 @10:52AM (#41914879)
+1 for py-spy. I would love to try out Scalene but the application I have does something funky with pickling for multiprocessing, breaking Scalene in the process (my fault, not Scalene's, I'll be looking into that). Py-spy worked, including catching all the sub-processes. Feeding the py-spy JSON output into https://speedscope.app makes for a very easy way to profile in a time crunch if you don't have time to get familiar with CLI tools or can't install stuff locally but have a browser and internet connection.
Re:Scalene: A high-performance, high-precision CPU, GPU, mem... by emeryberger on Tuesday October 22, 2024 @11:02AM (#41914990)
Scalene author here - please file an issue!
Re:Scalene: A high-performance, high-precision CPU, GPU, mem... by embeng4096 on Tuesday October 22, 2024 @11:18AM (#41915151)
I will! I'll try to pare down my customer's code into a minimal example I can post.
Re:Scalene: A high-performance, high-precision CPU, GPU, mem... by motbus3 on Friday October 25, 2024 @08:38AM (#41944654)
Scalene is great too. I actually use to find some memory allocation problems that were quite hard do pin.
Re:Scalene: A high-performance, high-precision CPU, GPU, mem... by carlmr on Tuesday October 22, 2024 @11:06AM (#41915026)
>where people told me there were network problems but it was actually not

Always ask if they assume it's network bound or they have measurements. Measurements may sometimes be wrong, but assumptions are more often wrong than right in performance engineering.