mirror of https://github.com/VLSIDA/OpenRAM.git
Don't converge only after a successful measurement.
This commit is contained in:
parent
5e33781268
commit
7d0d590879
|
|
@ -345,20 +345,19 @@ class delay():
|
||||||
|
|
||||||
target_period = 0.5 * (ub_period + lb_period)
|
target_period = 0.5 * (ub_period + lb_period)
|
||||||
debug.info(1, "MinPeriod Search: {0}ns (ub: {1} lb: {2})".format(target_period,
|
debug.info(1, "MinPeriod Search: {0}ns (ub: {1} lb: {2})".format(target_period,
|
||||||
ub_period,
|
ub_period,
|
||||||
lb_period))
|
lb_period))
|
||||||
|
|
||||||
(success, delay_out) = self.try_period(feasible_period, target_period, data_value)
|
(success, delay_out) = self.try_period(feasible_period, target_period, data_value)
|
||||||
if success:
|
if success:
|
||||||
if ch.relative_compare(ub_period, target_period):
|
|
||||||
# use the two values to compare, but only return the ub since it is guaranteed feasible
|
|
||||||
(success, delay_out) = self.try_period(feasible_period, ub_period, data_value)
|
|
||||||
return (ub_period, delay_out)
|
|
||||||
fail_flag = False
|
|
||||||
ub_period = target_period
|
ub_period = target_period
|
||||||
else:
|
else:
|
||||||
lb_period = target_period
|
lb_period = target_period
|
||||||
|
|
||||||
|
if ch.relative_compare(ub_period, lb_period):
|
||||||
|
# use the two values to compare, but only return the ub since it is guaranteed feasible
|
||||||
|
(success, delay_out) = self.try_period(feasible_period, ub_period, data_value)
|
||||||
|
return (ub_period, delay_out)
|
||||||
|
|
||||||
self.error("Should not reach here.",-1)
|
self.error("Should not reach here.",-1)
|
||||||
return (target_period, delay_out)
|
return (target_period, delay_out)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue