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.5k stars 527 forks source link

gpl: slowdown when activating multi-threading #5626

Open gudeh opened 3 weeks ago

gudeh commented 3 weeks ago

Description

This issue was discovered while addressing non-determinism with GPL when multi-threading was activated (https://github.com/The-OpenROAD-Project/OpenROAD/issues/5360).

I tested the GPL runtime using secure-CI (multiple designs) and locally via a GCP server with Nangate45/Swerv. The tests indicate that activating multi-threading results in the same runtime or, in some cases, even slows down GPL.

I believe the slowdown is due to too many context switches with minimal gain in parallelism, as the loops that use multi-threading typically perform simple mathematical operations.

Suggested Solution

No response

Additional Context

No response

maliberty commented 3 weeks ago

I suggest you look at the PR as they often include data there. There may have been multiple changes.

gudeh commented 3 weeks ago

This is the PR: https://github.com/The-OpenROAD-Project/OpenROAD/pull/4580.

Hi @kbieganski, do you still see improvements in runtime for gpl with MT?

QuantamHD commented 3 weeks ago

It could be the case that the MT only helps on larger designs, and is a net negative on designs below a certain size threshold.