[hipblaslt] Fix bug in TensorDescriptor#7050
Merged
minsukim-amd merged 1 commit intoMay 5, 2026
Merged
Conversation
bnemanich
approved these changes
May 4, 2026
Codecov Report✅ All modified and coverable lines are covered by tests. ❌ Your project status has failed because the head coverage (77.83%) is below the target coverage (80.00%). You can increase the head coverage or adjust the target coverage. Additional details and impacted files@@ Coverage Diff @@
## develop #7050 +/- ##
========================================
Coverage 64.73% 64.73%
========================================
Files 2108 2108
Lines 328677 328677
Branches 43144 43144
========================================
Hits 212750 212750
Misses 98006 98006
Partials 17921 17921
*This pull request uses carry forward flags. Click here to find out more. 🚀 New features to boost your workflow:
|
aledudek
pushed a commit
that referenced
this pull request
May 20, 2026
## Motivation PR #6499 ("[hipblaslt] Add support for gfx950 mxfp4") changed `DataTypeInfo::elementSize` from `size_t` → `float` to support sub-byte FP4/FP6 packed types, but missed updating one assert in `tensilelite/include/Tensile/TensorDescriptor.hpp:352`. The expression `totalAllocatedElements() * info.elementSize % info.packing` then evaluates to `float % size_t`, which the C++ compiler rejects with: `error: invalid operands to binary expression ('float' and 'const size_t' (aka 'const unsigned long'))` ## Technical Details Uses the existing `multiplyElementSize` helper from `Utils.hpp` (already included). It properly handles the float `elementSize` for both whole-byte (≥1.0) and sub-byte (0.5, 0.75) cases, returning a `size_t`. ## Test Plan Build hipblaslt via `install.sh` locally ## Test Result `MessagePack.cpp` now builds clean ## Submission Checklist - [ ] Look over the contributing guidelines at https://github.com/ROCm/ROCm/blob/develop/CONTRIBUTING.md#pull-requests.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
PR #6499 ("[hipblaslt] Add support for gfx950 mxfp4") changed
DataTypeInfo::elementSizefromsize_t→floatto support sub-byte FP4/FP6 packed types, but missed updating one assert intensilelite/include/Tensile/TensorDescriptor.hpp:352. The expressiontotalAllocatedElements() * info.elementSize % info.packingthen evaluates tofloat % size_t, which the C++ compiler rejects with:error: invalid operands to binary expression ('float' and 'const size_t' (aka 'const unsigned long'))Technical Details
Uses the existing
multiplyElementSizehelper fromUtils.hpp(already included). It properly handles the floatelementSizefor both whole-byte (≥1.0) and sub-byte (0.5, 0.75) cases, returning asize_t.Test Plan
Build hipblaslt via
install.shlocallyTest Result
MessagePack.cppnow builds cleanSubmission Checklist