-
Notifications
You must be signed in to change notification settings - Fork 3.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Control release mode debug logging output by ENABLE_DEBUG_LOGGING option #5628
Control release mode debug logging output by ENABLE_DEBUG_LOGGING option #5628
Conversation
As I write in #3427 (comment), the performance of debug log is acceptable. |
Can it be a compile time option? So one will be able to choose, whether debug output should not be compiled at all in release mode, or compiled in but not visible by default? |
Technically it's ok to be a compile time option, actually the |
I think whether performance is acceptable or not depents where the debug log output is being generated. If someone places a debug message in one of the important loops during data processing, even if logging is suppressed, it could increase processing time. My preference would be to leave the current behaviour by default - compile-time-disable debug logging, but may be add a CMake rule that enables debug logging for release builds if it's desired. |
@danpat I have added cmake option |
Issue
What issue is this PR targeting? If there is no issue that addresses the problem, please open a corresponding issue and link it here.
#3427
Please read our documentation on release and version management.
If your PR is still work in progress please attach the relevant label.
Tasklist
Requirements / Relations
Link any requirements here. Other pull requests this PR is based on?