-
Notifications
You must be signed in to change notification settings - Fork 10.3k
Slightly improve the performance of removeNullCharacters #17165
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
Conversation
I profiled pdf.pdf with a sampling interval equals to 0.1ms. |
It might not matter all that much, performance wise, but given how and where this helper function is being used do we still need the following part of it? Lines 216 to 219 in f098121
(This function was originally placed in |
Most of the strings shouldn't contain special chars (<= 0x1F) so we can have a fast path which just checks if the string contains at least one such a char.
bc68ce2
to
651057c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
r=me, thank you!
/botio integrationtest |
From: Bot.io (Windows)ReceivedCommand cmd_integrationtest from @calixteman received. Current queue size: 0 Live output at: http://54.193.163.58:8877/8578b21c45edd38/output.txt |
From: Bot.io (Linux m4)ReceivedCommand cmd_integrationtest from @calixteman received. Current queue size: 1 Live output at: http://54.241.84.105:8877/8cc62fdc5c36313/output.txt |
From: Bot.io (Linux m4)SuccessFull output at http://54.241.84.105:8877/8cc62fdc5c36313/output.txt Total script time: 5.56 mins
|
From: Bot.io (Windows)FailedFull output at http://54.193.163.58:8877/8578b21c45edd38/output.txt Total script time: 18.78 mins
|
Most of the strings shouldn't contain special chars (<= 0x1F) so we can have a fast path which just checks if the string contains at least one such a char.