Skip to content
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

Log path strings directly instead of accumulating #7718

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

Diff-fusion
Copy link

Accumulating all discovery paths into one string causes major slowdowns: #7377
This fixes the issue by immediately writing the names out instead of accumulating them. Additionally a check is added to skip the loop entirely if logging is disabled for the given log level.

Copy link
Collaborator

@claucambra claucambra left a comment

Choose a reason for hiding this comment

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

Seems like a good idea to me, Wdyt @mgallien ?

Copy link
Collaborator

@mgallien mgallien left a comment

Choose a reason for hiding this comment

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

thanks a lot
please see my comment

});

qCInfo(lcEngine()) << "paths to discover locally" << allPaths;
if (lcEngine().isInfoEnabled()) {
Copy link
Collaborator

Choose a reason for hiding this comment

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

can you also add a check for _localDiscoveryPaths not being empty

@Diff-fusion
Copy link
Author

Thanks for looking at this. I added the change.

Signed-off-by: Felix <felix-git@0xf.eu>
Signed-off-by: Felix <felix-git@0xf.eu>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants