chipsalliance / rocket-chip

Rocket Chip Generator
Other
3.19k stars 1.12k forks source link

Add IO Connections for Custom User Field in TL Channels within Xbar #3637

Closed ksungkeun84 closed 2 months ago

ksungkeun84 commented 4 months ago

Please refer to the issue page below. https://github.com/ucb-bar/chipyard/issues/1888

Related issue: https://github.com/ucb-bar/chipyard/issues/1888

Type of change: bug report

Impact: Affect custom user field of TL Channels

Development Phase: proposal | implementation

Release Notes

linux-foundation-easycla[bot] commented 4 months ago

CLA Signed

The committers listed above are authorized under a signed CLA.

ksungkeun84 commented 3 months ago

@jerryz123 Hi Jerry, I've made a PR in the rocket-chip for the issue I reported to the chipyard. Could you please review it? https://github.com/ucb-bar/chipyard/issues/1888

ksungkeun84 commented 3 months ago

@jerryz123 I'm not sure what waiveAll does exactly, but when I remove := DonCare, compilation failed as follows. generators/rocket-chip/src/main/scala/tilelink/Xbar.scala:155:18: error: sink "in_0_a_bits_user_myuserfield_myfield" not fully initialized in "TLXbar".

Could you please guide me a better way to connect userfield than I used?

jerryz123 commented 3 months ago

@sequencer can you assist?

sequencer commented 3 months ago

@sequencer can you assist?

Sure, will have a try this weekend.

ksungkeun84 commented 3 months ago

Thanks @sequencer for you help. Let me know if you have anything from me.

ksungkeun84 commented 2 months ago

Hi @jerryz123 and @sequencer, I'm been digging into this issue and figured out that my initial fix does not work perfectly. After I fully understand about squeezeAll, waiveAll, and DontCare, I'd like to propose better fix.

The fix is very simple and it just make DontCare comes first and then connect bundles. By doing this way, if pair of bundles have the same user field it will neighter waived out nor treated as DontCare.

Would you review my update and merge it if you agree on it?

jerryz123 commented 2 months ago

The new fix looks good. Thanks for investigating

ksungkeun84 commented 2 months ago

Thanks for your quick response!