Optimize block delay type check

When looking for a delay_type() in a block stop when we have a
DEFINITE_DELAY. Doing this could reduce the number of statements
that need to be checked.
This commit is contained in:
Cary R 2008-08-28 10:36:22 -07:00 committed by Stephen Williams
parent b455f3af5d
commit 150d51c19b
1 changed files with 1 additions and 0 deletions

View File

@ -2575,6 +2575,7 @@ DelayType NetBlock::delay_type() const
for (const NetProc*cur = proc_first(); cur; cur = proc_next(cur)) {
DelayType dt = cur->delay_type();
if (dt > result) result = dt;
if (dt == DEFINITE_DELAY) break;
}
return result;