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

[onert-micro] Fix training configure tool UB #14406

Merged

Conversation

SlavikMIPT
Copy link
Contributor

This commit fixes undefined behavior in training configure tool.

ONE-DCO-1.0-Signed-off-by: Vyacheslav Bazhenov [email protected]

@SlavikMIPT SlavikMIPT force-pushed the onert-micro/train-config/ub-fix branch 2 times, most recently from 9111592 to c7259a1 Compare December 3, 2024 12:41
stamalakhov
stamalakhov previously approved these changes Dec 3, 2024
Copy link
Contributor

@stamalakhov stamalakhov left a comment

Choose a reason for hiding this comment

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

LGTM! Thank you!

This commit fixes undefined behavior in training configure tool.

ONE-DCO-1.0-Signed-off-by: Vyacheslav Bazhenov <[email protected]>
Copy link
Contributor

@Torrero Torrero left a comment

Choose a reason for hiding this comment

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

LGTM, thank you!

@@ -32,7 +32,7 @@ void writeTrainConfigFileDataIntoBuffer(
const auto &train_op_indexes_with_ranks = train_data.trainable_op_indexes_with_ranks;

// Resize to calculated size
auto buffer_size = 8 + train_op_indexes_with_ranks.size() * 2;
auto buffer_size = 8 + train_op_indexes_with_ranks.size() * 3;
Copy link
Contributor

Choose a reason for hiding this comment

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

Could add some comment, please, for explanation of this calculation

Copy link
Contributor

@stamalakhov stamalakhov left a comment

Choose a reason for hiding this comment

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

LGTM! Thank you!

@SlavikMIPT SlavikMIPT merged commit aa9a7b2 into Samsung:master Dec 3, 2024
4 checks passed
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