circt icon indicating copy to clipboard operation
circt copied to clipboard

[HW] Move NonLocalAnchor from FIRRTL dialect to HWDialect

Open prithayan opened this issue 4 years ago • 3 comments

The NonLocalAnchor can be used to specify the instance path for uniquely identifying any operation globally. It is used to attach nonlocal annotations in the FIRRTL dialect. Currently it is dropped in the LowerToHW pass.

Move the NonLocalAnchor from FIRRTL dialect to HW dialect, so that we can represent the hierarchical paths in the HW dialect also. This enables the metadata emission to use it to specify the hierarchical paths. In a followup PR, we can enable ExportVerilog to lower this op to a corresponding instance path when used for macro substitution in a VerbatimOp.

prithayan avatar Nov 29 '21 17:11 prithayan

Could we get a design doc or expansion of a rationale doc to explain what this is and what it is used for?

lattner avatar Nov 29 '21 19:11 lattner

Updated the rationale docs with this change.

prithayan avatar Nov 29 '21 22:11 prithayan

@prithayan Is this PR still relevant? If not, please close it.

teqdruid avatar Jul 02 '22 02:07 teqdruid

I think subsumed by later work, closing.

darthscsi avatar Feb 28 '23 05:02 darthscsi