The-OpenROAD-Project / OpenROAD

OpenROAD's unified application implementing an RTL-to-GDS Flow. Documentation at https://openroad.readthedocs.io/en/latest/
https://theopenroadproject.org/
BSD 3-Clause "New" or "Revised" License
1.44k stars 503 forks source link

Improve PDN warning and error messages when failing to make PDN with macros #4009

Open oharboe opened 10 months ago

oharboe commented 10 months ago

Description

If I add this line:

export PDN_TCL               = $(FLOW_HOME)/platforms/asap7/openRoad/pdn/BLOCKS_grid_strategy.tcl

These error messages go away:

[INFO PDN-0001] Inserting grid: CORE_macro_grid_1 - foo_2
[INFO PDN-0001] Inserting grid: CORE_macro_grid_1 - foo_3
[deleted]
[WARNING PDN-0232] CORE_macro_grid_1 - foo_2 does not contain any shapes or vias.
[WARNING PDN-0232] CORE_macro_grid_1 - foo_3 does not contain any shapes or vias.
[ERROR PDN-0233] Failed to generate full power grid.

Suggested Solution

Improve the warnings and errors above to give the user more actionable guidance.

Additional Context

No response

maliberty commented 10 months ago

If you add that line to what?

oharboe commented 10 months ago

If you add that line to what?

I add this line to our config.mk file for our design(that I can't share publically), then the error above goes away.

maliberty commented 10 months ago

Its hard to say what the message should be if I don't know what the problem is.

maliberty commented 10 months ago

test.zip

@gadfort would you give advise on what the issue and how we could give better messages with the test case attached

gadfort commented 10 months ago

@maliberty the message is just there to indicate that nothing was generated in a particular grid. No vias, straps, rings, etc. So the powergrid is incomplete. I'll look at the testcase and see if there is anything else it could provide

kareefardi commented 3 weeks ago

This still seems to be relevant. Should I file a new issue?

gadfort commented 3 weeks ago

@kareefardi if you have a specific issue, then I would suggest filing a new issue. If you have suggestions for how to improve the error message I would be open to suggestions

oharboe commented 3 weeks ago

I think it would be easier to understand what is going on if the failed result was saved with e.g. 2_error.odb and then one can look at the failed result visually, it would explain failed macro placement better than a thousand carefully articulated error messages... this is a compliment to good error messages of course ...

kareefardi commented 3 weeks ago

@gadfort The current message indicates that the PDN failed to generate but it doesn't say how. In my experience the failure could be for a couple of reasons:

In itself, the message is a bit confusing. I am assuming it means that the grid (not the macro) is empty and doesn't have shapes. I am not sure what is the proper action here but at least as @oharboe is mentioning, having a layout with a PDN that failed to establish this connection would help debug the reason for failure.