Skip to content

High logging overhead #364

Closed
Closed
@almaslov

Description

@almaslov

Hello!
I was profiling some nodes in my project recently and noticed an issue in case of high incoming messages rate(~2-3K hz). In this case rcl_wait consumes significant amount of CPU. About 30-50% of rcl_wait execution time is rcutils_logging_logger_is_enabled_for:
perf_flamegraph_
It looks like most of overhead can be eliminated by removing rcutils_logging_severity_level_from_string and switching to integral log_level as mentioned in comment here and here

Metadata

Metadata

Assignees

No one assigned

    Labels

    help wantedExtra attention is needed

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions