Skip to content

Adds back a host/systime for demo only. filter it behind a feature flag#927

Merged
gbin merged 4 commits intomasterfrom
gbin/hack-in-systime-back
Mar 15, 2026
Merged

Adds back a host/systime for demo only. filter it behind a feature flag#927
gbin merged 4 commits intomasterfrom
gbin/hack-in-systime-back

Conversation

@gbin
Copy link
Collaborator

@gbin gbin commented Mar 10, 2026

Summary

Related issues

  • Closes #

Changes

Testing

  • just fmt
  • just lint
  • just test
  • optional full just std-ci (if std/runtime paths are impacted)
  • optional full just nostd-ci (if embedded/no_std paths are impacted)
  • Other (please specify):

pro-tip: just with no parameters in the root defaults to just fmt, just lint, and just test.

Checklist

  • I have updated docs or examples where needed
  • I have added or updated tests where needed
  • I have considered platform impact (Linux/macOS/Windows/embedded)
  • I have considered config/logging changes (if applicable)
  • This change is not a breaking change (or I documented it below)

Breaking changes (if any)

Additional context

@gbin gbin added bug Something isn't working enhancement New feature or request exclude from changelog labels Mar 10, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds an optional “host/system perf timing” path so runtime/process timing metadata can reflect wall-clock execution (especially in sims) while keeping message tov on the robot/sim clock.

Changes:

  • Introduces cu29::curuntime::perf_now() and a new sysclock-perf feature to switch perf timing to a host clock.
  • Updates generated runtime loop + task/bridge execution code to stamp process_time using perf_now().
  • Enables the feature in the balancebot + flight-controller simulation examples and updates their message timing helpers.

Reviewed changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
examples/cu_rp_balancebot/src/sim_driver.rs Uses perf_now() for process_time while preserving simulated tov.
examples/cu_rp_balancebot/Cargo.toml Enables cu29/sysclock-perf for the sim feature set.
examples/cu_flight_controller/src/sim.rs Updates sim message timing to use perf_now() for process_time.
examples/cu_flight_controller/Cargo.toml Enables cu29/sysclock-perf in sim_core.
core/cu29_runtime/src/curuntime.rs Adds perf_now() implementation and docs.
core/cu29_runtime/Cargo.toml Adds sysclock-perf feature flag.
core/cu29_derive/src/lib.rs Switches generated perf/process timing stamps from clock.now() to perf_now().
core/cu29/src/lib.rs Documents the new sysclock-perf feature in crate docs.
core/cu29/Cargo.toml Wires sysclock-perf feature through the cu29 facade crate.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@gbin gbin merged commit 1ad6745 into master Mar 15, 2026
23 checks passed
@gbin gbin deleted the gbin/hack-in-systime-back branch March 15, 2026 21:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working enhancement New feature or request exclude from changelog

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants