From b76891e3a27dc641a391885ec61fb8b00e2f8822 Mon Sep 17 00:00:00 2001 From: "yu.dongliang" <18588496441@163.com> Date: Mon, 30 Oct 2023 21:59:37 +0800 Subject: [PATCH] ses_lines_same_components() --- ses_layout.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/ses_layout.c b/ses_layout.c index c9d2b6b..b0f4c9a 100644 --- a/ses_layout.c +++ b/ses_layout.c @@ -430,12 +430,16 @@ int ses_lines_same_components(ScfEfunction* f) N_PINS = el0->n_pins; } - for (n = 0; n < 5; n++) { + scf_loge("N_PINS: %ld\n", N_PINS); + + N_PINS = N_PINS < 8 ? 8 : N_PINS; + + for (n = 0; n < N_PINS / 2 - 2; n++) { for (i = 0; i < f->n_elines; i++) { el0 = f->elines[i]; - if (el0->n_pins > 4) + if (el0->n_pins > N_PINS / 2 - n) continue; for (j = i + 1; j < f->n_elines; j++) @@ -487,8 +491,6 @@ int ses_lines_same_components(ScfEfunction* f) } // printf("\n"); } - - scf_loge("N_PINS: %ld\n", N_PINS); #endif return 0; -- 2.25.1