the-openroad-project / opendb Goto Github PK
View Code? Open in Web Editor NEWDatabase and Tool Framework for EDA
License: BSD 3-Clause "New" or "Revised" License
Database and Tool Framework for EDA
License: BSD 3-Clause "New" or "Revised" License
Now that OpenDB can read a 5.8 LEF file, how can I access the information that has been read using the TCL API?
Adding the following code to the TCL routine that is executed at startup will enable the package loading mechanism to be enabled.
foreach dir $env(TCLLIBPATH) {
if {[file exists $dir/pkgIndex.tcl]} {
source $dir/pkgIndex.tcl
}
}
Note the loop variable dir is used inside the pkgIndex.tcl files to load the TCL source code for a package when the package require
command is called.
Is there a reason that the following lines require a dbSBox to have an even dimension (in DB units)?
Lines 200 to 211 in 3946371
At the end of a session with the database I should be able to save the current database to a file, then I should be able to exit the tool, restart and load the database so that I'm back at the same position.
Currently all the examples are of the dbDatabase_create variety.
If I try to save a database with dbDatabase_write I get a type error
% $db write test.odb
TypeError in method 'dbDatabase_write', argument 2 of type 'FILE *'
For read:
% $db read test.odb
TypeError in method 'dbDatabase_read', argument 2 of type 'FILE *'
does this imply that I have to create a database in order to load a database?
You seem to be missing that....
There are some use cases where it is necessary to be able to delete objects from the database. For example, the PDN module inserts a power grid for the design, but this will clash with any existing nets defined in the incoming database.
There is a -delete function on many of the objects, however, this seems to delete the TCL object and doesnt affect the underlying database.
I am not blocked by this issue, as I can massage my incoming testcases - removing offending objects in my input DEF before loading into a database, so I would consider it "low" priority.
The enclosed testcase.tgz includes data and unit tests to be added to OpenDB.
The library data is based on the nangate45 open library
The first testcase, gcd_def_access_checks.tcl looks at floorplan.def. 43 out of 54 tests pass in this suite.
The second testcase, gcd_pdn_def_access_checks.tcl looks at gcd_pdn.def. 50 out of 69 tests pass in this suite
It is not normal practice to concatenate LEF files together into a single file before reading into a tool.
Normally there is a single LEF file that defines the technology - this file is specified first in a list of LEF files, and is read first in order to define all the layers etc. Subsequent LEF files are read and add cells to the library.
Hi I'm a student from UT Austin and I'm trying to use OpenDB to read Lef/Def for my router which is in C++.
My understanding of using it is:
dbDatabase db;
lefin lef(&db, false);
defin def(&db);
lef.readLef(lefFileName);
def.createChip(.....);
etc.
My question is, the readLef function in lefin is private. I'm unable to call it. Should it be public?
Could you please provide a simple example just to show how to read and write LEF/DEF?
I wrote some additional tests to examin vias that are created from via rules - the tests pass, so nothing to fix, but it would be good to incorporate the tests into the regression test suite.
A sample of such statements can be seen in the .defok files in most of the tools. For example:
https://github.com/The-OpenROAD-Project/OpenROAD/blob/openroad/src/replace/test/ar01.defok#L1-L2
https://github.com/The-OpenROAD-Project/OpenROAD/blob/openroad/src/resizer/test/buffer_ports1.defok#L1-L2
https://github.com/The-OpenROAD-Project/OpenROAD/blob/openroad/src/opendp/test/simple05.defok#L1-L2
For some more context, see this: The-OpenROAD-Project/OpenROAD#452 (review)
Thanks.
The README.md file in the project does not have the instructions to install the dependencies flex
, bison
, tcl-dev
to build the project. I would like to add it to the README.md file.
An example of how wires should be constructed in the database would be very helpful - its not intuitive from just looking at the names of the functions that are available.
Need to have a function available from TCL to load a DEF file that will append it's data into an existing design.
Currently apply_pdn works by generating a DEF file, then merging it with the original input DEF file. This capability is available in existing EDA tools.
The integration of OpenDB with Python provides it as a package that gets loaded into the Python interpreter.
The same can be done with TCL. Rather than having a separate executable, if opendbtcl is built as a shared object library, then it can be loaded into any TCL shell through the package loading mechanism.
Alongside the shared object library there would be a TCL file called pkgIndex.tcl, which would load the shared object library if required. This would look something like:
package ifneeded opendbtcl 1.0.0 [list load $dir/libopendbtcl.so]
The end user would add the path of the directory where the pkgIndex.tcl file could be found to the environment variable TCLLIBPATH so that all the packages are known (but not loaded) when the tclsh starts up.
More information on the TCL load command:
http://tmml.sourceforge.net/doc/tcl/load.html
To use the opendbtcl package, the end user would do the following:
% tclsh
> package require opendbtcl
Taking this approach will make the python/tcl approach more consistent and tidy up some loose ends in the current opendbtcl binary [e.g. the package mechanism not working]
According to the header comments in db.h#L934:
/// Get the parent block this block. Returns NULL if this block is the
/// top-block of the chip.
///
dbBlock * getParent();
However, when getting the parent of a top-level block in the tcl shell, it causes an assertion failure and crashes the shell:
opendbtcl: /OpenDB/src/db/dbTable.h:126: T* odb::dbTable<T>::getPtr(uint) const [with T = odb::_dbBlock; uint = unsigned int]: Assertion `(id != 0) && (page < _page_cnt)' failed.
Aborted (core dumped)
I would expect the function to return NULL or gracefully error. Is this the expected behavior?
A code snippet which will reproduce the crash:
set db [dbDatabase_create]
set lef_parser [new_lefin $db true]
set def_parser [new_defin $db]
set lib [lefin_createTechAndLib $lef_parser gscl45nm ./OpenDB/tests/data/gscl45nm.lef]
set chip [$def_parser createChip {$lib} ./OpenDB/tests/data/design.def]
set block [dbChip_getBlock $chip]
dbBlock_getParent $block
Running the enclose tcl script on a DEF with a component that has a HALO defined, the output DEF has written an illegal syntax for the HALO description. From the transcript you can see that parentheses have been used
halo_test.tar.gz
when writing out the DEF that should not be present.
Transcript as follows:
% set db [dbDatabase_create]
odb_read_lef $db nangate45/NangateOpenCellLibrary.mod.lef
odb_read_def [$db getLibs] halo_test.input.def
odb_write_def [[$db getChip] getBlock] halo_test.output.def DEF_5_6
dbDatabase_destroy $db
_607a2c0200000000_p_odb__dbDatabase
% % No Logger: notice 0: Reading LEF file: nangate45/NangateOpenCellLibrary.mod.lef
No Logger: notice 0: Created 22 technology layers
No Logger: notice 0: Created 27 technology vias
No Logger: notice 0: Created 134 library cells
No Logger: notice 0: Finished LEF file: nangate45/NangateOpenCellLibrary.mod.lef
_3011370200000000_p_odb__dbLib
% No Logger: notice 0:
Reading DEF file: halo_test.input.def
No Logger: notice 0: Design: test
No Logger: notice 0: Created 1 components and 5 component-terminals.
No Logger: notice 0: Finished DEF file: halo_test.input.def
_2056340200000000_p_odb__dbChip
% % 1
% % % set db1 [dbDatabase_create]
_607a2c0200000000_p_odb__dbDatabase
% odb_read_lef $db1 nangate45/NangateOpenCellLibrary.mod.lef
No Logger: notice 0: Reading LEF file: nangate45/NangateOpenCellLibrary.mod.lef
No Logger: notice 0: Created 22 technology layers
No Logger: notice 0: Created 27 technology vias
No Logger: notice 0: Created 134 library cells
No Logger: notice 0: Finished LEF file: nangate45/NangateOpenCellLibrary.mod.lef
_709d410200000000_p_odb__dbLib
% odb_read_def [$db1 getLibs] halo_test.output.def
No Logger: notice 0:
Reading DEF file: halo_test.output.def
No Logger: notice 0: Design: test
No Logger: notice 0: error: DEF:17: syntax error, reading (
deflex: token leaked from line 17 with value AND2_X1
deflex: token leaked from line 17 with value test
No Logger: notice 0: Created 1 components and 5 component-terminals.
No Logger: notice 0: Finished DEF file: halo_test.output.def
_b04d380200000000_p_odb__dbChip
% exec diff halo_test.input.def halo_test.output.def
17c17
< - test AND2_X1 + FIXED ( 2784400 517660 ) N + HALO 1600 5120 1600 6060 ;
---
> - test AND2_X1 + FIXED ( 2784400 517660 ) N + HALO ( 1600 5120 ) ( 1600 6060 ) ;
The TCL function dbVia_setViaParams doesn't accept enough arguments, so I'm unable to set the via parameters
% $block getVias
_a0b0839e267f0000_p_odb__dbVia
% set via _a0b0839e267f0000_p_odb__dbVia
_a0b0839e267f0000_p_odb__dbVia
% $via hasParams
0
% set params [$via getViaParams]
_b048730100000000_p_odb__dbViaParams
% $params setNumCutRows 3
% $params getNumCutRows
3
% [$via getViaParams] getNumCutRows
1
% $via hasParams
0
% $via setViaParams $params
Wrong # args.:dbVia_setViaParams self argument 2
Clearly [$via getViaParams] is returning a copy of the viaParams object. This being the case, I need to be able to set the params to a modified set by calling the $via setViaParams function - however, this function does not accept a dbViaParams object as an argument.
Scanning dependencies of target opendb
[ 48%] Building CXX object src/db/CMakeFiles/opendb.dir/dbBTerm.cpp.o
In file included from /usr/include/limits.h:8,
from /root/temp/opendb/include/opendb/odb.h:37,
from /root/temp/opendb/include/opendb/ZException.h:35,
from /root/temp/opendb/src/db/dbAttrTable.h:35,
from /root/temp/opendb/src/db/dbCore.h:47,
from /root/temp/opendb/src/db/dbBTerm.h:37,
from /root/temp/opendb/src/db/dbBTerm.cpp:33:
/root/temp/opendb/src/db/dbAttrTable.h:51:21: error: expected unqualified-id before numeric constant
51 | static const uint PAGE_SIZE;
| ^~~~~~~~~
/root/temp/opendb/src/db/dbAttrTable.h:162:28: error: expected unqualified-id before numeric constant
162 | const uint dbAttrTable::PAGE_SIZE = 32;
| ^~~~~~~~~
/root/temp/opendb/src/db/dbAttrTable.h: In function 'odb::dbOStream& odb::operator<<(odb::dbOStream&, const odb::dbAttrTable&)':
/root/temp/opendb/src/db/dbAttrTable.h:254:39: error: expected unqualified-id before numeric constant
254 | for (j = 0; j < dbAttrTable::PAGE_SIZE; ++j)
[root@cec0efcfcea7 build]$ cmake .. -Wno-dev
-- The CXX compiler identification is GNU 9.3.0
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ - works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found Tclsh: /usr/bin/tclsh (found version "8.6")
-- Found TCL: /usr/lib/libtcl8.6.so
-- Found TCLTK: /usr/lib/libtcl8.6.so
-- Found TK: /usr/lib/libtk8.6.so
-- Found Boost: /usr/lib/cmake/Boost-1.72.0/BoostConfig.cmake (found version "1.72.0")
-- Looking for C++ include pthread.h
-- Looking for C++ include pthread.h - found
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Success
-- Found Threads: TRUE
-- leflib_home: /root/temp/opendb/src/lef
-- Found BISON: /usr/bin/bison (found version "3.6.2")
-- Found ZLIB: /lib/libz.so (found version "1.2.11")
-- Found Boost: /usr/lib/cmake/Boost-1.72.0/BoostConfig.cmake (found version "1.72.0") found components: unit_test_framework
-- Found SWIG: /usr/bin/swig (found suitable version "4.0.1", minimum required is "3.0")
-- Found Python3: /usr/lib/libpython3.8.so (found version "3.8") found components: Development
-- Could NOT find Doxygen (missing: DOXYGEN_EXECUTABLE)
-- Configuring done
-- Generating done
-- Build files have been written to: /root/temp/opendb/build
The lefout.h was recently modified and now fails to compile on our systems. It would appear the issue is a missing #include <string>
in at the header of the file
OpenDB/include/opendb/lefout.h
Line 84 in c095760
Please let me know if you need more information.
Thanks,
Peter
Hi all,
I tried making an application. My Makefile is:
INC = -I/home/muktadir/cse220/OpenDB/include/opendb
LIB = /home/muktadir/cse220/OpenDB/build/src/db/libopendb.a
all: app
app: includeText.cpp ${LIB}
c++ -Wall -pedantic -g $(INC) includeText.cpp -o includeText ${LIB}
clean:
rm -f app
And I am getting these errors:
c++ -Wall -pedantic -g -I/home/muktadir/cse220/OpenDB/include/opendb includeText.cpp -o includeText /home/muktadir/cse220/OpenDB/build/src/db/libopendb.a
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(dbDatabase.cpp.o): In function odb::operator>>(odb::dbIStream&, odb::_dbDatabase&)': dbDatabase.cpp:(.text+0x169d): undefined reference to
odb::ZException::ZException(char const*, ...)'
dbDatabase.cpp:(.text+0x16a4): undefined reference to odb::ZException::~ZException()' dbDatabase.cpp:(.text+0x16ff): undefined reference to
odb::ZException::ZException(char const*, ...)'
dbDatabase.cpp:(.text+0x1706): undefined reference to odb::ZException::~ZException()' dbDatabase.cpp:(.text+0x175e): undefined reference to
odb::ZException::ZException(char const*, ...)'
dbDatabase.cpp:(.text+0x1765): undefined reference to odb::ZException::~ZException()' dbDatabase.cpp:(.text+0x17be): undefined reference to
odb::ZException::ZException(char const*, ...)'
dbDatabase.cpp:(.text+0x17c5): undefined reference to odb::ZException::~ZException()' /home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(dbDatabase.cpp.o): In function
odb::dbDatabase::writeTech(_IO_FILE*)':
dbDatabase.cpp:(.text+0x255c): undefined reference to odb::ZException::ZException(char const*, ...)' dbDatabase.cpp:(.text+0x2563): undefined reference to
odb::ZException::~ZException()'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(dbDatabase.cpp.o): In function odb::ZOutOfMemory::ZOutOfMemory()': dbDatabase.cpp:(.text._ZN3odb12ZOutOfMemoryC2Ev[_ZN3odb12ZOutOfMemoryC5Ev]+0x14): undefined reference to
odb::ZException::ZException()'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(dbDatabase.cpp.o): In function odb::ZIOError::~ZIOError()': dbDatabase.cpp:(.text._ZN3odb8ZIOErrorD2Ev[_ZN3odb8ZIOErrorD5Ev]+0x14): undefined reference to
odb::ZException::~ZException()'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(dbDatabase.cpp.o): In function odb::dbOStream::write_error()': dbDatabase.cpp:(.text._ZN3odb9dbOStream11write_errorEv[_ZN3odb9dbOStream11write_errorEv]+0x39): undefined reference to
odb::ZIOError::ZIOError(int, char const*)'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(dbDatabase.cpp.o): In function odb::dbIStream::read_error()': dbDatabase.cpp:(.text._ZN3odb9dbIStream10read_errorEv[_ZN3odb9dbIStream10read_errorEv]+0x44): undefined reference to
odb::ZException::ZException(char const*, ...)'
dbDatabase.cpp:(.text._ZN3odb9dbIStream10read_errorEv[_ZN3odb9dbIStream10read_errorEv]+0x4b): undefined reference to odb::ZException::~ZException()' dbDatabase.cpp:(.text._ZN3odb9dbIStream10read_errorEv[_ZN3odb9dbIStream10read_errorEv]+0x8d): undefined reference to
odb::ZIOError::ZIOError(int, char const*)'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(dbDatabase.cpp.o): In function odb::ZOutOfMemory::~ZOutOfMemory()': dbDatabase.cpp:(.text._ZN3odb12ZOutOfMemoryD2Ev[_ZN3odb12ZOutOfMemoryD5Ev]+0x14): undefined reference to
odb::ZException::~ZException()'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function _getBits': logger.cpp:(.text+0x4b): undefined reference to
Tcl_AppendResult'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function _getCompileTime': logger.cpp:(.text+0x8d): undefined reference to
Tcl_AppendResult'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function _getCPUTime': logger.cpp:(.text+0x152): undefined reference to
Tcl_AppendResult'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function odb::_allocMem(void*, Tcl_Interp*, int, Tcl_Obj* const*)': logger.cpp:(.text+0x3f8): undefined reference to
Tcl_GetIntFromObj'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function odb::_enableMemCount(void*, Tcl_Interp*, int, Tcl_Obj* const*)': logger.cpp:(.text+0x518): undefined reference to
Tcl_GetIntFromObj'
logger.cpp:(.text+0x549): undefined reference to Tcl_GetDoubleFromObj' logger.cpp:(.text+0x5a5): undefined reference to
odb::AthSignalInstaller(int, void ()(int))'
logger.cpp:(.text+0x5db): undefined reference to odb::AthMemCounter(int)' logger.cpp:(.text+0x5e8): undefined reference to
odb::AthSignalInstaller(int, void ()(int))'
logger.cpp:(.text+0x614): undefined reference to odb::AthMemCounterp(int)' logger.cpp:(.text+0x621): undefined reference to
odb::AthSignalInstaller(int, void ()(int))'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function odb::_setVerbose(void*, Tcl_Interp*, int, Tcl_Obj* const*)': logger.cpp:(.text+0x6e3): undefined reference to
Tcl_GetIntFromObj'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function odb::_setDebug(void*, Tcl_Interp*, int, Tcl_Obj* const*)': logger.cpp:(.text+0x750): undefined reference to
Tcl_GetString'
logger.cpp:(.text+0x767): undefined reference to Tcl_GetString' logger.cpp:(.text+0x77e): undefined reference to
Tcl_GetString'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function odb::_startTimer(void*, Tcl_Interp*, int, Tcl_Obj* const*)': logger.cpp:(.text+0xdbd): undefined reference to
Tcl_AppendResult'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function odb::_showTimer(void*, Tcl_Interp*, int, Tcl_Obj* const*)': logger.cpp:(.text+0xe11): undefined reference to
Tcl_GetString'
logger.cpp:(.text+0xe28): undefined reference to Tcl_GetString' logger.cpp:(.text+0xe3f): undefined reference to
Tcl_GetString'
logger.cpp:(.text+0xe61): undefined reference to Tcl_GetIntFromObj' /home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function
odb::_resetTimer(void, Tcl_Interp*, int, Tcl_Obj* const*)':
logger.cpp:(.text+0xed7): undefined reference to Tcl_GetIntFromObj' /home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function
odb::_getTimer(void*, Tcl_Interp*, int, Tcl_Obj* const*)':
logger.cpp:(.text+0xf40): undefined reference to Tcl_GetIntFromObj' logger.cpp:(.text+0xf90): undefined reference to
Tcl_AppendResult'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function odb::_getCWToken(void*, Tcl_Interp*, int, Tcl_Obj* const*)': logger.cpp:(.text+0xfea): undefined reference to
Tcl_AppendResult'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function odb::_setWarnCount(void*, Tcl_Interp*, int, Tcl_Obj* const*)': logger.cpp:(.text+0x1181): undefined reference to
Tcl_GetString'
logger.cpp:(.text+0x11a3): undefined reference to Tcl_GetIntFromObj' logger.cpp:(.text+0x11c1): undefined reference to
Tcl_GetIntFromObj'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function odb::Logger::initLogger(Tcl_Interp*)': logger.cpp:(.text+0x124a): undefined reference to
Tcl_CreateObjCommand'
logger.cpp:(.text+0x126f): undefined reference to Tcl_CreateObjCommand' logger.cpp:(.text+0x1294): undefined reference to
Tcl_CreateObjCommand'
logger.cpp:(.text+0x12b9): undefined reference to Tcl_CreateObjCommand' logger.cpp:(.text+0x12e2): undefined reference to
Tcl_CreateObjCommand'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o):logger.cpp:(.text+0x130b): more undefined references to Tcl_CreateObjCommand' follow /home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function
odb::idle(int)':
logger.cpp:(.text+0x14c0): undefined reference to odb::ZInterface::idle(int)' /home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function
odb::debug(char const*, char const*, char const*, ...)':
logger.cpp:(.text+0x1916): undefined reference to odb::ZInterface::notice(int, char const*, ...)' /home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function
odb::milos(int, char const*, ...)':
logger.cpp:(.text+0x1ceb): undefined reference to odb::ZInterface::event(char const*, char const*, char const*, ...)' /home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function
odb::ade(int, char const*, ...)':
logger.cpp:(.text+0x1e6b): undefined reference to odb::ZInterface::event(char const*, char const*, char const*, ...)' /home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function
odb::notice(int, char const*, ...)':
logger.cpp:(.text+0x2000): undefined reference to odb::ZInterface::event(char const*, char const*, char const*, ...)' /home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function
odb::verbose(int, char const*, ...)':
logger.cpp:(.text+0x21ad): undefined reference to odb::ZInterface::event(char const*, char const*, char const*, ...)' /home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function
odb::info(int, char const*, ...)':
logger.cpp:(.text+0x2365): undefined reference to odb::ZInterface::event(char const*, char const*, char const*, ...)' /home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o):logger.cpp:(.text+0x251d): more undefined references to
odb::ZInterface::event(char const*, char const*, char const*, ...)' follow
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function odb::Logger::Logger(Tcl_Interp*)': logger.cpp:(.text._ZN3odb6LoggerC2EP10Tcl_Interp[_ZN3odb6LoggerC5EP10Tcl_Interp]+0x18): undefined reference to
odb::ZInterface::ZInterface()'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o): In function odb::Logger::~Logger()': logger.cpp:(.text._ZN3odb6LoggerD2Ev[_ZN3odb6LoggerD5Ev]+0x26): undefined reference to
odb::ZInterface::~ZInterface()'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(logger.cpp.o):(.data.rel.ro._ZTIN3odb6LoggerE[_ZTIN3odb6LoggerE]+0x10): undefined reference to typeinfo for odb::ZInterface' /home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(dbBlock.cpp.o): In function
odb::dbBlock::findSomeMaster(char const*, std::vector<odb::dbMaster*, std::allocatorodb::dbMaster* >&)':
dbBlock.cpp:(.text+0x9928): undefined reference to Ath__parser::Ath__parser()' dbBlock.cpp:(.text+0x9944): undefined reference to
Ath__parser::mkWords(char const*, char*)'
dbBlock.cpp:(.text+0x9957): undefined reference to Ath__parser::getWordCnt()' dbBlock.cpp:(.text+0x9972): undefined reference to
Ath__parser::get(int)'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(dbBlock.cpp.o): In function odb::dbBlock::findSomeNet(char const*, std::vector<odb::dbNet*, std::allocator<odb::dbNet*> >&)': dbBlock.cpp:(.text+0x9a77): undefined reference to
Ath__parser::Ath__parser()'
dbBlock.cpp:(.text+0x9a93): undefined reference to Ath__parser::mkWords(char const*, char*)' dbBlock.cpp:(.text+0x9aa6): undefined reference to
Ath__parser::getWordCnt()'
dbBlock.cpp:(.text+0x9ac5): undefined reference to Ath__parser::get(int)' /home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(dbBlock.cpp.o): In function
odb::dbBlock::findSomeInst(char const*, std::vector<odb::dbInst*, std::allocatorodb::dbInst* >&)':
dbBlock.cpp:(.text+0x9c19): undefined reference to Ath__parser::Ath__parser()' dbBlock.cpp:(.text+0x9c35): undefined reference to
Ath__parser::mkWords(char const*, char*)'
dbBlock.cpp:(.text+0x9c48): undefined reference to Ath__parser::getWordCnt()' dbBlock.cpp:(.text+0x9c67): undefined reference to
Ath__parser::get(int)'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(dbBlock.cpp.o): In function odb::dbBlock::saveLef(char*)': dbBlock.cpp:(.text+0xeaf8): undefined reference to
odb::lefout::writeTechAndLib(odb::dbLib*, char const*)'
/home/muktadir/cse220/OpenDB/build/src/db/libopendb.a(dbBlock.cpp.o): In function odb::dbBlock::saveDef(char*, char*)': dbBlock.cpp:(.text+0xebbb): undefined reference to
odb::defout::defout()'
dbBlock.cpp:(.text+0xec07): undefined reference to odb::defout::selectNet(odb::dbNet*)' dbBlock.cpp:(.text+0xec24): undefined reference to
odb::defout::writeBlock(odb::dbBlock*, char const*)'
dbBlock.cpp:(.text+0xec54): undefined reference to odb::defout::~defout()' dbBlock.cpp:(.text+0xec81): undefined reference to
odb::defout::~defout()'
collect2: error: ld returned 1 exit status
Makefile:7: recipe for target 'app' failed
make: *** [app] Error 1
I've needed to comment out this test addition because it uses an issue on non-standard installs with TCL. But since this is a test, shouldn't this directory only be included when compiling for debugging?
Line 36 in c095760
Thanks,
Peter
There are some properties stored in the DEF that I need to get access to from the TCL interface, but it's unclear how I would go about accessing them.
% dbProperty_getProperties
Wrong number of arguments :dbProperty_getProperties object argument 1
% dbProperty_getProperties $block
TypeError in method 'dbProperty_getProperties', argument 1 of type 'dbObject *'
% dbProperty_getProperties $db
TypeError in method 'dbProperty_getProperties', argument 1 of type 'dbObject *'
Is there some additional SWIG support required for properties?
I have "Red Hat Enterprise Linux Server release 6.9" - in order to make the build process work I need to add the line
add_link_options(-lrt)
into the CMakeLists.txt file. Tested this out on UCSD machines, and the build is still successful with that setting. Please can this option be added into the CMakeLists.txt file.
Recently, a spdlog library was added:
Line 54 in 0c53d7f
OpenDB/include/opendb/Logger.h
Lines 34 to 36 in 0c53d7f
Please let me know if you need more information.
Thanks,
Sheiny
Hi I'm tring to read the spacing table of a layer in LEF. The table is a 2d table with indices of width and length.
I can use the getV55SpacingTable() to read the entries of the table. But how do I read the index array of width and length?
I can only use the getMaxWideDRCRange() and getMinWideDRCRange() to get the max and min of width and length, but how about the values in the middle?
On CentOS 6 the default version of swig is 1.3.40 but OpenDB fails to build. I was able to get it working by updating to a new version of swig (I used 2.0.8).
Please bump the minimum version of swig required in the CMakeLists.txt
I observe the following error using SWIG Version 1.3.40
[ 98%] Building CXX object src/swig/tcl/CMakeFiles/opendbtcl.dir/opendb_wrap.cpp.o
/net/trenton/x/ajayi/projects/OpenROAD/ux/OpenDB/build/src/swig/tcl/opendb_wrap.cpp: In function \u2018int _wrap_dbWireGraph_createVia__SWIG_0(ClientData, Tcl_Interp*, int, Tcl_Obj* const*)\u2019:
/net/trenton/x/ajayi/projects/OpenROAD/ux/OpenDB/build/src/swig/tcl/opendb_wrap.cpp:69089:3: error: \u2018Via\u2019 was not declared in this scope
Via *result = 0 ;
^
/net/trenton/x/ajayi/projects/OpenROAD/ux/OpenDB/build/src/swig/tcl/opendb_wrap.cpp:69089:8: error: \u2018result\u2019 was not declared in this scope
Via *result = 0 ;
^
/net/trenton/x/ajayi/projects/OpenROAD/ux/OpenDB/build/src/swig/tcl/opendb_wrap.cpp:69128:18: error: expected primary-expression before \u2018)\u2019 token
result = (Via *)(arg1)->createVia(arg2,arg3,arg4,arg5,arg6);
https://github.com/The-OpenROAD-Project/OpenDB/blob/master/src/swig/tcl/CMakeLists.txt#L20
Please use the library returned by FindTCL.cmake
I've found out that the following nangate45 cases show this problem:
filler_source_test.tar.gz
commit: 5fc66c3
I only used odb_read_lef, odb_read_def and odb_write_def, but the generated DEF doesn't have "+ SOURCE DIST" statements.
This caused a failure to OpenDP JenkinsCI testcases on the integrated top-level repo.
Could you check this problem?
I can create a net using dbCreateNet e.g.
set net [dbCreateNet $block "VDD"]
Normally I use $net getSWires to examine the set of wire segments for this net, but how do I add a wire segment to the net?
The code:
set db [dbDatabase_create]
dbChip_create $db
does not create a chip
object, returning NULL instead.
A chip object needs to be passed to dbBlock_create to allow a block
object to be created
The project currently degined in the CMakeLists.txt includes a "DESCRIPTION" parameter. (https://github.com/The-OpenROAD-Project/OpenDB/blob/master/CMakeLists.txt#L14)
The DESCRIPTION parameters was added in CMake 3.8, and so this is breaks compilation on platforms with CMake <= 3.8
Either remove this parameter or bump minimum cmake version required to 3.8
The specific error using cmake 3.3.2 is as follows
$ cmake ..
CMake Error: Could not find cmake module file: CMakeDetermineDESCRIPTIONCompiler.cmake
CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.
Missing variable is:
CMAKE_DESCRIPTION_COMPILER_ENV_VAR
CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.
Missing variable is:
CMAKE_DESCRIPTION_COMPILER
CMake Error: Could not find cmake module file: /net/trenton/x/ajayi/projects/OpenROAD/ux/OpenDB/build/CMakeFiles/3.3.2/CMakeDESCRIPTIONCompiler.cmake
CMake Error: Could not find cmake module file: CMakeDetermineDatabase and Tool Framework for EDACompiler.cmake
CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.
Missing variable is:
CMAKE_Database and Tool Framework for EDA_COMPILER_ENV_VAR
CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.
Missing variable is:
CMAKE_Database and Tool Framework for EDA_COMPILER
CMake Error: Could not find cmake module file: /net/trenton/x/ajayi/projects/OpenROAD/ux/OpenDB/build/CMakeFiles/3.3.2/CMakeDatabase and Tool Framework for EDACompiler.cmake
CMake Error at CMakeLists.txt:13 (project):
No CMAKE_DESCRIPTION_COMPILER could be found.
Tell CMake where to find the compiler by setting the CMake cache entry
CMAKE_DESCRIPTION_COMPILER to the full path to the compiler, or to the
compiler name if it is in the PATH.
CMake Error: Could not find cmake module file: CMakeDESCRIPTIONInformation.cmake
CMake Error at CMakeLists.txt:13 (project):
No CMAKE_Database and Tool Framework for EDA_COMPILER could be found.
Tell CMake where to find the compiler by setting the CMake cache entry
CMAKE_Database and Tool Framework for EDA_COMPILER to the full path to the
compiler, or to the compiler name if it is in the PATH.
CMake Error: Could not find cmake module file: CMakeDatabase and Tool Framework for EDAInformation.cmake
CMake Error: CMAKE_DESCRIPTION_COMPILER not set, after EnableLanguage
CMake Error: CMAKE_Database and Tool Framework for EDA_COMPILER not set, after EnableLanguage
-- Configuring incomplete, errors occurred!
See also "/net/trenton/x/ajayi/projects/OpenROAD/ux/OpenDB/build/CMakeFiles/CMakeOutput.log".
If I try to set the version of DEF to be writteon out, I get:
ERROR: set defout version: Command {$def_writer setVersion DEF_5_6}
TypeError in method 'defout_setVersion', argument 2 of type 'odb::defout::Version'
I've updated one of the tests to include this check
07-write_def_test.tcl.gz
The header of the def is:
% more ./OpenDB/build/test.def
VERSION 5.3 ;
NAMESCASESENSITIVE ON ;
DIVIDERCHAR "/" ;
BUSBITCHARS "[]" ;
DESIGN counter ;
UNITS DISTANCE MICRONS 1000 ;
the VERSION value is hardcoded in the defout code. (The version in the incoming DEF is 5.7, so unless otherwise modified by the user, this should be the default value used for the def out version as well)
The command to create a row seems to be of the form:
dbRow_create block name site origin_x origin_y orient direction num_sites spacing
e.g.
dbRow_create $block abc $site 0 0 N horizontal 400 480
TypeError in method 'dbRow_create', argument 6 of type 'dbOrientType'
How do I create a dbOrientType to use for this - shouldn't the wrapper convert a string argument for me?
The test creates some rows with various settings for direction and orientation. Examining the row settings immediately aferwards shows that the values are incorrect.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.