Skip to content

fixup#18656

Merged
lucylq merged 1 commit intomainfrom
lfq.fixup-difftrain
Apr 1, 2026
Merged

fixup#18656
lucylq merged 1 commit intomainfrom
lfq.fixup-difftrain

Conversation

@lucylq
Copy link
Copy Markdown
Contributor

@lucylq lucylq commented Apr 1, 2026

Summary

fix failures on D99137671

@lucylq lucylq requested a review from JacobSzwejbka as a code owner April 1, 2026 22:12
Copilot AI review requested due to automatic review settings April 1, 2026 22:12
@pytorch-bot
Copy link
Copy Markdown

pytorch-bot Bot commented Apr 1, 2026

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/18656

Note: Links to docs will display an error until the docs builds have been completed.

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Apr 1, 2026
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 1, 2026

This PR needs a release notes: label

If your change should be included in the release notes (i.e. would users of this library care about this change?), please use a label starting with release notes:. This helps us keep track and include your important work in the next release notes.

To add a label, you can comment to pytorchbot, for example
@pytorchbot label "release notes: none"

For more information, see
https://github.com/pytorch/pytorch/wiki/PyTorch-AutoLabel-Bot#why-categorize-for-release-notes-and-how-does-it-work.

@lucylq lucylq merged commit c39a0ff into main Apr 1, 2026
158 of 163 checks passed
@lucylq lucylq deleted the lfq.fixup-difftrain branch April 1, 2026 22:13
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Fixes a build/test failure from D99137671 by adjusting a printf-style format string in the ATen executor tensor layout validation path.

Changes:

  • Updated the error message format specifier used when reporting dim_order size mismatches in validateTensorLayout().

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +135 to 137
"Dim order size mismatch. Expected %d, got %u.",
dim,
s_tensor->dim_order()->size());
Copy link

Copilot AI Apr 1, 2026

Choose a reason for hiding this comment

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

The format specifier was changed to %u, but s_tensor->dim_order()->size() is a FlatBuffers vector size type (typically uoffset_t/uint32_t), and %u is not guaranteed to match its underlying type on all platforms (e.g., if uint32_t is unsigned long). To avoid -Wformat/UB and match existing code (see tensor_parser_portable.cpp which uses PRIu32 for FlatBuffers sizes), prefer "%" PRIu32 with an explicit static_cast<uint32_t>(...), or cast to size_t and keep %zu.

Suggested change
"Dim order size mismatch. Expected %d, got %u.",
dim,
s_tensor->dim_order()->size());
"Dim order size mismatch. Expected %d, got %zu.",
dim,
static_cast<size_t>(s_tensor->dim_order()->size()));

Copilot uses AI. Check for mistakes.
Jiseong-oh pushed a commit to Jiseong-oh/executorch that referenced this pull request Apr 2, 2026
### Summary
fix failures on [D99137671](https://www.internalfb.com/diff/D99137671)

Co-authored-by: Github Executorch <github_executorch@arm.com>
Jiseong-oh pushed a commit that referenced this pull request Apr 2, 2026
### Summary
fix failures on [D99137671](https://www.internalfb.com/diff/D99137671)

Co-authored-by: Github Executorch <github_executorch@arm.com>
Jiseong-oh pushed a commit that referenced this pull request Apr 7, 2026
### Summary
fix failures on [D99137671](https://www.internalfb.com/diff/D99137671)

Co-authored-by: Github Executorch <github_executorch@arm.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants