Skip to content

Commit d661e52

Browse files
committed
odb: Code clean-up
Signed-off-by: Jaehyun Kim <[email protected]>
1 parent 070165c commit d661e52

File tree

6 files changed

+0
-53
lines changed

6 files changed

+0
-53
lines changed

src/odb/src/db/dbBlock.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -950,7 +950,6 @@ dbIStream& operator>>(dbIStream& stream, _dbBlock& block)
950950
stream >> *block.inst_tbl_;
951951
stream >> *block.module_tbl_;
952952
}
953-
954953
if (db->isSchema(kSchemaDbRemoveHash)) {
955954
// Construct dbinst_hash_
956955
dbSet<dbInst> insts((dbBlock*) &block, block.inst_tbl_);

src/odb/src/db/dbInst.cpp

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -191,24 +191,6 @@ dbIStream& operator>>(dbIStream& stream, _dbInst& inst)
191191
stream >> inst.iterms_;
192192
stream >> inst.halo_;
193193
stream >> inst.pin_access_idx_;
194-
195-
dbDatabase* db = (dbDatabase*) (inst.getDatabase());
196-
if (((_dbDatabase*) db)->isSchema(kSchemaDbRemoveHash)) {
197-
// _dbBlock* block = (_dbBlock*) (db->getChip()->getBlock());
198-
// _dbModule* module = nullptr;
199-
// // if the instance has no module parent put in the top module
200-
// // We sometimes see instances with _module set to 0 (possibly
201-
// // introduced downstream) so we stick them in the hash for the
202-
// // top module.
203-
// if (inst.module_ == 0) {
204-
// module = (_dbModule*) (((dbBlock*) block)->getTopModule());
205-
// } else {
206-
// module = block->module_tbl_->getPtr(inst.module_);
207-
// }
208-
// if (inst.name_) {
209-
// module->dbinst_hash_[inst.name_] = dbId<_dbInst>(inst.getId());
210-
// }
211-
}
212194
return stream;
213195
}
214196

src/odb/src/db/dbModBTerm.cpp

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -107,16 +107,6 @@ dbIStream& operator>>(dbIStream& stream, _dbModBTerm& obj)
107107
if (obj.getDatabase()->isSchema(kSchemaHierPortRemoval)) {
108108
stream >> obj.prev_entry_;
109109
}
110-
// User Code Begin >>
111-
if (obj.getDatabase()->isSchema(kSchemaDbRemoveHash)) {
112-
// dbDatabase* db = (dbDatabase*) (obj.getDatabase());
113-
// _dbBlock* block = (_dbBlock*) (db->getChip()->getBlock());
114-
// _dbModule* module = block->module_tbl_->getPtr(obj.parent_);
115-
// if (obj.name_) {
116-
// module->modbterm_hash_[obj.name_] = obj.getId();
117-
// }
118-
}
119-
// User Code End >>
120110
return stream;
121111
}
122112

src/odb/src/db/dbModInst.cpp

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -106,14 +106,6 @@ dbIStream& operator>>(dbIStream& stream, _dbModInst& obj)
106106
if (db_->isSchema(kSchemaUpdateHierarchy)) {
107107
stream >> obj.moditerms_;
108108
}
109-
if (db_->isSchema(kSchemaDbRemoveHash)) {
110-
// _dbBlock* block = (_dbBlock*) (((dbDatabase*)
111-
// db_)->getChip()->getBlock()); _dbModule* module =
112-
// block->module_tbl_->getPtr(obj.parent_); if (obj.name_) {
113-
// module->modinst_hash_[obj.name_] = obj.getId();
114-
// }
115-
}
116-
// User Code End >>
117109
return stream;
118110
}
119111

src/odb/src/db/dbModNet.cpp

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -106,16 +106,6 @@ dbIStream& operator>>(dbIStream& stream, _dbModNet& obj)
106106
if (obj.getDatabase()->isSchema(kSchemaUpdateHierarchy)) {
107107
stream >> obj.bterms_;
108108
}
109-
// User Code Begin >>
110-
if (obj.getDatabase()->isSchema(kSchemaDbRemoveHash)) {
111-
// dbDatabase* db = (dbDatabase*) (obj.getDatabase());
112-
// _dbBlock* block = (_dbBlock*) (db->getChip()->getBlock());
113-
// _dbModule* module = block->module_tbl_->getPtr(obj.parent_);
114-
// if (obj.name_) {
115-
// module->modnet_hash_[obj.name_] = obj.getId();
116-
// }
117-
}
118-
// User Code End >>
119109
return stream;
120110
}
121111

src/rsz/src/ConcreteSwapArithModules.cc

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -261,11 +261,6 @@ bool ConcreteSwapArithModules::doSwapInstances(
261261
logger_->warn(RSZ, 158, "Module {} has no owner block", old_name);
262262
continue;
263263
}
264-
#include "db_sta/dbSta.hh"
265-
#include "odb/db.h"
266-
267-
// ...
268-
269264
dbModule* new_master = block->findModule(new_name.c_str());
270265
if (!new_master) {
271266
logger_->warn(
@@ -276,7 +271,6 @@ bool ConcreteSwapArithModules::doSwapInstances(
276271
inst->getName(),
277272
old_name,
278273
new_name);
279-
280274
inst->swapMaster(new_master);
281275
swapped_count++;
282276
}

0 commit comments

Comments
 (0)