Repository navigation
Conversation
1 task done
5 tasks done
Contributor
Author
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.
What & why
The delegated
/statuspath multiplies reported GiB/MiB values and casts directly toint64_t. In a reproduction linked to the actual status implementation, a finite1e100report produces-9223372036854775808bytes for RAM and GPU memory. A used-memory value larger than the total also produces negative available/free bytes, with an empty reason.Check that each scaled value is finite, nonnegative and below the exclusive
2^63bound before conversion. Validate both total and used values before subtracting them. Invalid measurements becomenull; unavailable system-memory measurements include a reason. Legitimate zero/fractional reports and the existing subtraction-before-conversion rounding are preserved.Area
edge0-infer/)How was it tested?
Base
f6bfa5546bcf89919f86946ec669bcc7f4cd526d; Linux, GCC 14.2, CMake 4.4.5, CPU preset.2^63rejection and the closest representable double below that boundary. A fractional subtraction control preserves the previous byte rounding.nullplus the system-memory reason afterward.moe_test_strata_registrypassed.ctest --preset cpu -L "L0|L1" --output-on-failure -j 4: 97 passed, 3 Vulkan tests skipped, 4 existing failures. The same base failures aremoe_test_app_generation(std::tmpfileunavailable here),moe_test_platform_memory(Linux expectation), and extreme-float serialization inmoe_test_ordered_json/moe_test_template_tools.proxy,live_progress,check_status_schema, anddialectspassed against the built CLI and repository fake engine over loopback HTTP.git diff --checkpassed. Hardware memory telemetry and GPU/model execution were not tested; this patch validates the values supplied to the status mapper.Checklist