openvinotoolkit / openvinotoolkit/npu_compiler

[Performance] Avoid repeated sorting in AsyncDepsInfo dependency queries

Open
#342 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
MLIR
Stars
100
Forks
50
Avg merge
3h 57m
Merged PRs (30d)
1

Description

Problem

getOpDeps() and getConsumerOps() repeatedly copy and sort the same dependency sets. This adds noticeable compile time for large models such as Qwen2.5-7B.

Proposed change

Cache the sorted dependency and consumer lists. Clear only the affected cache entry when dependencies change.

Acceptance criteria

  • Keep the current sorted output and public API.
  • Correctly update the cache after all dependency changes.
  • Handle duplicate dependencies safely.
  • Pass focused and full unit tests.
  • Verify correctness with a real model compile.
  • Show a repeatable improvement on latest upstream.
  • Document the memory cost.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with AsyncDepsInfo::getOpDeps() and getConsumerOps(), then trace every dependency-change path that can affect their results. Done means sorted output and the public API remain unchanged, focused and full unit tests pass, duplicate dependencies are safe, a real Qwen2.5-7B compile is correct, the improvement is repeatable on latest upstream, and memory cost is documented.

Written by the indexing model from the issue text.

Assessment

Domain
compilers, performance
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.