llvm / llvm/circt

[FIRRTL][LowerXMR] Simplify now that input probes aren't supported

Open
#7,031 0 comments 0 reactions 0 assignees View on GitHub
enhancement FIRRTL
Dominant language
C++
Stars
2.2k
Forks
524
Avg merge
3d 2h
Merged PRs (30d)
46

Description

With input probes no longer being valid IR, this pass can be simplified.

Paths are now append-only and can be resolved in a single post-order (considering all entry points / instance-graph nodes not just the "main" top) and strictly following their flow via `define` and `ref.sub`/`ref.cast` operations.
(or similar/equivalent formulations, just pointing to what simplification is now possible)

Instead of needing to walk IR repeatedly until convergence (cc #5732), follow the flow of the refs along the dataflow and walk that once[1].

[1] at least once our IR supports the efficient thing here, as-is need to walk the IR to extract the requisite dataflow graph anyway, so shrug. Point is this is a simple flow along the flow of refs now (and bottom-up re:module visiting), shouldn't need to track things to resolve using information discovered later :+1:.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reviewing the LowerXMR pass and the repeated-convergence approach referenced in issue #5732. The desired result is a simpler resolution flow that considers all entry points and instance-graph nodes, follows define/ref.sub/ref.cast paths, and avoids repeated walks until convergence.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
compilers
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.