dfs loop
authoryu.dongliang <18588496441@163.com>
Tue, 18 Jul 2023 08:38:47 +0000 (16:38 +0800)
committeryu.dongliang <18588496441@163.com>
Tue, 18 Jul 2023 08:38:47 +0000 (16:38 +0800)
Makefile
ses_layout.c

index 24429856d9b7b0deee0ec756e49c3ff176868dd3..db296b3496ca2c0812e9a1aba45dda0da30824e4 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -2,6 +2,7 @@ CFILES += main.c
 CFILES += scf_eda.pb-c.c
 CFILES += scf_eda_pb.c
 CFILES += ses_layout.c
+CFILES += ses_loop.c
 
 CFLAGS += -g
 CFLAGS += -I./
index 8a2589cae2800b6551e1d9411ae7a502ed93bbb8..2d299a4ef4c78b95302f0bba577160418b22d28c 100644 (file)
@@ -954,6 +954,7 @@ int ses_layout_draw(ScfEboard* b, uint32_t bx, uint32_t by, uint32_t bw, uint32_
 int ses_layout_board(ScfEboard* b)
 {
        ScfEfunction*  f;
+       scf_vector_t*  loops;
 
        size_t i;
        size_t j;
@@ -983,6 +984,12 @@ int ses_layout_board(ScfEboard* b)
                y = f->y;
                w = f->w;
                h = f->h;
+
+               loops = scf_vector_alloc();
+               if (!loops)
+                       return -ENOMEM;
+
+               ses_loop_function(f, loops);
        }
 
        ses_layout_draw(b, x, y, w, h);