Netlist::Module(3)
πΈ NAME πΈ
okay so this is Netlist::Module(3), a page from the User Contributed Perl Documentation crew, and it's literally about Verilog::Netlist::Module β Module within a Verilog Netlist. periodt π
π¦ SYNOPSIS π¦
the synopsis vibe is:
use Verilog::Netlist;
...
my $module = $netlist->find_module('modname');
my $cell = $self->find_cell('name')
my $port = $self->find_port('name')
my $net = $self->find_net('name')
β¨ DESCRIPTION β¨
A Verilog::Netlist::Module object gets created by Verilog::Netlist for every single module, macromodule, primitive or program in the design. iconic behavior, honestly π
π ACCESSORS π
also see Verilog::Netlist::Subclass for additional accessors and methods. iykyk.
$self->cellsβ returns the list of references toVerilog::Netlist::Cellin the module. the whole cell squad π§$self->cells_sortedβ returns the list of name-sorted references toVerilog::Netlist::Cellin the module. alphabetized besties β¨$self->commentβ returns any comments following the definition. important:keep_comments=>1must be passed toVerilog::Netlist::newfor comments to be retained. no cap, otherwise they ghost you π»$self->find_port_by_indexβ returns the port name associated with the given index. Indexes start at1(pin numbers are traditionally counted from pin 1..pin N, not starting at zero. This was probably an unfortunate choice, sorry.) π$self->is_topβ returns true if the module has no cells referencing it (is at the top of the hierarchy). main character module energy π$self->keywordβ returns the keyword used to declare the module ("module","macromodule","primitive"or"program".) it might at first not seem obvious that programs are considered modules, but in most cases they contain the same type of objects so can be handled identically. π¦$self->nameβ the name of the module. obvi π$self->netlistβ reference to theVerilog::Netlistthe module is under. its home base π$self->netsβ returns the list of references toVerilog::Netlist::Netin the module. net friends π«Ά$self->nets_sortedβ returns the list of name-sorted references toVerilog::Netlist::Netin the module. sorted and slaying β¨$self->nets_and_ports_sortedβ returns the list of name-sorted references toVerilog::Netlist::NetandVerilog::Netlist::Portin the module. mixed friend group, alphabetized π$self->portsβ returns the list of references toVerilog::Netlist::Portin the module. port girlies πΈ$self->ports_orderedβ returns the list of references toVerilog::Netlist::Portin the module sorted by pin number. pin-order realness π₯$self->ports_sortedβ returns the list of references toVerilog::Netlist::Portin the module sorted by name. name-order realness π¦$self->statementsβ returns the list of references toVerilog::Netlist::ContAssignin the module. heads up: other statement types (Always, etc) may also be added to this list in the future. future tea π΅$self->statements_sortedβ returns the list of name-sorted references toVerilog::Netlist::ContAssignin the module. again: other statement types (Always, etc) may also be added to this list in the future. β
π MEMBER FUNCTIONS π
also see Verilog::Netlist::Subclass for additional accessors and methods. yes, same reminder, bestie π
$self->find_cell(name)β returnsVerilog::Netlist::Cellmatching given name. cell hunt activated π$self->find_port(name)β returnsVerilog::Netlist::Portmatching given name. port hunt activated π$self->find_net(name)β returnsVerilog::Netlist::Netmatching given name. net hunt activated π$self->is_libcellβ returns if module declared inside a`celldefine. library-cell mood π$self->levelβ returns the reverse depth of this module with respect to other modules. Leaf modules (modules with no cells) will be level1. Modules which instantiate cells of level1will be level2modules and so forth. also see Netlist'smodules_sorted_level. hierarchy math ate π$self->lintβ checks the module for errors. vibe check but for errors π$self->linkβ creates interconnections between this module and other modules. linking the friend group π«Ά$self->modulename_from_filenameβ uses a rough algorithm (drop the extension) to convert a filename to the module that is expected to be inside it. filename-to-module detective work π΅οΈ$self->new_cellβ creates a newVerilog::Netlist::Cell. new cell just dropped β¨$self->new_portβ creates a newVerilog::Netlist::Port. new port just dropped β¨$self->new_netβ creates a newVerilog::Netlist::Net. new net just dropped β¨$self->dumpβ prints debugging information for this module. dump time, but make it debug π$self->verilog_textβ returns verilog code which represents this module. Returned as an array that must be joined together to form the final text string. important: the netlist must be already->link'edfor this to work correctly. fr fr π₯
π DISTRIBUTION π
Verilog-Perl is part of the <https://www.veripool.org/> free Verilog EDA software tool suite. The latest version is available from CPAN and from <https://www.veripool.org/verilog-perl>. obsessed with a classic π
Copyright 2000-2024 by Wilson Snyder. This package is free software; you can redistribute it and/or modify it under the terms of either the GNU Lesser General Public License Version 3 or the Perl Artistic License Version 2.0. license lore, no cap π
π«Ά AUTHORS π«Ά
Wilson Snyder <wsnyder@wsnyder.org> the author himself π
π SEE ALSO π
Verilog-Perl, Verilog::Netlist::Subclass Verilog::Netlist the whole linked-up squad π¦
and that's the tea, bestie π β this footer-core moment is from perl v5.42.0, dated 2025-07-25, on the Netlist::Module(3) page. bye π
β¨
π¦ where this page comes from
- fedora 43: perl-Verilog-Perl 3.482-6.fc43 Β· LGPL-3.0-only OR Artistic-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms