Skip to content

Fix: preserve creator edges in deps_viewer reduced and omitted modes#1377

Open
indigo1973 wants to merge 1 commit into
hw-native-sys:mainfrom
indigo1973:dep_0716_2
Open

Fix: preserve creator edges in deps_viewer reduced and omitted modes#1377
indigo1973 wants to merge 1 commit into
hw-native-sys:mainfrom
indigo1973:dep_0716_2

Conversation

@indigo1973

Copy link
Copy Markdown
Contributor

Preserve source=creator edges during transitive reduction because they
encode tensor lifetime retention rather than redundant scheduling
dependencies. Continue reducing transitively covered explicit and
tensormap edges.

Pass edge annotations into the reduction logic, add regression coverage
based on the vector_example dependency pattern, and update the
deps_viewer documentation.

@coderabbitai

coderabbitai Bot commented Jul 16, 2026

Copy link
Copy Markdown

Review Change Stack

Important

Review skipped

Auto incremental reviews are disabled on this repository.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 443613f0-250c-4f58-8c47-b54349b5c5bd

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

deps_viewer now performs annotation-aware transitive reduction: creator-sourced tensor lifetime edges are preserved, while redundant tensormap shortcuts remain removable. CLI documentation and unit tests were updated for the new behavior.

Changes

Lifetime-aware dependency reduction

Layer / File(s) Summary
Lifetime-aware reduction semantics
simpler_setup/tools/deps_viewer.py, simpler_setup/tools/README.md
Structural reduction now protects edges annotated with source=creator, while reduced and omitted modes pass annotations into the reducer and document cycle handling.
Reduction behavior tests
tests/ut/py/test_deps_viewer.py
Test helpers support per-edge sources, and tests cover removal of tensormap shortcuts and retention of creator references.

Estimated code review effort: 2 (Simple) | ~10 minutes

Poem

I’m a bunny guarding edges bright,
Creator threads stay tucked in tight.
Shortcuts hop away in twos,
Tests leave footprints in the views.
Lifetime safe, the graph can glow!

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the main change: preserving creator edges in deps_viewer reduced and omitted modes.
Description check ✅ Passed The description matches the implemented change by explaining creator-edge preservation, continued reduction of other edges, tests, and docs.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Code Review

This pull request updates the transitive reduction logic in deps_viewer.py to preserve tensor-lifetime edges (where source=creator) while continuing to reduce redundant scheduling edges. It also updates the CLI help, documentation, and adds unit tests to verify this behavior. The review feedback suggests adding a defensive type check when parsing annotations to prevent potential AttributeError exceptions from malformed data.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread simpler_setup/tools/deps_viewer.py
- Keep creator references out of v1 structural reduction
- Add reduced_v2 and omitted_v2 with conservative byte-range
  INOUT dataflow proof
- Preserve OUTPUT_EXISTING reuse boundaries and document the new modes
- Cover middle-output reduction, cross-round retention, and CLI selection
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant