Skip to content

Commit

Permalink
PDNSim integration initial commit build passing
Browse files Browse the repository at this point in the history
  • Loading branch information
VidyaChhabria committed Feb 26, 2020
1 parent 002f8ce commit e2365f2
Show file tree
Hide file tree
Showing 6 changed files with 25 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,7 @@
[submodule "src/OpenRCX"]
path = src/OpenRCX
url = https://github.com/The-OpenROAD-Project/OpenRCX.git
[submodule "src/PDNSim"]
path = src/PDNSim
url = https://github.com/The-OpenROAD-Project/PDNSim.git
branch = openroad
6 changes: 6 additions & 0 deletions include/openroad/OpenRoad.hh
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,10 @@ namespace OpenRCX {
class Ext;
}

namespace pdnsim {
class PDNSim;
}

namespace ord {

using std::string;
Expand Down Expand Up @@ -91,6 +95,7 @@ public:
MacroPlace::TritonMacroPlace *getTritonMp() { return tritonMp_; }
OpenRCX::Ext *getOpenRCX() { return extractor_; }
replace::Replace* getReplace() { return replace_; }
pdnsim::PDNSim* getPDNSim() { return pdnsim_; }
// Return the bounding box of the db rows.
odb::adsRect getCore();
// Return true if the command units have been initialized.
Expand Down Expand Up @@ -130,6 +135,7 @@ private:
tapcell::Tapcell *tapcell_;
OpenRCX::Ext *extractor_;
replace::Replace *replace_;
pdnsim::PDNSim *pdnsim_;

// Singleton used by tcl command interpreter.
static OpenRoad *openroad_;
Expand Down
4 changes: 4 additions & 0 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ set(FASTROUTE_HOME ${PROJECT_SOURCE_DIR}/src/FastRoute)
set(TAPCELL_HOME ${OPENROAD_HOME}/src/tapcell)
set(OPENRCX_HOME ${OPENROAD_HOME}/src/OpenRCX)
set(MPLACE_HOME ${PROJECT_SOURCE_DIR}/src/TritonMacroPlace)
set(PDNSIM_HOME ${PROJECT_SOURCE_DIR}/src/PDNSim)

set(OPENROAD_TCL_INIT ${CMAKE_CURRENT_BINARY_DIR}/OpenRoadTclInitVar.cc)

Expand Down Expand Up @@ -210,6 +211,7 @@ add_subdirectory(FastRoute)
add_subdirectory(tapcell)
add_subdirectory(TritonMacroPlace)
add_subdirectory(OpenRCX)
add_subdirectory(PDNSim)

################################################################

Expand Down Expand Up @@ -238,6 +240,7 @@ target_include_directories(openroad
${PDNGEN_HOME}/include
${TAPCELL_HOME}/include
${OPENRCX_HOME}/include
${PDNSIM_HOME}/include
${TCL_INCLUDE_PATH}
${Boost_INCLUDE_DIRS}
)
Expand All @@ -261,6 +264,7 @@ target_link_libraries(openroad
TritonMacroPlace
ParquetFP
ABKCommon
pdnsim
zlib
tm
defin
Expand Down
3 changes: 3 additions & 0 deletions src/OpenRoad.cc
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
#include "TritonCTS/src/MakeTritoncts.h"
#include "tapcell/MakeTapcell.h"
#include "OpenRCX/MakeOpenRCX.h"
#include "pdnsim/MakePDNSim.hh"

namespace sta {
extern const char *openroad_tcl_inits[];
Expand Down Expand Up @@ -109,6 +110,7 @@ OpenRoad::init(Tcl_Interp *tcl_interp)
tritonMp_ = makeTritonMp();
extractor_ = makeOpenRCX();
replace_ = makeReplace();
pdnsim_ = makePDNSim();

// Init components.
Openroad_Init(tcl_interp);
Expand All @@ -129,6 +131,7 @@ OpenRoad::init(Tcl_Interp *tcl_interp)
initTapcell(this);
initTritonMp(this);
initOpenRCX(this);
initPDNSim(this);

// Import exported commands to global namespace.
Tcl_Eval(tcl_interp, "sta::define_sta_cmds");
Expand Down
7 changes: 7 additions & 0 deletions src/OpenRoad.i
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,13 @@ getOpenRCX()
return openroad->getOpenRCX();
}

pdnsim::PDNSim*
getPDNSim()
{
OpenRoad *openroad = getOpenRoad();
return openroad->getPDNSim();
}

} // namespace

using ord::OpenRoad;
Expand Down
1 change: 1 addition & 0 deletions src/PDNSim
Submodule PDNSim added at 0a68fd

0 comments on commit e2365f2

Please sign in to comment.