llvm / llvm/circt

[HW][InnerSym] Use Inner* infra, enable verification, support IST on HW...

Open
#4,453 0 comments 0 reactions 0 assignees View on GitHub
documentation enhancement HW Tracking Issue
Dominant language
C++
Stars
2.2k
Forks
524
Avg merge
3d 2h
Merged PRs (30d)
46

Description

There's work to be done regarding InnerSymbols throughout, this issue is to track known tasks and problems, and is intended to be maintained as work on this progresses.

## Tasks

* [x] Make HWModuleLike's IST's
* IST is an HW interface yet none of its operations use it yet.
* [ ] Use IRN in HW, now that it's defined there
* [ ] Add to container op (perhaps move off `builtin.module`?), or maybe make `builtin.module` (optionally? (!)) an IRN.
* Changing the 'container' op is a big change and should not be done without some discussion/review.
* [ ] Enable verification of inner_syms in HW (#3526). Using IRN (+IST) in HW will accomplish this.
* [ ] Audit all users of InnerRef to ensure they work with this and implement `InnerRefUserOpInterface` where appropriate (for verification).
* [ ] Audit any existing verifiers that should instead use the more efficient verification enabled by IRN/IST.
* [ ] Move InnerSymDCE to HW, it's no longer FIRRTL-specific (especially after #4418 which may also do this).
* [ ] Review whether IST can replace HWSymCache or otherwise share code.
* [ ] Review documentation reflects current situation (as needed)
* [ ] HW's rationale docs on ["Symbols and Visibility"](https://github.com/llvm/circt/blob/main/docs/Dialects/HW/RationaleHW.md#symbols-and-visibility) does not seem accurate (and not due to any recent change).
* [ ] Review and be clear about differences between `hw::InnerRefAttr` and `hw::HWInnerRefAttr`.
* I believe the latter is for representing inner references in other dialects? Comments on its introduction: https://github.com/llvm/circt/pull/3005#discussion_r862374300 .
* [x] Drop InnerRefRecord as unused (removed in #5093)

## Abbreviations

IST: InnerSymbolTable
IRN: InnerRefNamespace

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reading the unchecked task list and the HW rationale document, RationaleHW.md, especially its “Symbols and Visibility” section. Then review the referenced InnerRef, InnerSymbolTable, and InnerRefNamespace work and the linked issues and pull requests. Done would require narrowing this tracking issue to a reviewed task and completing its corresponding verification, documentation, or infrastructure changes.

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
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.