Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
To control RDS latency, many blocks in rds_tx.grc have a maximum output buffer size (Maxoutbuf) specified. As noted in #83 (comment), this causes excessively high CPU utilization. This stems almost entirely from the high-sample-rate blocks (Multiply, Add, Frequency Mod) which contribute a negligible amount to the overall RDS latency. Removing the Maxoutbuf setting for these blocks reduces CPU utilization by about 65% without any noticeable effect on latency.
Also, two low-sample-rate blocks (RDS Encoder, Chunks to Symbols) do not specify a maximum output buffer size. Adding the setting to the RDS Encoder block reduces RDS latency from 72 seconds to 20. I've added the setting to the Chunks to Symbols block as well, but unfortunately it has no effect at the moment due to a bug in GNU Radio: gnuradio/gnuradio#7534. If that bug is fixed, then another 7 seconds of latency could be removed.
As noted in #83 (comment), a better way to control latency would be to use the approach taken by gr-latency_manager: have the RDS Encoder block generate stream tags, and limit its output until those tags are seen downstream. That's a bigger change, so I thought it would make sense to do a quick fix to the Maxoutbuf settings first, which already gives a substantial improvement.