Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
MiniEDA
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
MiniEDA
Commits
aff051ea
Commit
aff051ea
authored
Nov 21, 2022
by
lvzhengyang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add describe for db_mgr
parent
0c66a59f
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
70 additions
and
21 deletions
+70
-21
src/db_mgr/include/db_mgr/db_mgr.h
+67
-0
src/utl/include/utl/Logger.h
+3
-21
No files found.
src/db_mgr/include/db_mgr/db_mgr.h
0 → 100644
View file @
aff051ea
#pragma once
#ifndef _DB_MGR_H_
#define _DB_MGR_H_
#include <unordered_map>
#include <string>
namespace
odb
{
class
dbDatabase
;
}
// Logger symbol: MGR
namespace
utl
{
class
Logger
;
}
/* DB Manager: for hierarchical design. A hierarchical design
* contains multiple sub-block within the 'top' module. Because
* dbBlock class in OpenDB only supports two-levels of hierarchy,
* I choose to use a dbDatabase to represent a Block.
*
* NOTE: OpenDB claims that it supports that a dbDataBase can
* store multiple dbChip, but denote with "DEPRECATE".
*
* A hierarchical design:
* * ---------TOP--------- *
* | * ------- * ------- * |
* | | | | |
* | | Block A | Block B | |
* | | | | |
* | * ------- * ------- * |
* | | | | |
* | | Block C | Block D | |
* | | | | |
* | * ------- * ------- * |
* * --------------------- *
* Abutting Style: no spare cells amonng Blocks.
*/
class
DbMgr
{
public
:
DbMgr
();
void
deleteDbMgr
();
// dbDatadase::destroy()
bool
readLibDB
();
bool
readBlockDBs
();
bool
addBlockDB
();
bool
deleteBlockDB
();
bool
haveBlockDB
(
std
::
string
block
);
private
:
/* all Blocks share the same lib (.lef files)
* First, read the lib files into the lib_db_.
* Then, for each block, create a new db with copy of
* lib_db_, by `dbDatabase::duplicate(lib_db_)`
*/
odb
::
dbDatabase
*
lib_db_
;
/* use a STL Hash table to store Block DBs.
* use the block name as key.
* check if there exists duplicate name when inserting
* blocks.
*/
std
::
unordered_map
<
std
::
string
,
odb
::
dbDatabase
>
block_dbs_
;
};
#endif // _DB_MGR_H_
src/utl/include/utl/Logger.h
View file @
aff051ea
...
...
@@ -49,34 +49,16 @@
namespace
utl
{
#define FOREACH_TOOL(X) \
X(ANT) \
X(CTS) \
X(DPL) \
X(DPO) \
X(DRT) \
X(DST) \
X(FIN) \
X(FLW) \
X(EDA) \
X(ODB) \
X(MGR) \
X(GPL) \
X(GRT) \
X(GUI) \
X(PAD) \
X(IFP) \
X(MPL) \
X(ODB) \
X(EDA) \
X(PAR) \
X(PDN) \
X(PDR) \
X(PPL) \
X(PSM) \
X(PSN) \
X(RCX) \
X(RMP) \
X(RSZ) \
X(STA) \
X(STT) \
X(TAP) \
X(UKN) \
#define GENERATE_ENUM(ENUM) ENUM,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment