---
name: "lvx"
section: "1"
platform: "linux"
package: "alliance"
version: "5.1.1-3"
release: "Debian 10 (Buster)"
platforms: ["linux"]
url: "https://new.carta.tech/lvx"
---

# lvx(1)

Logical Versus eXtracted net-list comparator

## NAME

lvx - Logical Versus eXtracted net-list comparator

## SYNOPSIS

- **lvx** *format1 format2 filename1 filename2* **\[ -a \] \[ -u \] \[ -o \] \[ -f \]**

  ## DESCRIPTION

**lvx** compares two gate-level or block level net-list. The goal is to compare a specification net-list (logical net-list), the input to a place and route tool, with the physical net-list (extracted net-list) obtained by the [**cougar**(1)](/cougar/1.md) extractor.\
 The net-list 1 is considered as the logical net-list and net-list 2 as the extracted net-list.\
\
 **lvx** is an one-level hierarchical tool:

-

  The two net-list are flattened, if the **-f** option is present, to the cells contained in the catalog file. The path to the catalog file is indicated in the [**MBK\_CATA\_LIB**(1)](/MBK_CATA_LIB/1.md) variable for the cell library, and in the [**MBK\_WORK\_LIB**(1)](/MBK_WORK_LIB/1.md) variable with the name [**MBK\_CATAL\_NAME**(1)](/MBK_CATAL_NAME/1.md) for user blocks ( [**catal**(5)](/catal/5.md) ) that are not to be flattened.

-

  For both net-list, the instances are considered as black-boxes.

-

  The two net-list must have the same external connectors names.

-

  The two net-list must have the same instances names.

-

  The two net-list must have the same signals names for unconnected signals.

-

  The two net-list cannot directly contain transistors.

Comparison is performed in three steps:

-

  Compare terminals.

-

  Compare instances.

-

  Compare connections.

-

  Compare unconnected signals.

If an error occurs during first or second step, a message is immediately displayed and the third step will not start: **lvx** cannot compare connections (signals) if terminals or instances are not equivalent.\
 The **-o** option allows to order connectors if the steps described before have been reached successfully. *Extracted\_netlist* is then saved on disk. The file get the name *filename2* suffixed by the value of [**MBK\_OUT\_LO**(1)](/MBK_OUT_LO/1.md) variable.\
 Routers add automatically empty feed-through cells. These cells must not be taken into account in the comparison. A cell that have the *F* attribute in the catalog file ( **catal (5)** ) is considered as feed-through cell, and are deleted, in memory, from the net-list where it appears.

## OPTIONS

- **-a**

  Some routers generate layout with several physical connectors for power and ground ( *VDD* or *VSS* ). If those connectors are not internally connected, they will have different indexed names ( *VDD1* , *VDD2* etc...) in the extracted net-list. It is possible to perform reduction on those power and ground connectors before comparison, using the -a option. After reduction, each instance contains only one *VDD* connector and one *VSS* connector, as the main figure.

- **-o**

  In this case, **lvx** produces a modified net-list (saved with the name *filename2* ), which is a copy of net-list 2 with ordered connectors. Terminals and instance connectors are relisted in the order of the models in net-list 1. The saved net-list is done with the [**MBK\_OUT\_LO**(1)](/MBK_OUT_LO/1.md) format, so user has to set this variable before running **lvx** . If he does not, default value is used, and net-list 1 could be lost if filename are identical and input format same as output format.\
   If -a option is used, then the saved net-list is the reduced net-list with only one *VDD* and one *VSS* .

- **-u**

  This option force  **lvx** to check the consistency of unassigned signals between the two netlists.

- **-f**

  The two net-lists are flattened to the leaf cells contained in the catalog file. Usually the extracted net-list is a flatten net-list, while the logical one can be a hierarchical net-list.

## EXAMPLES

With *logical\_netlist* named amd2901.vst and the corresponding *extracted\_netlist* as amd2901.al containing multiple power connectors, the command line is :\

-

  **lvx** vst al amd2901 amd2901 -a\

## OUTPUT FILES

- *filename2*.***xx***

  Netlist view saved when the **-o** option is present. The suffixe depend on the [***MBK\_OUT\_LO***(1)](/MBK_OUT_LO/1.md) environment variable.

## ENVIRONMENT VARIABLES

- ***MBK\_CATA\_LIB***

  contains the directories where the cell librtaries are. ***MBK\_WORK\_LIB*** contains the directory path of the working directory, usually set to ***.*** (dot).

- ***MBK\_OUT\_LO***

  contains the expected format of the netlist output.

- ***MBK\_CATAL\_NAME***

  contains the name of the user cell catalog.

## SEE ALSO

[**cougar**(1)](/cougar/1.md), [**MBK\_OUT\_LO**(1)](/MBK_OUT_LO/1.md), [**MBK\_WORK\_LIB**(1)](/MBK_WORK_LIB/1.md), [**MBK\_CATA\_LIB**(1)](/MBK_CATA_LIB/1.md), [**MBK\_CATAL\_NAME**(1)](/MBK_CATAL_NAME/1.md), [**catal**(5)](/catal/5.md) .

## DIAGNOSTICS

The string "\_logic" is appended to the net-list 1 and the string "\_extract", is appended to the net-list 2.

Two kinds of error message can occur:

-

  A fatal error causes the program to exit. It happens when one of the net-lists is not correct, **lvx** cannot construct internal structure for compare.

-

  A compare error occurs when the figures are not identical. It happens when basic objects (instances, connectors) do not exist in both net-list, or when connections (signals) do not connect same terminals or instances in the two net-lists.

Exit code 0 is returned for identical net-lists.
