klayout
klayout copied to clipboard
Support for standalone LEF files
It would be nice to read a LEF file on its own in order to verify the abstracts generated for leaf cells. These LEFs are typically quite simple, but can require their own UNITS, i.e.:
UNITS
DATABASE MICRONS 1000 ;
END UNITS
As I (now) understand this isn't supported by klayout yet. I can open the LEF file but with the UNITS stanza it fails:
Trying to read this in klayout yields an error:
(The full file is here: test.lef.zip)
Without that stanza I imagine it's treated more or less like a DEF file, and renders correctly.
There is a misunderstanding. KLayout does not read LEF files. It reads DEF files, and supports LEF as companion files. There is no "LEF" format support on "File/Open".
The only way currently to import LEF alone is by using "File/Import/LEF".
LEF-only support is questionable as LEF files often are only meaningful together with other LEF files (technology LEF) and a single LEF file often is not comprehensible without that context. A DEF file in that sense it is top level entity from which reading of a layout makes sense.
If you need LEF-only support, please rephrase the issue to an enhancement: support LEF-only file reading.
Matthias
I see! Thank you for clarifying. I will rephrase the issue.
Very good. I'd like to know what the master of LEF/DEF (@stefanottili) has to say to that :)
Besides “just having a look”, the other use case to read Macro lef is to be able to compare (dbdiff/xor) IP deliverables. Unlike reading def there is no need to read technology lef to read macro lef. So there is no reason not to read pin and obs geometry and pin text of macro lef files and treat it as layout data the same way you would with gds/oasis/def or drc results.
Is this "as simple" as adding support for the DATABASE
unit-spec line for LEFs?
No that is not the issue. LEF reading works. But when you use "File/Open", DEF is expected. LEF is not supported yet.
Did not want to close it.