296 lines
10 KiB
Prolog
296 lines
10 KiB
Prolog
TARGET = DRAMSys
|
|
|
|
TEMPLATE = lib
|
|
CONFIG += staticlib
|
|
CONFIG += console
|
|
CONFIG -= app_bundle
|
|
CONFIG -= qt
|
|
|
|
system(cd ../../DRAMSys/library/src/common/third_party/DRAMPower; make src/libdrampower.a;)
|
|
|
|
systemc_home = $$(SYSTEMC_HOME)
|
|
isEmpty(systemc_home) {
|
|
systemc_home = /opt/systemc
|
|
}
|
|
|
|
# Check if PCT's SystemC should be used?
|
|
dramsys_pct = $$(DRAMSYS_PCT)
|
|
isEmpty(dramsys_pct) {
|
|
dramsys_pct = false
|
|
}
|
|
|
|
$$eval(dramsys_pct) {
|
|
# PCT:
|
|
message(PCT Simulation Feature Enabled)
|
|
systemc_home = /software/Synopsys_CoWare/K-2015.12-SP1/SLS/linux/common
|
|
INCLUDEPATH += $${systemc_home}/include/tlm
|
|
|
|
DEFINES += DRAMSYS_PCT
|
|
}
|
|
|
|
# Check if gem5 should be used
|
|
gem5 = $$(GEM5)
|
|
isEmpty(gem5) {
|
|
message(GEM5 environment variable not found)
|
|
message(Gem5 Simulation Disabled)
|
|
} else {
|
|
message(Gem5 Simulation Feature Enabled)
|
|
message(Gem5 home is $${gem5})
|
|
DEFINES += DRAMSYS_GEM5
|
|
}
|
|
|
|
message(SystemC home is $${systemc_home})
|
|
|
|
systemc_target_arch = $$(SYSTEMC_TARGET_ARCH)
|
|
isEmpty(systemc_target_arch) {
|
|
systemc_target_arch = linux64
|
|
}
|
|
message(SystemC target architecture is $${systemc_target_arch})
|
|
|
|
INCLUDEPATH += $${systemc_home}/include
|
|
|
|
INCLUDEPATH += src/common/third_party/DRAMPower/src
|
|
INCLUDEPATH += src/common/third_party/DRAMPower/src/libdrampower
|
|
INCLUDEPATH += src/common/third_party/json/include
|
|
|
|
DEFINES += TIXML_USE_STL
|
|
DEFINES += SC_INCLUDE_DYNAMIC_PROCESSES
|
|
|
|
dramsys_disable_coverage_check = $$(DRAMSYS_DISABLE_COVERAGE_CHECK)
|
|
isEmpty(dramsys_disable_coverage_check) {
|
|
coverage_check = true
|
|
message(Coverage check ENABLED)
|
|
} else {
|
|
coverage_check = false
|
|
message(Coverage check DISABLED)
|
|
}
|
|
|
|
unix:!macx {
|
|
QMAKE_CXXFLAGS += -std=c++11 -O0 -g
|
|
$$eval(coverage_check) {
|
|
QMAKE_CXXFLAGS += -fprofile-arcs -ftest-coverage -fPIC -O0
|
|
QMAKE_LFLAGS += -lgcov --coverage
|
|
}
|
|
}
|
|
|
|
macx: {
|
|
CONFIG += c++11
|
|
QMAKE_CXXFLAGS += -std=c++0x -stdlib=libc++ -O0 -g
|
|
$$eval(coverage_check) {
|
|
QMAKE_CXXFLAGS += --coverage
|
|
QMAKE_LFLAGS += --coverage
|
|
}
|
|
}
|
|
|
|
QMAKE_CXXFLAGS += -isystem $${systemc_home}/include
|
|
|
|
SOURCES += \
|
|
src/common/third_party/tinyxml2/tinyxml2.cpp \
|
|
src/common/TlmRecorder.cpp \
|
|
src/common/DebugManager.cpp \
|
|
src/controller/core/configuration/Configuration.cpp \
|
|
src/controller/core/powerdown/PowerDownManagerTimeout.cpp \
|
|
src/controller/core/powerdown/PowerDownManagerBankwise.cpp \
|
|
src/controller/core/powerdown/PowerDownManager.cpp \
|
|
src/controller/scheduler/FrFcfs.cpp \
|
|
src/controller/scheduler/Fifo.cpp \
|
|
src/controller/scheduler/SMS.cpp \
|
|
src/controller/core/refresh/RefreshManagerBankwise.cpp \
|
|
src/controller/core/refresh/RefreshManager.cpp \
|
|
src/controller/core/refresh/RGR.cpp \
|
|
src/controller/core/scheduling/checker/WriteChecker.cpp \
|
|
src/controller/core/scheduling/checker/RefreshChecker.cpp \
|
|
src/controller/core/scheduling/checker/ReadChecker.cpp \
|
|
src/controller/core/scheduling/checker/PrechargeChecker.cpp \
|
|
src/controller/core/scheduling/checker/PrechargeAllChecker.cpp \
|
|
src/controller/core/scheduling/checker/PowerDownChecker.cpp \
|
|
src/controller/core/scheduling/checker/ActivateChecker.cpp \
|
|
src/controller/core/scheduling/checker/PreBChecker.cpp \
|
|
src/controller/core/scheduling/checker/ActBChecker.cpp \
|
|
src/controller/core/scheduling/ScheduledCommand.cpp \
|
|
src/controller/core/Slots.cpp \
|
|
src/controller/core/ControllerCore.cpp \
|
|
src/simulation/MemoryManager.cpp \
|
|
src/simulation/TemperatureController.cpp \
|
|
src/controller/core/configuration/ConfigurationLoader.cpp \
|
|
src/controller/core/powerdown/NoPowerDown.cpp \
|
|
src/controller/Command.cpp \
|
|
src/controller/ControllerState.cpp \
|
|
src/controller/RowBufferStates.cpp \
|
|
src/controller/scheduler/IScheduler.cpp \
|
|
src/controller/scheduler/FifoStrict.cpp \
|
|
src/error/errormodel.cpp \
|
|
src/controller/Controller.cpp \
|
|
src/simulation/TracePlayer.cpp \
|
|
src/controller/core/powerdown/PowerDownManagerTimeoutBankwise.cpp \
|
|
src/simulation/TraceSetup.cpp \
|
|
src/simulation/DRAMSys.cpp \
|
|
src/simulation/Setup.cpp \
|
|
src/error/ECC/Bit.cpp \
|
|
src/error/ECC/ECC.cpp \
|
|
src/error/ECC/Word.cpp \
|
|
src/error/eccbaseclass.cpp \
|
|
src/error/ecchamming.cpp \
|
|
src/controller/scheduler/FrFcfsRp.cpp \
|
|
src/controller/scheduler/FrFcfsGrp.cpp \
|
|
src/controller/scheduler/Grp.cpp \
|
|
src/controller/RecordableController.cpp \
|
|
src/common/AddressDecoder.cpp \
|
|
src/simulation/Dram.cpp \
|
|
src/simulation/Arbiter.cpp \
|
|
src/common/CongenAddressDecoder.cpp \
|
|
src/common/XmlAddressDecoder.cpp \
|
|
src/controller/core/timingCalculations.cpp \
|
|
src/common/dramExtensions.cpp \
|
|
src/common/utils.cpp \
|
|
src/simulation/DramDDR3.cpp \
|
|
src/simulation/DramDDR4.cpp \
|
|
src/simulation/DramRecordable.cpp \
|
|
src/simulation/DramWideIO.cpp \
|
|
src/controller/core/configuration/MemSpec.cpp \
|
|
src/controller/core/scheduling/checker/CheckerDDR3New.cpp \
|
|
src/controller/BankMachine.cpp \
|
|
src/controller/ControllerNew.cpp \
|
|
src/controller/scheduler/SchedulerFifo.cpp \
|
|
src/controller/scheduler/SchedulerFrFcfs.cpp \
|
|
src/controller/cmdmux/CmdMuxStrict.cpp \
|
|
src/controller/cmdmux/CmdMuxOldest.cpp \
|
|
src/controller/ControllerRecordable.cpp \
|
|
src/controller/checker/CheckerDDR3.cpp
|
|
|
|
HEADERS += \
|
|
src/common/third_party/tinyxml2/tinyxml2.h \
|
|
src/common/TlmRecorder.h \
|
|
src/common/tlm2_base_protocol_checker.h \
|
|
src/common/protocol.h \
|
|
src/common/DebugManager.h \
|
|
src/controller/core/configuration/Configuration.h \
|
|
src/controller/core/powerdown/PowerDownManagerTimeout.h \
|
|
src/controller/core/powerdown/PowerDownManagerBankwise.h \
|
|
src/controller/core/powerdown/PowerDownManager.h \
|
|
src/controller/scheduler/FrFcfs.h \
|
|
src/controller/scheduler/Fifo.h \
|
|
src/controller/scheduler/SMS.h \
|
|
src/controller/Controller.h \
|
|
src/controller/core/refresh/RefreshManagerBankwise.h \
|
|
src/controller/core/refresh/RefreshManager.h \
|
|
src/controller/core/refresh/IRefreshManager.h \
|
|
src/controller/core/refresh/RGR.h \
|
|
src/controller/core/scheduling/checker/WriteChecker.h \
|
|
src/controller/core/scheduling/checker/RefreshChecker.h \
|
|
src/controller/core/scheduling/checker/ReadChecker.h \
|
|
src/controller/core/scheduling/checker/PrechargeChecker.h \
|
|
src/controller/core/scheduling/checker/PrechargeAllChecker.h \
|
|
src/controller/core/scheduling/checker/PowerDownChecker.h \
|
|
src/controller/core/scheduling/checker/ICommandChecker.h \
|
|
src/controller/core/scheduling/checker/ActivateChecker.h \
|
|
src/controller/core/scheduling/checker/PreBChecker.h \
|
|
src/controller/core/scheduling/checker/ActBChecker.h \
|
|
src/controller/core/scheduling/ScheduledCommand.h \
|
|
src/controller/core/Slots.h \
|
|
src/controller/core/ControllerCore.h \
|
|
src/simulation/TracePlayer.h \
|
|
src/simulation/MemoryManager.h \
|
|
src/simulation/Dram.h \
|
|
src/simulation/Arbiter.h \
|
|
src/common/libDRAMPower.h \
|
|
src/simulation/ReorderBuffer.h \
|
|
src/controller/core/configuration/MemSpec.h \
|
|
src/simulation/StlPlayer.h \
|
|
src/simulation/TracePlayerListener.h \
|
|
src/simulation/TraceGenerator.h \
|
|
src/simulation/TemperatureController.h \
|
|
src/controller/core/powerdown/NoPowerDown.h \
|
|
src/controller/Command.h \
|
|
src/controller/RowBufferStates.h \
|
|
src/controller/ControllerState.h \
|
|
src/controller/core/powerdown/IPowerDownManager.h \
|
|
src/controller/scheduler/IScheduler.h \
|
|
src/controller/scheduler/FifoStrict.h \
|
|
src/controller/IController.h \
|
|
src/controller/core/configuration/ConfigurationLoader.h \
|
|
src/error/errormodel.h \
|
|
src/simulation/ExampleInitiator.h \
|
|
src/controller/core/powerdown/PowerDownManagerTimeoutBankwise.h \
|
|
src/simulation/TraceSetup.h \
|
|
src/simulation/DRAMSys.h \
|
|
src/simulation/Setup.h \
|
|
src/error/ECC/Bit.h \
|
|
src/error/ECC/ECC.h \
|
|
src/error/ECC/Word.h \
|
|
src/error/eccbaseclass.h \
|
|
src/error/ecchamming.h \
|
|
src/controller/scheduler/FrFcfsRp.h \
|
|
src/controller/scheduler/FrFcfsGrp.h \
|
|
src/controller/scheduler/Grp.h \
|
|
src/simulation/IArbiter.h \
|
|
src/simulation/SimpleArbiter.h \
|
|
src/controller/RecordableController.h \
|
|
src/common/AddressDecoder.h \
|
|
src/common/CongenAddressDecoder.h \
|
|
src/common/XmlAddressDecoder.h \
|
|
src/controller/core/timingCalculations.h \
|
|
src/common/dramExtensions.h \
|
|
src/common/utils.h \
|
|
src/controller/core/configuration/TemperatureSimConfig.h \
|
|
src/simulation/DramDDR3.h \
|
|
src/simulation/DramDDR4.h \
|
|
src/simulation/DramRecordable.h \
|
|
src/simulation/DramWideIO.h \
|
|
src/controller/GenericController.h \
|
|
src/controller/core/scheduling/checker/CheckerDDR3New.h \
|
|
src/controller/BankMachine.h \
|
|
src/controller/ControllerNew.h \
|
|
src/controller/scheduler/SchedulerIF.h \
|
|
src/controller/scheduler/SchedulerFifo.h \
|
|
src/controller/scheduler/SchedulerFrFcfs.h \
|
|
src/controller/cmdmux/CmdMuxIF.h \
|
|
src/controller/cmdmux/CmdMuxStrict.h \
|
|
src/controller/cmdmux/CmdMuxOldest.h \
|
|
src/controller/ControllerRecordable.h \
|
|
src/controller/checker/CheckerIF.h \
|
|
src/controller/checker/CheckerDDR3.h
|
|
#src/common/third_party/json/include/nlohmann/json.hpp \
|
|
|
|
thermalsim = $$(THERMALSIM)
|
|
isEmpty(thermalsim) {
|
|
thermalsim = false
|
|
}
|
|
|
|
$$eval(thermalsim) {
|
|
message(Thermal Simulation Feature Enabled)
|
|
|
|
libthreed_ice_home = $$(LIBTHREED_ICE_HOME)
|
|
isEmpty(libthreed_ice_home) {
|
|
libthreed_ice_home = /opt/3D-ICE/
|
|
}
|
|
message(LIBTHREED_ICE_HOME path is $${libthreed_ice_home})
|
|
|
|
libsuperlu_home = $$(LIBSUPERLU_HOME)
|
|
isEmpty(libsuperlu_home) {
|
|
libsuperlu_home = /opt/SuperLU_4.3/
|
|
}
|
|
message(LIBSUPERLU_HOME path is $${libthreed_ice_home})
|
|
|
|
LIBS += -L$${libthreed_ice_home}/lib -lthreed-ice-2.2.4
|
|
LIBS += -L$${libsuperlu_home}/lib -lsuperlu_4.3
|
|
LIBS += -lblas
|
|
message(Libraries: $${LIBS})
|
|
|
|
INCLUDEPATH += $${libthreed_ice_home}/include
|
|
INCLUDEPATH += $${libsuperlu_home}/SRC
|
|
INCLUDEPATH += $${systemc_home}/include
|
|
message(Include paths: $${INCLUDEPATH})
|
|
|
|
QMAKE_CXXFLAGS += -DTHERMALSIM
|
|
message(Compiler flags: $${QMAKE_CXXFLAGS})
|
|
|
|
} else {
|
|
message(Thermal Simulation Feature Disabled)
|
|
}
|
|
|
|
# Additional Files:
|
|
include(resources/resources.pri)
|
|
|
|
DISTFILES += ../DRAMSys.astylerc
|