You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Enables TensorIndexer (via IdModel) for six reduction-related test suites by converting test fixture type aliases to proper classes with SetUp() methods.
Key Changes:
Converts using TestName = NVFuserTest; to class definitions with SetUp() override
Each SetUp() calls parent NVFuserTest::SetUp() then enables IdModel with EnableOptionsGuard::getCurOptions().set(EnableOption::IdModel, {"all"})
Affects test suites: ReductionTest, OuterReductionTest, WelfordTest, PersistentBufferTest, PointwiseFusedReductionTest, SerialGridReductionTest
Confidence Score: 5/5
This PR is safe to merge with minimal risk
The changes are mechanical refactorings that follow an established pattern from previous PRs. Each test fixture is converted identically, properly calling parent SetUp() before enabling IdModel. No test logic is modified, only the initialization mechanism changes.
No files require special attention
Important Files Changed
File Analysis
Filename
Score
Overview
tests/cpp/test_outer_reduction.cpp
5/5
Converted test fixture from type alias to class with SetUp() override to enable IdModel for all tests
tests/cpp/test_persistent_buffer.cpp
5/5
Converted test fixture from type alias to class with SetUp() override to enable IdModel for all tests
tests/cpp/test_reduction.cpp
5/5
Converted test fixture from type alias to class with SetUp() override to enable IdModel for all tests
tests/cpp/test_reduction_pointwise.cpp
5/5
Converted test fixture from type alias to class with SetUp() override to enable IdModel for all tests
tests/cpp/test_serial_gridreduce.cpp
5/5
Converted test fixture from type alias to class with SetUp() override to enable IdModel for all tests
tests/cpp/test_welford.cpp
5/5
Converted test fixture from type alias to class with SetUp() override to enable IdModel for all tests
Sequence Diagram
sequenceDiagram
participant TestRunner as Test Runner
participant TestFixture as ReductionTest/WelfordTest/etc
participant NVFuserTest as NVFuserTest Base
participant EnableOptionsGuard as EnableOptionsGuard
participant IdModel as IdModel System
TestRunner->>TestFixture: Create test instance
TestRunner->>TestFixture: Call SetUp()
TestFixture->>NVFuserTest: Call parent SetUp()
NVFuserTest-->>TestFixture: Base initialization complete
TestFixture->>EnableOptionsGuard: getCurOptions().set(IdModel, {"all"})
EnableOptionsGuard->>IdModel: Enable IdModel for indexing
IdModel-->>EnableOptionsGuard: IdModel enabled
EnableOptionsGuard-->>TestFixture: Configuration set
TestFixture-->>TestRunner: Setup complete
TestRunner->>TestFixture: Execute test case
Note over TestFixture,IdModel: All tests run with IdModel enabled
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
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.
Confirmed code diff results are benign