.\" Automatically generated by Pod::Man 4.10 (Pod::Simple 3.35) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{\ . if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" ======================================================================== .\" .IX Title "VRENAME 1p" .TH VRENAME 1p "2019-09-13" "perl v5.28.1" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" vrename \- change signal names across many Verilog files .SH "SYNOPSIS" .IX Header "SYNOPSIS" .Vb 1 \& vrename ... .Ve .SH "DESCRIPTION" .IX Header "DESCRIPTION" Vrename will allow a signal to be changed across all levels of the design hierarchy, or to create a cross reference of signal names. (It actually includes module names, macros, and other definitions, so those can be changed too.) .PP Vpm uses a three step process. First, use .PP .Vb 1 \& vrename \-\-list [...] [....] .Ve .PP This reads the specified files, or all files below the specified directory, and creates a signals.vrename file. .PP Now, edit the signals.vrename file manually to specify the new signal names. Then, use .PP .Vb 1 \& vrename \-\-change [...] [....] .Ve .PP Note that in the signals.vrename file any signal names including special characters must follow Verilog naming rules in that they must be escaped with a leading backslash and trailing space. Vrename will attempt to preserve spacing when changing escaped to non-escaped names and vice-versa, however in some cases extra whitespace may be inserted to ensure proper downstream parsing. .SH "ARGUMENTS" .IX Header "ARGUMENTS" vrename takes the following arguments: .IP "\-\-help" 4 .IX Item "--help" Displays this message and program version and exits. .IP "\-\-version" 4 .IX Item "--version" Displays program version and exits. .IP "\-\-change" 4 .IX Item "--change" Take the signals file signals.vrename in the current directory and change the signals in the design as specified by the signals file. Either \-\-list or \-\-change must be specified. .IP "\-\-changefile {file}" 4 .IX Item "--changefile {file}" Use the given filename instead of \*(L"signals.vrename\*(R". .IP "\-\-changelang" 4 .IX Item "--changelang" Include in the signals.vrename file the template needed to change the language standard for the file. For the first run, use \*(L"\-\-list \&\-\-changelang\*(R" and \-\-language to specify the file's original language, then rerun with the \*(L"\-\-change\*(R" option. The files will get escaped identifiers for the most recent Verilog standard. For example with \-\-language 1364\-2005, \*(L"do\*(R" will become \*(L"\edo \*(R". .IP "\-\-crypt" 4 .IX Item "--crypt" With \-\-list, randomize the signal renames. With \-\-change, compress spaces and comments and apply those renames listed in the file (presumably created with vrename \-\-list \-\-crypt). .Sp The comment /*ENCRYPT_ME*/ must be included in all files that need to be encrypted, or use the \-\-cryptall flag. If a signal should not be encrypted, it can simply be set in the signals.vrename list to be changed to itself. After encrypting, you may want to save the signals.vrename file so you have a key for decoding, and also so that it may be used for the next encryption run. When used in this way for the next encryption run, only new signals will get new encryptions, all other encryptions will be encrypted the same. .IP "\-\-cryptall" 4 .IX Item "--cryptall" As with \-\-crypt, but put cryptic names into signals.vrename even if the file does not include \s-1ENCRYPT_ME.\s0 Generally you will then need to edit the signals.vrename file manually to exclude any top level signals that should be preserved. .IP "\-\-keywords" 4 .IX Item "--keywords" Include keywords in the renaming list. Default is to ignore keywords, as changing a keyword will probably result in unrunnable code, however, occasionally it may be necessary to rename signals which happen to match the name of keywords recently added to the language (such as 'bit'). .IP "\-\-language <1364\-1995|1364\-2001|1364\-2005|1800\-2005|1800\-2009|1800\-2012|1800\-2017>" 4 .IX Item "--language <1364-1995|1364-2001|1364-2005|1800-2005|1800-2009|1800-2012|1800-2017>" Set the language standard for the files. This determines which tokens are signals versus keywords, such as the ever-common \*(L"do\*(R" (data-out signal, versus a do-while loop keyword). .IP "\-\-list" 4 .IX Item "--list" Create a list of signals in the design and write to signals.vrename. Either \-\-list or \-\-change must be specified. .IP "\-\-nowrite" 4 .IX Item "--nowrite" Don't write the actual changes, just report the files that would be changed. .IP "\-\-o {dir}" 4 .IX Item "--o {dir}" Use the given directory for output instead of the current directory. .IP "\-\-read" 4 .IX Item "--read" Read the changes list, allows \-\-list to append to the changes already read. .IP "\-\-xref" 4 .IX Item "--xref" Include a cross reference of where the signals are used. \&\-\-list must also be specified. .SH "DISTRIBUTION" .IX Header "DISTRIBUTION" Verilog-Perl is part of the free Verilog \s-1EDA\s0 software tool suite. The latest version is available from \s-1CPAN\s0 and from . .PP Copyright 2000\-2019 by Wilson Snyder. This package is free software; you can redistribute it and/or modify it under the terms of either the \s-1GNU\s0 Lesser General Public License Version 3 or the Perl Artistic License Version 2.0. .SH "AUTHORS" .IX Header "AUTHORS" Wilson Snyder .SH "SEE ALSO" .IX Header "SEE ALSO" Verilog-Perl, Verilog::Parser