###
DEF 5.8 C/C++ Programming Interface (Open Licensing Program)

# 8

# DEF File Comparison Utility

The Cadence® Design Exchange Format (DEF) reader provides the following utility for comparing DEF files.

### lefdefdiff

Compares two LEF or DEF files and reports any differences between them.

Because LEF and DEF files can be very large, the lefdefdiff utility writes each construct from a file to an output file in the /tmp directory. The utility writes the constructs using the format:

> section_head/subsection/subsection/ ... /statement

The lefdefdiff utility then sorts the output files and uses the diff program to compare the two files. Always verify the accuracy of the diff results.

Note: You must specify the -lef or -def, inFileName1, and inFileName2 arguments in the listed order. All other arguments can be specified in any order after these arguments.

#### Syntax

lefdefdiff
  {-lef | -def}
inFileName1
  inFileName2
  [-o outFileName]
  [-path pathName]
  [-quick]
  [-d]
  [-ignorePinExtra]
  [-ignoreRowName]
  [-h]

#### Arguments

-d

> Uses the gnu diff program to compare the files for a smaller set of differences. Use this argument only for UNIX platforms.

-h

> Returns the syntax and command usage for the lefdefdiff utility.

-ignorePinExtra

> Ignores any .extra N statements in the pin name. This argument can only be used when comparing DEF files.

-ignoreRowName

> Ignores the row name when comparing ROW statements in the DEF files. This argument can only be used when comparing DEF files.

inFileName1

> Specifies the first LEF or DEF file.

inFileName2

> Specifies the LEF or DEF file to compare with the first file.

-lef | -def

> Specifies whether you are comparing LEF or DEF files.

-o outFileName

> Outputs the results of the comparison to the specified file.
> Default: Outputs the results to the screen.

-path pathName

> Temporarily stores the intermediate files created by the lefdefdiff utility in the specified path directory.
> Default: Temporarily stores the files in the current directory

-quick

> Uses the bdiff program to perform a faster comparison.

### Example

The following example shows an output file created by the lefdefdiff utility after comparing two DEF files:

> #The names of the two DEF files that were compared.

> < in.def

> > out.def

> #Statements listed under Deleted were found in in.def but not in out.def.

> Deleted:

> < BLOCKAGE LAYER m3 RECT 455 454 344 890

> < BLOCKAGE LAYER m3 SLOTS

> < BLOCKAGE LAYER m4 FILLS

> < BLOCKAGE LAYER m4 RECT 455 454 344 890

> < BLOCKAGE LAYER m5 PUSHDOWN

> < BLOCKAGE LAYER m5 RECT 455 454 344 890

> < BLOCKAGE PLACEMENT

> Deleted:

> < BLOCKAGE PLACEMENT PUSHDOWN

> Deleted:

> < BLOCKAGE PLACEMENT RECT 4000 6000 8000 4000

> < BLOCKAGE PLACEMENT RECT 4000 6000 8000 4000

> #Changed always contains two statements: the statement as it appears in in.def and the statement as it appears in out.def.

> Changed:

> < COMP |i1 UNPLACED

> < DESIGN muk

> ---

> > DESIGN cell

> Changed:

> < NET net1 USE SCAN

> ---

> > NET net1 WEIGHT 30 SOURCE TIMING ORIGINAL VDD USE SCAN

> Changed:

> < NET net3 SOURCE USER PATTERN BALANCED ORIGINAL extra_crispy USE SIGNAL

> ---

> > NET net3 SOURCE USER PATTERN BALANCED ORIGINAL extra_crispy

> #Statements listed under Added were found in out.def but not in in.def.

> Added:

> > NET SCAN ( PIN scanpin )

> Added:

> > NET net1 ( PIN pin1 )

> Added:

> > NET net2 ( PIN pin2 )

Return to top of page

For support, see Cadence Online Support service.
Copyright © 2016, Cadence Design Systems, Inc.
All rights reserved.