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

use iostream instead of printf #977

Merged
merged 2 commits into from
Jan 15, 2024

Conversation

va-kuznecov
Copy link
Member

No description provided.

Copy link

github-actions bot commented Jan 12, 2024

Note

This is an automated comment that will be appended during run.

🔴 linux-x86_64-relwithdebinfo: some tests FAILED for commit b3ea45d.

Test history

TESTS PASSED ERRORS FAILED SKIPPED MUTED?
59892 50672 0 3 9206 11

🔴 linux-x86_64-release-asan: some tests FAILED for commit b3ea45d.

Test history

TESTS PASSED ERRORS FAILED SKIPPED MUTED?
15869 15734 0 20 93 22

);

o << buf;
o << '['
Copy link
Collaborator

Choose a reason for hiding this comment

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

15 виртуальных вызовов нам для этого нужно :)

Copy link
Member Author

Choose a reason for hiding this comment

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

ну как мы любим, пусть разработчики компиляторов и процессоров делают свою работу и оптимизируют виртуальные вызовы

Copy link
Member Author

Choose a reason for hiding this comment

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

побенчили с Сашей, получилось, что новая версия строго быстрее

ToString(Sprintf): 5.345924s
Out(snprintf): 5.017919s
ToString(stream): 3.712372s
Out(stream): 3.966677s

@va-kuznecov va-kuznecov merged commit a86783e into ydb-platform:main Jan 15, 2024
2 of 4 checks passed
@va-kuznecov va-kuznecov deleted the cleanup_printf branch January 16, 2024 11:55
@niksaveliev niksaveliev mentioned this pull request Jan 29, 2024
@vitstn vitstn mentioned this pull request Jan 29, 2024
@starlinskiy starlinskiy mentioned this pull request Feb 12, 2024
@vitstn vitstn mentioned this pull request Feb 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants