Src attribute preservation

Following up on @Ravenslofty’s Add node retention tracking through ABC transformations by robtaylor · Pull Request #41 · YosysHQ/abc · GitHub - I’ve been looking into using the “y” XAIGER
extension instead of adding new node retention infrastructure.

The goal is preserving \src attributes on cells through abc/abc9 synthesis passes.

Looking at the current code, vEquLitIds seems to capture a static snapshot rather than tracking identity through passes - Gia_ManDup() and
Gia_ManDupWithAttributes() don’t propagate it, it’s only populated when reading XAIGER with -s or via Gia_ManVerifyFindNameMapping() during
equivalence checking, and the Yosys XAIGER frontend doesn’t read it back.

So I’m not sure how to use it as-is for this. Is the idea to compute the mapping after optimization (e.g. via miter) rather than track it through
each pass? Or is there planned work to extend “y” propagation?

Happy to contribute patches in whatever direction makes sense - just want to build on the right foundation.

Warm regards

Rob

@lofty was too quick for me and already responded in the PR.

i’ll be taking a look at this, and will update here as things progress