From f66999a8830c5829872b93ce15491de1673cb4e3 Mon Sep 17 00:00:00 2001 From: David Shah Date: Sun, 17 Jun 2018 16:03:16 +0200 Subject: Minor performance tweaks and fixes Signed-off-by: David Shah --- common/place_sa.cc | 2 +- common/route.cc | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'common') diff --git a/common/place_sa.cc b/common/place_sa.cc index e8b3725c..12ca30d8 100644 --- a/common/place_sa.cc +++ b/common/place_sa.cc @@ -66,7 +66,7 @@ static float random_float_upto(rnd_state &rnd, float limit) static int random_int_between(rnd_state &rnd, int a, int b) { - return a + int(random_float_upto(rnd, b - a)); + return a + int(random_float_upto(rnd, b - a) - 0.00001); } // Initial random placement diff --git a/common/route.cc b/common/route.cc index 32212c7d..247c8840 100644 --- a/common/route.cc +++ b/common/route.cc @@ -440,8 +440,8 @@ void route_design(Design *design, bool verbose) "routing.\n", int(netsQueue.size())); - ripup_pip_penalty += 5; - ripup_wire_penalty += 5; + ripup_pip_penalty *= 1.5; + ripup_wire_penalty *= 1.5; } } -- cgit v1.2.3