Open
Conversation
800a846 to
d68d824
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
d68d824 to
472cb8d
Compare
472cb8d to
d247e90
Compare
d247e90 to
4e16cdc
Compare
NuojCheng
reviewed
Apr 23, 2026
NuojCheng
reviewed
Apr 23, 2026
NuojCheng
reviewed
Apr 23, 2026
6fec229 to
99fa017
Compare
NuojCheng
reviewed
Apr 23, 2026
Collaborator
NuojCheng
left a comment
There was a problem hiding this comment.
Overall, LGTM! Moving forward, is there a way we can streamline the process for adding new test cases (e.g., for models other than DeepSeek, or different sharding configs)?
552a1d3 to
120edf7
Compare
5777e7a to
cd0562b
Compare
NuojCheng
reviewed
Apr 23, 2026
NuojCheng
approved these changes
Apr 23, 2026
SurbhiJainUSC
approved these changes
Apr 24, 2026
gobbleturk
approved these changes
Apr 24, 2026
Collaborator
gobbleturk
left a comment
There was a problem hiding this comment.
This looks great! Can you also add some documentation in a .md file about this test (e.g. example commands for how to update the HLO). Some users are unfamiliar with what HLO even is, so a brief explanation of the point of this test (to protect performance regressions) as well
…tion updates pipelines integrations execution rules
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.
Description
Goal
This PR introduces an automated checks system that detects unintended compiler transformations or model graph deviations without breaking isolation security constraints.
The PR consists of two core components:
tests/integration/hlo_diff_test.pycomparing against valid base references (stored intests/utils/reference_hlo_*.txt).Update HLO References (for hlo_diff_test.py). This workflow executestests/utils/update_hlo_references.pyin a secure isolated runner environment to recreate all parameterized reference files and push them back to the workspace PR branch.Changes Integrated
Parameterized HLO Graph Diff Validations
tests/integration/hlo_diff_test.py:@pytest.mark.parametrizeto support scaling HLO validation across multiple model configurations.deepseek3), Llama 3 8B (llama3_8b), and Qwen 3 1.7B (qwen3_1.7b).stack_frame_id), sharding hints, and normalize trailing operation naming differences.try...finallyscoping block to clear compilation landing dirs even on assertion failures.MAX_LINES = 2000constant.tests/utils/update_hlo_references.py:reference_hlo_*.txt) before orchestrating thepytestsuite to regenerate them.Secure CI Automation Workflows
.github/workflows/update_reference_hlo.yml:Update HLO References (for hlo_diff_test.py).run_tests_coordinator.ymllayer passingis_update_hlo: true.contents: readcompliance rules.run_tests_against_package.yml, conditionally branches the workload step to process the references update script instead of the normalpytestcheck loop.maxtext_tpu_pathways_unit_testsvia job ignores list in.github/workflows/build_and_test_maxtext.yml.Auto PR Updates Extractions
reference-hlo).tests/utils/reference_hlo_*.txtglob.FIXES: b/502981577
Tests
Manually ran the "Update HLO Reference" workflow on Github Actions to verify it generates a new reference HLO file and creates a new commit in the PR: http://screen/BwgqGAkWGpqqiE7
Checklist
Before submitting this PR, please make sure (put X in square brackets):
gemini-reviewlabel.