Skip to content

Commit f745f67

Browse files
authored
Merge pull request #9096 from The-OpenROAD-Project-staging/odb-naming
Odb naming
2 parents b583811 + 022b25d commit f745f67

File tree

128 files changed

+741
-643
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

128 files changed

+741
-643
lines changed

src/odb/src/codeGenerator/gen.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -202,7 +202,7 @@ def add_field_attributes(field, klass, flags_struct, schema):
202202

203203
# For fields that we need to free/destroy in the destructor
204204
if (
205-
field["name"] == "_name"
205+
field["name"] == "name_"
206206
and "no-destruct" not in field["flags"]
207207
or "table" in field
208208
):

src/odb/src/codeGenerator/schema.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -455,7 +455,7 @@
455455
"parent":"dbDatabase",
456456
"child":"dbProperty",
457457
"type":"1_n",
458-
"tbl_name":"_prop_tbl",
458+
"tbl_name":"prop_tbl_",
459459
"flags": ["no-serial"]
460460
},
461461
{

src/odb/src/codeGenerator/schema/tech/dbCellEdgeSpacing.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"fields": [
55
{
66
"type": "bit",
7-
"name": "except_abutted_"
7+
"name": "except_abutted"
88
},
99
{
1010
"type": "bit",

src/odb/src/codeGenerator/templates/impl.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ namespace odb {
146146

147147
{% for field in klass.fields %}
148148
{% if field.table %}
149-
{{field.name}}->collectMemInfo(info.children_["{{field.name}}"]);
149+
{{field.name}}->collectMemInfo(info.children["{{field.name}}"]);
150150
{% endif %}
151151
{% endfor %}
152152

src/odb/src/db/dbAccessPoint.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -140,12 +140,12 @@ void _dbAccessPoint::collectMemInfo(MemInfo& info)
140140
info.size += sizeof(*this);
141141

142142
// User Code Begin collectMemInfo
143-
info.children_["iterms"].add(iterms_);
144-
MemInfo& via_info = info.children_["vias"];
143+
info.children["iterms"].add(iterms_);
144+
MemInfo& via_info = info.children["vias"];
145145
for (const auto& v : vias_) {
146146
via_info.add(v);
147147
}
148-
info.children_["path_segs"].add(path_segs_);
148+
info.children["path_segs"].add(path_segs_);
149149
// User Code End collectMemInfo
150150
}
151151

src/odb/src/db/dbBPin.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -284,7 +284,7 @@ void _dbBPin::collectMemInfo(MemInfo& info)
284284
info.cnt++;
285285
info.size += sizeof(*this);
286286

287-
info.children_["ap"].add(aps_);
287+
info.children["ap"].add(aps_);
288288
}
289289

290290
void _dbBPin::removeBox(_dbBox* box)

src/odb/src/db/dbBTerm.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -924,7 +924,7 @@ void _dbBTerm::collectMemInfo(MemInfo& info)
924924
info.cnt++;
925925
info.size += sizeof(*this);
926926

927-
info.children_["name"].add(name_);
927+
info.children["name"].add(name_);
928928
}
929929

930930
dbSet<dbBTerm>::iterator dbBTerm::destroy(dbSet<dbBTerm>::iterator& itr)

src/odb/src/db/dbBlock.cpp

Lines changed: 79 additions & 79 deletions
Original file line numberDiff line numberDiff line change
@@ -137,20 +137,20 @@ namespace odb {
137137

138138
struct OldTransform
139139
{
140-
int _orient;
141-
int _originX;
142-
int _originY;
143-
int _sizeX;
144-
int _sizeY;
140+
int orient;
141+
int originX;
142+
int originY;
143+
int sizeX;
144+
int sizeY;
145145
};
146146

147147
dbIStream& operator>>(dbIStream& stream, OldTransform& t)
148148
{
149-
stream >> t._orient;
150-
stream >> t._originX;
151-
stream >> t._originY;
152-
stream >> t._sizeX;
153-
stream >> t._sizeY;
149+
stream >> t.orient;
150+
stream >> t.originX;
151+
stream >> t.originY;
152+
stream >> t.sizeX;
153+
stream >> t.sizeY;
154154
return stream;
155155
}
156156

@@ -3711,75 +3711,75 @@ void _dbBlock::collectMemInfo(MemInfo& info)
37113711
info.cnt++;
37123712
info.size += sizeof(*this);
37133713

3714-
info.children_["name"].add(name_);
3715-
info.children_["corner_name"].add(corner_name_list_);
3716-
info.children_["blocked_regions_for_pins"].add(blocked_regions_for_pins_);
3717-
3718-
info.children_["net_hash"].add(net_hash_);
3719-
info.children_["inst_hash"].add(inst_hash_);
3720-
info.children_["module_hash"].add(module_hash_);
3721-
info.children_["modinst_hash"].add(modinst_hash_);
3722-
info.children_["powerdomain_hash"].add(powerdomain_hash_);
3723-
info.children_["logicport_hash"].add(logicport_hash_);
3724-
info.children_["powerswitch_hash"].add(powerswitch_hash_);
3725-
info.children_["isolation_hash"].add(isolation_hash_);
3726-
info.children_["levelshifter_hash"].add(levelshifter_hash_);
3727-
info.children_["group_hash"].add(group_hash_);
3728-
info.children_["inst_hdr_hash"].add(inst_hdr_hash_);
3729-
info.children_["bterm_hash"].add(bterm_hash_);
3730-
3731-
info.children_["children"].add(children_);
3732-
info.children_["component_mask_shift"].add(component_mask_shift_);
3733-
3734-
bterm_tbl_->collectMemInfo(info.children_["bterm"]);
3735-
iterm_tbl_->collectMemInfo(info.children_["iterm"]);
3736-
net_tbl_->collectMemInfo(info.children_["net"]);
3737-
inst_hdr_tbl_->collectMemInfo(info.children_["inst_hdr"]);
3738-
inst_tbl_->collectMemInfo(info.children_["inst"]);
3739-
box_tbl_->collectMemInfo(info.children_["box"]);
3740-
via_tbl_->collectMemInfo(info.children_["via"]);
3741-
gcell_grid_tbl_->collectMemInfo(info.children_["gcell_grid"]);
3742-
track_grid_tbl_->collectMemInfo(info.children_["track_grid"]);
3743-
obstruction_tbl_->collectMemInfo(info.children_["obstruction"]);
3744-
blockage_tbl_->collectMemInfo(info.children_["blockage"]);
3745-
wire_tbl_->collectMemInfo(info.children_["wire"]);
3746-
swire_tbl_->collectMemInfo(info.children_["swire"]);
3747-
sbox_tbl_->collectMemInfo(info.children_["sbox"]);
3748-
row_tbl_->collectMemInfo(info.children_["row"]);
3749-
fill_tbl_->collectMemInfo(info.children_["fill"]);
3750-
region_tbl_->collectMemInfo(info.children_["region"]);
3751-
hier_tbl_->collectMemInfo(info.children_["hier"]);
3752-
bpin_tbl_->collectMemInfo(info.children_["bpin"]);
3753-
non_default_rule_tbl_->collectMemInfo(info.children_["non_default_rule"]);
3754-
layer_rule_tbl_->collectMemInfo(info.children_["layer_rule"]);
3755-
prop_tbl_->collectMemInfo(info.children_["prop"]);
3756-
module_tbl_->collectMemInfo(info.children_["module"]);
3757-
powerdomain_tbl_->collectMemInfo(info.children_["powerdomain"]);
3758-
logicport_tbl_->collectMemInfo(info.children_["logicport"]);
3759-
powerswitch_tbl_->collectMemInfo(info.children_["powerswitch"]);
3760-
isolation_tbl_->collectMemInfo(info.children_["isolation"]);
3761-
levelshifter_tbl_->collectMemInfo(info.children_["levelshifter"]);
3762-
modinst_tbl_->collectMemInfo(info.children_["modinst"]);
3763-
group_tbl_->collectMemInfo(info.children_["group"]);
3764-
ap_tbl_->collectMemInfo(info.children_["ap"]);
3765-
global_connect_tbl_->collectMemInfo(info.children_["global_connect"]);
3766-
guide_tbl_->collectMemInfo(info.children_["guide"]);
3767-
net_tracks_tbl_->collectMemInfo(info.children_["net_tracks"]);
3768-
dft_tbl_->collectMemInfo(info.children_["dft"]);
3769-
modbterm_tbl_->collectMemInfo(info.children_["modbterm"]);
3770-
moditerm_tbl_->collectMemInfo(info.children_["moditerm"]);
3771-
modnet_tbl_->collectMemInfo(info.children_["modnet"]);
3772-
busport_tbl_->collectMemInfo(info.children_["busport"]);
3773-
cap_node_tbl_->collectMemInfo(info.children_["cap_node"]);
3774-
r_seg_tbl_->collectMemInfo(info.children_["r_seg"]);
3775-
cc_seg_tbl_->collectMemInfo(info.children_["cc_seg"]);
3776-
3777-
name_cache_->collectMemInfo(info.children_["name_cache"]);
3778-
info.children_["r_val"].add(*r_val_tbl_);
3779-
info.children_["c_val"].add(*c_val_tbl_);
3780-
info.children_["cc_val"].add(*cc_val_tbl_);
3781-
3782-
info.children_["module_name_id_map"].add(module_name_id_map_);
3714+
info.children["name"].add(name_);
3715+
info.children["corner_name"].add(corner_name_list_);
3716+
info.children["blocked_regions_for_pins"].add(blocked_regions_for_pins_);
3717+
3718+
info.children["net_hash"].add(net_hash_);
3719+
info.children["inst_hash"].add(inst_hash_);
3720+
info.children["module_hash"].add(module_hash_);
3721+
info.children["modinst_hash"].add(modinst_hash_);
3722+
info.children["powerdomain_hash"].add(powerdomain_hash_);
3723+
info.children["logicport_hash"].add(logicport_hash_);
3724+
info.children["powerswitch_hash"].add(powerswitch_hash_);
3725+
info.children["isolation_hash"].add(isolation_hash_);
3726+
info.children["levelshifter_hash"].add(levelshifter_hash_);
3727+
info.children["group_hash"].add(group_hash_);
3728+
info.children["inst_hdr_hash"].add(inst_hdr_hash_);
3729+
info.children["bterm_hash"].add(bterm_hash_);
3730+
3731+
info.children["children"].add(children_);
3732+
info.children["component_mask_shift"].add(component_mask_shift_);
3733+
3734+
bterm_tbl_->collectMemInfo(info.children["bterm"]);
3735+
iterm_tbl_->collectMemInfo(info.children["iterm"]);
3736+
net_tbl_->collectMemInfo(info.children["net"]);
3737+
inst_hdr_tbl_->collectMemInfo(info.children["inst_hdr"]);
3738+
inst_tbl_->collectMemInfo(info.children["inst"]);
3739+
box_tbl_->collectMemInfo(info.children["box"]);
3740+
via_tbl_->collectMemInfo(info.children["via"]);
3741+
gcell_grid_tbl_->collectMemInfo(info.children["gcell_grid"]);
3742+
track_grid_tbl_->collectMemInfo(info.children["track_grid"]);
3743+
obstruction_tbl_->collectMemInfo(info.children["obstruction"]);
3744+
blockage_tbl_->collectMemInfo(info.children["blockage"]);
3745+
wire_tbl_->collectMemInfo(info.children["wire"]);
3746+
swire_tbl_->collectMemInfo(info.children["swire"]);
3747+
sbox_tbl_->collectMemInfo(info.children["sbox"]);
3748+
row_tbl_->collectMemInfo(info.children["row"]);
3749+
fill_tbl_->collectMemInfo(info.children["fill"]);
3750+
region_tbl_->collectMemInfo(info.children["region"]);
3751+
hier_tbl_->collectMemInfo(info.children["hier"]);
3752+
bpin_tbl_->collectMemInfo(info.children["bpin"]);
3753+
non_default_rule_tbl_->collectMemInfo(info.children["non_default_rule"]);
3754+
layer_rule_tbl_->collectMemInfo(info.children["layer_rule"]);
3755+
prop_tbl_->collectMemInfo(info.children["prop"]);
3756+
module_tbl_->collectMemInfo(info.children["module"]);
3757+
powerdomain_tbl_->collectMemInfo(info.children["powerdomain"]);
3758+
logicport_tbl_->collectMemInfo(info.children["logicport"]);
3759+
powerswitch_tbl_->collectMemInfo(info.children["powerswitch"]);
3760+
isolation_tbl_->collectMemInfo(info.children["isolation"]);
3761+
levelshifter_tbl_->collectMemInfo(info.children["levelshifter"]);
3762+
modinst_tbl_->collectMemInfo(info.children["modinst"]);
3763+
group_tbl_->collectMemInfo(info.children["group"]);
3764+
ap_tbl_->collectMemInfo(info.children["ap"]);
3765+
global_connect_tbl_->collectMemInfo(info.children["global_connect"]);
3766+
guide_tbl_->collectMemInfo(info.children["guide"]);
3767+
net_tracks_tbl_->collectMemInfo(info.children["net_tracks"]);
3768+
dft_tbl_->collectMemInfo(info.children["dft"]);
3769+
modbterm_tbl_->collectMemInfo(info.children["modbterm"]);
3770+
moditerm_tbl_->collectMemInfo(info.children["moditerm"]);
3771+
modnet_tbl_->collectMemInfo(info.children["modnet"]);
3772+
busport_tbl_->collectMemInfo(info.children["busport"]);
3773+
cap_node_tbl_->collectMemInfo(info.children["cap_node"]);
3774+
r_seg_tbl_->collectMemInfo(info.children["r_seg"]);
3775+
cc_seg_tbl_->collectMemInfo(info.children["cc_seg"]);
3776+
3777+
name_cache_->collectMemInfo(info.children["name_cache"]);
3778+
info.children["r_val"].add(*r_val_tbl_);
3779+
info.children["c_val"].add(*c_val_tbl_);
3780+
info.children["cc_val"].add(*cc_val_tbl_);
3781+
3782+
info.children["module_name_id_map"].add(module_name_id_map_);
37833783
}
37843784

37853785
void _dbBlock::ensureConstraintRegion(const Direction2D& edge,

src/odb/src/db/dbBox.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -950,8 +950,8 @@ dbBox* dbBox::create(dbTechVia* via_,
950950
}
951951

952952
// link box to via
953-
box->next_box_ = via->_boxes;
954-
via->_boxes = box->getOID();
953+
box->next_box_ = via->boxes_;
954+
via->boxes_ = box->getOID();
955955
return (dbBox*) box;
956956
}
957957

src/odb/src/db/dbBoxItr.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ void dbBoxItr<page_size>::reverse(dbObject* parent)
113113

114114
case dbTechViaObj: {
115115
_dbTechVia* via = (_dbTechVia*) parent;
116-
uint id = via->_boxes;
116+
uint id = via->boxes_;
117117
uint list = 0;
118118

119119
while (id != 0) {
@@ -124,7 +124,7 @@ void dbBoxItr<page_size>::reverse(dbObject* parent)
124124
id = n;
125125
}
126126

127-
via->_boxes = list;
127+
via->boxes_ = list;
128128
break;
129129
}
130130

@@ -237,7 +237,7 @@ uint dbBoxItr<page_size>::begin(dbObject* parent) const
237237

238238
case dbTechViaObj: {
239239
_dbTechVia* via = (_dbTechVia*) parent;
240-
return via->_boxes;
240+
return via->boxes_;
241241
}
242242

243243
case dbBPinObj: {

0 commit comments

Comments
 (0)