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

Replace strlen with sizeof for kconfig string #10466

Merged
merged 1 commit into from Sep 2, 2023

Conversation

xiaoxiang781216
Copy link
Contributor

Summary

improve the speed and reduce the code size a little bit

Impact

code refactor

Testing

ci

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
@pkarashchenko
Copy link
Contributor

I think it will not bring a speed and size impact. Maybe only with O0. I've experimented with similar things in the past and compiler computes all possible things at compile time so strlen call will not be inserted, but the computed value will be used.
But I do not have any objections to this change.

@pkarashchenko pkarashchenko merged commit 7f3a76c into apache:master Sep 2, 2023
26 checks passed
@xiaoxiang781216 xiaoxiang781216 deleted the sizeof branch September 2, 2023 19:01
@jerpelea jerpelea added this to To-Add in Release Notes - 12.3.0 Sep 26, 2023
@jerpelea jerpelea moved this from To-Add to done in Release Notes - 12.3.0 Oct 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Development

Successfully merging this pull request may close these issues.

None yet

3 participants