syn: is an inout port supported by synthesize? export creates its block terminal twice and segfaults

Abierto
#11,991 0 comentarios 0 reacciones 1 asignado Ver en GitHub

Los mantenedores suelen responder en 1 día

@povik ya está trabajando en esto.

Desde el 26/10/2026.

Evaluación

Dificultad
3/5
Tiempo estimado
1-2 días
Aptitud para principiantes
55/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
cpp

Línea de trabajo

Start with the Input and Output branches in src/syn/src/flow/export.cc and trace how elaboration represents the reproduced top-level inout port. Run the Nangate45 Tcl sequence from test/ with the Verilog reproducer to confirm the export failure. Done means the issue has a defined outcome for inout ports and the run either exports the intended terminal or reports a clear unsupported case without crashing.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

syn

Is an inout port meant to be supported by synthesize? A top-level module with one ends the run with Signal 11 received in the export to the database.

Reproducer (Nangate45 from test/):

module top(inout [1:0] p, input e, output y);
  assign y = p[0] & e;
endmodule
read_lef Nangate45/Nangate45_tech.lef
read_lef Nangate45/Nangate45_stdcell.lef
read_liberty Nangate45/Nangate45_typ.lib
sv_elaborate design.sv
synthesize

The synthesis passes complete (the stats table prints), and then the process dies during the export, before anything is written.

What seems to happen: elaboration represents the inout port as both an Input instance and an Output instance named p. In src/syn/src/flow/export.cc, the Input branch creates the block terminals p[0] and p[1]. The Output branch then calls dbBTerm::create again for the same names. dbBTerm::create returns nullptr for a name already in the block, and the following bterm->setIoType(odb::dbIoType::OUTPUT) dereferences it.

The question: what is the intended behaviour for an inout port? A few possibilities:

  • one terminal with dbIoType::INOUT (when the Output meets a terminal its Input already created, set the type to INOUT instead of creating a new terminal);
  • a clean logger_->error saying inout ports are not supported yet;
  • or rejecting it earlier, at sv_elaborate.

Any of these would avoid the crash. We are happy to open a PR for whichever you prefer.

Seen at 27288f5c90. The same code is on master (7b3eb039fa).

Lenguaje dominante
Verilog
Estrellas
3.4k
Forks
1.1k
Merge medio
3 d 11 h
PR fusionados (30 d)
245

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de The-OpenROAD-Project/OpenROAD

Todos los issues de The-OpenROAD-Project/OpenROAD

Issues similares

Más issues de Backend & API Design

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.