smartdevicelink / sdl_core

SmartDeviceLink In-Vehicle Software and Sample HMI
BSD 3-Clause "New" or "Revised" License
241 stars 245 forks source link

Boost Logger CPU Usage #3709

Open Jack-Byrne opened 3 years ago

Jack-Byrne commented 3 years ago

Bug Report

When comparing the default log4cxx build of SDL Core with the Boost logger configured build, the Boost build of SDL Core uses a lot more CPU during video streaming.

Reproduction Steps
  1. Build SDL Core with boost logger
  2. Connect HMI and app and start video stream
  3. Monitor system resource usage in htop.
Expected Behavior

Boost logger build of SDL Core uses a comparable amount of CPU as the LOG4CXX build.

Observed Behavior

Boost build of SDL Core uses over 100% of system CPU when video streaming.

OS & Version Information
ShobhitAd commented 2 years ago

https://github.com/smartdevicelink/sdl_core/pull/3941 improves the CPU usage but is only a partial fix. The CPU usage of the boost build for video streaming logs is still much higher than that of the log4cxx build.

Some other ways to improve CPU usage would be to: