oxidecomputer / idolatry

An experimental IPC interface definition language for Hubris.
Mozilla Public License 2.0
17 stars 11 forks source link

add feature flags for controlling counter codegen #44

Closed hawkw closed 8 months ago

hawkw commented 8 months ago

This commit adds "client-counters" and "server-counters" feature flags to the idol crate to enable the generation of IPC client and server counters. This is a bit easier than doing it in the build script, as it allows the top-level task to control whether it generates client counters, rather than the crate defining the client stub. In particular, a task that depends on many client stub crates can enable counter generation in one place, by setting the feature on its idol dep, without having to manually enumerate all of its client stub dependencies.

The CounterSettings type can still be used to manually override these features.