Skip to content

question: Clarify rate_target_hz performance #987

@bpousett

Description

@bpousett

Question

I want to run a DAG at 1 kHz, so I set rate_target_hz: 1000 in my copperconfig.ron file. However, when I run it, the Observed rate in the consolemon is consistently ~940 Hz. This is despite the values in the LAT tab being all on the order of nanoseconds.

I turned off rate limiting, and the observed rate hovers around 200 kHz. Furthermore, if I turn up rate_target_hz: 1200 for example, the Observed rate consistently is above 1 kHz (around 1120 Hz), which I think demonstrates that this is not a performance bottleneck with my system. I briefly tried also running on an isolated cpu core. I have not tried running on a real-time kernel, but I would expect these steps to positively impact jitter, whereas my issue is that the rate limiter is limiting the execution speed too much, consistently reducing the throughput.

I read in the book that this issue can be caused by serialization and logging of the CopperList. I tried getting around this by cloning the "getting started" example from the book, turning off all logging, and using the async-cl-io feature. I did not notice any performance difference.

I understand that rate_target_hz is an upper bound for the frequency. My main question is, if Copper can clearly run my list much faster than my upper bound, why isn't the actual frequency tightly limited by this bound?

What I have tried?

Environment

  • OS: Ubuntu 24.04
  • Rust toolchain (rustc -V): rustc 1.93.1 (01f6ddf75 2026-02-11)
  • Copper revision: master branch

Here is a snapshot of my BW tab:

Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions