[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Problem with porting an OOT module to 3.8 (sampling speed)
From: |
Marcus Müller |
Subject: |
Re: Problem with porting an OOT module to 3.8 (sampling speed) |
Date: |
Fri, 2 Oct 2020 16:30:38 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.11.0 |
Hi Wojciech,
On 02.10.20 15:51, Wojciech Kazubski wrote:
> I suppose that in 3.8 the source block has to signal required sample rate to
> GR runtime. Is this correct?
No, that's not correct. The runtime doesn't care about required rates at
all. It just makes blocks produce items as fast as they can.
> How to fix the code?
Good question! Unless you're doing something *very* specific in your
code, I'd honestly blame this on a bug that was introduced during
porting – but I might be wrong.
Two very common tools to investigate this are rather simple:
1. htop (a `top`-alike program with a bit better visualization), with
thread names enabled – that way you can see which block occupies the CPU
the most, because all blocks run in their own thread
2. `perf` (especially, `perf top -a`), which allows you to sample in
which function your CPU cores are most often. That way, you can identify
functions that might be the blockers there.
Best regards,
Marcus