Make dataLength parameter required for initiators
This commit is contained in:
@@ -9,6 +9,7 @@
|
|||||||
{
|
{
|
||||||
"type": "player",
|
"type": "player",
|
||||||
"clkMhz": 800,
|
"clkMhz": 800,
|
||||||
|
"dataLength": 64,
|
||||||
"name": "traces/example.stl"
|
"name": "traces/example.stl"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -9,6 +9,7 @@
|
|||||||
{
|
{
|
||||||
"type": "player",
|
"type": "player",
|
||||||
"clkMhz": 200,
|
"clkMhz": 200,
|
||||||
|
"dataLength": 64,
|
||||||
"name": "traces/example.stl"
|
"name": "traces/example.stl"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -212,6 +212,7 @@
|
|||||||
{
|
{
|
||||||
"type": "player",
|
"type": "player",
|
||||||
"clkMhz": 200,
|
"clkMhz": 200,
|
||||||
|
"dataLength": 64,
|
||||||
"name": "traces/example.stl"
|
"name": "traces/example.stl"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -9,6 +9,7 @@
|
|||||||
{
|
{
|
||||||
"type": "player",
|
"type": "player",
|
||||||
"clkMhz": 1000,
|
"clkMhz": 1000,
|
||||||
|
"dataLength": 32,
|
||||||
"name": "traces/example.stl"
|
"name": "traces/example.stl"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -9,6 +9,7 @@
|
|||||||
{
|
{
|
||||||
"type": "player",
|
"type": "player",
|
||||||
"clkMhz": 200,
|
"clkMhz": 200,
|
||||||
|
"dataLength": 32,
|
||||||
"name": "traces/example.stl"
|
"name": "traces/example.stl"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -9,6 +9,7 @@
|
|||||||
{
|
{
|
||||||
"type": "player",
|
"type": "player",
|
||||||
"clkMhz": 800,
|
"clkMhz": 800,
|
||||||
|
"dataLength": 64,
|
||||||
"name": "traces/example.stl"
|
"name": "traces/example.stl"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -9,6 +9,7 @@
|
|||||||
{
|
{
|
||||||
"type": "player",
|
"type": "player",
|
||||||
"clkMhz": 2000,
|
"clkMhz": 2000,
|
||||||
|
"dataLength": 64,
|
||||||
"name": "../../configs/traces/example.stl"
|
"name": "../../configs/traces/example.stl"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -8,6 +8,7 @@
|
|||||||
"tracesetup": [
|
"tracesetup": [
|
||||||
{
|
{
|
||||||
"clkMhz": 2000,
|
"clkMhz": 2000,
|
||||||
|
"dataLength": 64,
|
||||||
"type": "generator",
|
"type": "generator",
|
||||||
"name": "gen0",
|
"name": "gen0",
|
||||||
"numRequests": 2000,
|
"numRequests": 2000,
|
||||||
@@ -19,6 +20,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"clkMhz": 2000,
|
"clkMhz": 2000,
|
||||||
|
"dataLength": 64,
|
||||||
"type": "generator",
|
"type": "generator",
|
||||||
"name": "gen1",
|
"name": "gen1",
|
||||||
"numRequests": 2000,
|
"numRequests": 2000,
|
||||||
|
|||||||
@@ -8,6 +8,7 @@
|
|||||||
"tracesetup": [
|
"tracesetup": [
|
||||||
{
|
{
|
||||||
"clkMhz": 2000,
|
"clkMhz": 2000,
|
||||||
|
"dataLength": 32,
|
||||||
"type": "generator",
|
"type": "generator",
|
||||||
"name": "gen0",
|
"name": "gen0",
|
||||||
"numRequests": 2000,
|
"numRequests": 2000,
|
||||||
|
|||||||
@@ -9,6 +9,7 @@
|
|||||||
{
|
{
|
||||||
"type": "player",
|
"type": "player",
|
||||||
"clkMhz": 200,
|
"clkMhz": 200,
|
||||||
|
"dataLength": 32,
|
||||||
"name": "../../configs/traces/example.stl"
|
"name": "../../configs/traces/example.stl"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -79,12 +79,13 @@ struct TracePlayer
|
|||||||
|
|
||||||
uint64_t clkMhz{};
|
uint64_t clkMhz{};
|
||||||
std::string name;
|
std::string name;
|
||||||
|
unsigned dataLength;
|
||||||
std::optional<unsigned int> maxPendingReadRequests;
|
std::optional<unsigned int> maxPendingReadRequests;
|
||||||
std::optional<unsigned int> maxPendingWriteRequests;
|
std::optional<unsigned int> maxPendingWriteRequests;
|
||||||
};
|
};
|
||||||
|
|
||||||
NLOHMANN_JSONIFY_ALL_THINGS(
|
NLOHMANN_JSONIFY_ALL_THINGS(
|
||||||
TracePlayer, clkMhz, name, maxPendingReadRequests, maxPendingWriteRequests)
|
TracePlayer, clkMhz, name, dataLength, maxPendingReadRequests, maxPendingWriteRequests)
|
||||||
|
|
||||||
struct TrafficGeneratorActiveState
|
struct TrafficGeneratorActiveState
|
||||||
{
|
{
|
||||||
@@ -136,7 +137,7 @@ struct TrafficGenerator
|
|||||||
|
|
||||||
std::optional<uint64_t> seed;
|
std::optional<uint64_t> seed;
|
||||||
std::optional<uint64_t> maxTransactions;
|
std::optional<uint64_t> maxTransactions;
|
||||||
std::optional<unsigned> dataLength;
|
unsigned dataLength;
|
||||||
std::optional<unsigned> dataAlignment;
|
std::optional<unsigned> dataAlignment;
|
||||||
|
|
||||||
uint64_t numRequests{};
|
uint64_t numRequests{};
|
||||||
@@ -174,7 +175,7 @@ struct TrafficGeneratorStateMachine
|
|||||||
|
|
||||||
std::optional<uint64_t> seed;
|
std::optional<uint64_t> seed;
|
||||||
std::optional<uint64_t> maxTransactions;
|
std::optional<uint64_t> maxTransactions;
|
||||||
std::optional<unsigned> dataLength;
|
unsigned dataLength;
|
||||||
std::optional<unsigned> dataAlignment;
|
std::optional<unsigned> dataAlignment;
|
||||||
std::vector<std::variant<TrafficGeneratorActiveState, TrafficGeneratorIdleState>> states;
|
std::vector<std::variant<TrafficGeneratorActiveState, TrafficGeneratorIdleState>> states;
|
||||||
std::vector<TrafficGeneratorStateTransition> transitions;
|
std::vector<TrafficGeneratorStateTransition> transitions;
|
||||||
@@ -200,7 +201,8 @@ struct RowHammer
|
|||||||
std::string name;
|
std::string name;
|
||||||
std::optional<unsigned int> maxPendingReadRequests;
|
std::optional<unsigned int> maxPendingReadRequests;
|
||||||
std::optional<unsigned int> maxPendingWriteRequests;
|
std::optional<unsigned int> maxPendingWriteRequests;
|
||||||
|
|
||||||
|
unsigned dataLength;
|
||||||
uint64_t numRequests{};
|
uint64_t numRequests{};
|
||||||
uint64_t rowIncrement{};
|
uint64_t rowIncrement{};
|
||||||
};
|
};
|
||||||
@@ -210,6 +212,7 @@ NLOHMANN_JSONIFY_ALL_THINGS(RowHammer,
|
|||||||
name,
|
name,
|
||||||
maxPendingReadRequests,
|
maxPendingReadRequests,
|
||||||
maxPendingWriteRequests,
|
maxPendingWriteRequests,
|
||||||
|
dataLength,
|
||||||
numRequests,
|
numRequests,
|
||||||
rowIncrement)
|
rowIncrement)
|
||||||
|
|
||||||
|
|||||||
@@ -85,7 +85,6 @@ Simulator::instantiateInitiator(const DRAMSys::Config::Initiator& initiator)
|
|||||||
{
|
{
|
||||||
uint64_t memorySize = dramSys->getMemSpec().getSimMemSizeInBytes();
|
uint64_t memorySize = dramSys->getMemSpec().getSimMemSizeInBytes();
|
||||||
sc_core::sc_time interfaceClk = dramSys->getMemSpec().tCK;
|
sc_core::sc_time interfaceClk = dramSys->getMemSpec().tCK;
|
||||||
unsigned int defaultDataLength = dramSys->getMemSpec().defaultBytesPerBurst;
|
|
||||||
|
|
||||||
return std::visit(
|
return std::visit(
|
||||||
[=](auto&& config) -> std::unique_ptr<RequestIssuer>
|
[=](auto&& config) -> std::unique_ptr<RequestIssuer>
|
||||||
@@ -94,8 +93,7 @@ Simulator::instantiateInitiator(const DRAMSys::Config::Initiator& initiator)
|
|||||||
if constexpr (std::is_same_v<T, DRAMSys::Config::TrafficGenerator> ||
|
if constexpr (std::is_same_v<T, DRAMSys::Config::TrafficGenerator> ||
|
||||||
std::is_same_v<T, DRAMSys::Config::TrafficGeneratorStateMachine>)
|
std::is_same_v<T, DRAMSys::Config::TrafficGeneratorStateMachine>)
|
||||||
{
|
{
|
||||||
auto generator =
|
auto generator = std::make_unique<TrafficGenerator>(config, memorySize);
|
||||||
std::make_unique<TrafficGenerator>(config, memorySize, defaultDataLength);
|
|
||||||
|
|
||||||
return std::make_unique<RequestIssuer>(config.name.c_str(),
|
return std::make_unique<RequestIssuer>(config.name.c_str(),
|
||||||
std::move(generator),
|
std::move(generator),
|
||||||
@@ -124,11 +122,8 @@ Simulator::instantiateInitiator(const DRAMSys::Config::Initiator& initiator)
|
|||||||
SC_REPORT_FATAL("Simulator", report.c_str());
|
SC_REPORT_FATAL("Simulator", report.c_str());
|
||||||
}
|
}
|
||||||
|
|
||||||
auto player = std::make_unique<StlPlayer>(tracePath.c_str(),
|
auto player = std::make_unique<StlPlayer>(
|
||||||
config.clkMhz,
|
config, tracePath.c_str(), *traceType, storageEnabled);
|
||||||
defaultDataLength,
|
|
||||||
*traceType,
|
|
||||||
storageEnabled);
|
|
||||||
|
|
||||||
return std::make_unique<RequestIssuer>(config.name.c_str(),
|
return std::make_unique<RequestIssuer>(config.name.c_str(),
|
||||||
std::move(player),
|
std::move(player),
|
||||||
@@ -141,7 +136,7 @@ Simulator::instantiateInitiator(const DRAMSys::Config::Initiator& initiator)
|
|||||||
}
|
}
|
||||||
else if constexpr (std::is_same_v<T, DRAMSys::Config::RowHammer>)
|
else if constexpr (std::is_same_v<T, DRAMSys::Config::RowHammer>)
|
||||||
{
|
{
|
||||||
auto hammer = std::make_unique<RowHammer>(config, defaultDataLength);
|
auto hammer = std::make_unique<RowHammer>(config);
|
||||||
|
|
||||||
return std::make_unique<RequestIssuer>(config.name.c_str(),
|
return std::make_unique<RequestIssuer>(config.name.c_str(),
|
||||||
std::move(hammer),
|
std::move(hammer),
|
||||||
|
|||||||
@@ -39,12 +39,11 @@
|
|||||||
#include "SequentialState.h"
|
#include "SequentialState.h"
|
||||||
|
|
||||||
TrafficGenerator::TrafficGenerator(DRAMSys::Config::TrafficGeneratorStateMachine const& config,
|
TrafficGenerator::TrafficGenerator(DRAMSys::Config::TrafficGeneratorStateMachine const& config,
|
||||||
uint64_t memorySize,
|
uint64_t memorySize) :
|
||||||
unsigned int defaultDataLength) :
|
|
||||||
stateTransistions(config.transitions),
|
stateTransistions(config.transitions),
|
||||||
generatorPeriod(sc_core::sc_time(1.0 / static_cast<double>(config.clkMhz), sc_core::SC_US))
|
generatorPeriod(sc_core::sc_time(1.0 / static_cast<double>(config.clkMhz), sc_core::SC_US))
|
||||||
{
|
{
|
||||||
unsigned int dataLength = config.dataLength.value_or(defaultDataLength);
|
unsigned int dataLength = config.dataLength;
|
||||||
unsigned int dataAlignment = config.dataAlignment.value_or(dataLength);
|
unsigned int dataAlignment = config.dataAlignment.value_or(dataLength);
|
||||||
|
|
||||||
for (auto const& state : config.states)
|
for (auto const& state : config.states)
|
||||||
@@ -62,13 +61,13 @@ TrafficGenerator::TrafficGenerator(DRAMSys::Config::TrafficGeneratorStateMachine
|
|||||||
DRAMSys::Config::AddressDistribution::Random)
|
DRAMSys::Config::AddressDistribution::Random)
|
||||||
{
|
{
|
||||||
auto producer = std::make_unique<RandomState>(activeState.numRequests,
|
auto producer = std::make_unique<RandomState>(activeState.numRequests,
|
||||||
config.seed.value_or(0),
|
config.seed.value_or(0),
|
||||||
activeState.rwRatio,
|
activeState.rwRatio,
|
||||||
activeState.minAddress,
|
activeState.minAddress,
|
||||||
activeState.maxAddress,
|
activeState.maxAddress,
|
||||||
memorySize,
|
memorySize,
|
||||||
dataLength,
|
dataLength,
|
||||||
dataAlignment);
|
dataAlignment);
|
||||||
|
|
||||||
producers.emplace(activeState.id, std::move(producer));
|
producers.emplace(activeState.id, std::move(producer));
|
||||||
}
|
}
|
||||||
@@ -76,13 +75,13 @@ TrafficGenerator::TrafficGenerator(DRAMSys::Config::TrafficGeneratorStateMachine
|
|||||||
{
|
{
|
||||||
auto producer =
|
auto producer =
|
||||||
std::make_unique<SequentialState>(activeState.numRequests,
|
std::make_unique<SequentialState>(activeState.numRequests,
|
||||||
config.seed.value_or(0),
|
config.seed.value_or(0),
|
||||||
activeState.rwRatio,
|
activeState.rwRatio,
|
||||||
activeState.addressIncrement,
|
activeState.addressIncrement,
|
||||||
activeState.minAddress,
|
activeState.minAddress,
|
||||||
activeState.maxAddress,
|
activeState.maxAddress,
|
||||||
memorySize,
|
memorySize,
|
||||||
dataLength);
|
dataLength);
|
||||||
|
|
||||||
producers.emplace(activeState.id, std::move(producer));
|
producers.emplace(activeState.id, std::move(producer));
|
||||||
}
|
}
|
||||||
@@ -98,35 +97,34 @@ TrafficGenerator::TrafficGenerator(DRAMSys::Config::TrafficGeneratorStateMachine
|
|||||||
}
|
}
|
||||||
|
|
||||||
TrafficGenerator::TrafficGenerator(DRAMSys::Config::TrafficGenerator const& config,
|
TrafficGenerator::TrafficGenerator(DRAMSys::Config::TrafficGenerator const& config,
|
||||||
uint64_t memorySize,
|
uint64_t memorySize) :
|
||||||
unsigned int defaultDataLength) :
|
|
||||||
generatorPeriod(sc_core::sc_time(1.0 / static_cast<double>(config.clkMhz), sc_core::SC_US))
|
generatorPeriod(sc_core::sc_time(1.0 / static_cast<double>(config.clkMhz), sc_core::SC_US))
|
||||||
{
|
{
|
||||||
unsigned int dataLength = config.dataLength.value_or(defaultDataLength);
|
unsigned int dataLength = config.dataLength;
|
||||||
unsigned int dataAlignment = config.dataAlignment.value_or(dataLength);
|
unsigned int dataAlignment = config.dataAlignment.value_or(dataLength);
|
||||||
|
|
||||||
if (config.addressDistribution == DRAMSys::Config::AddressDistribution::Random)
|
if (config.addressDistribution == DRAMSys::Config::AddressDistribution::Random)
|
||||||
{
|
{
|
||||||
auto producer = std::make_unique<RandomState>(config.numRequests,
|
auto producer = std::make_unique<RandomState>(config.numRequests,
|
||||||
config.seed.value_or(0),
|
config.seed.value_or(0),
|
||||||
config.rwRatio,
|
config.rwRatio,
|
||||||
config.minAddress,
|
config.minAddress,
|
||||||
config.maxAddress,
|
config.maxAddress,
|
||||||
memorySize,
|
memorySize,
|
||||||
dataLength,
|
dataLength,
|
||||||
dataAlignment);
|
dataAlignment);
|
||||||
producers.emplace(0, std::move(producer));
|
producers.emplace(0, std::move(producer));
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
auto producer = std::make_unique<SequentialState>(config.numRequests,
|
auto producer = std::make_unique<SequentialState>(config.numRequests,
|
||||||
config.seed.value_or(0),
|
config.seed.value_or(0),
|
||||||
config.rwRatio,
|
config.rwRatio,
|
||||||
config.addressIncrement,
|
config.addressIncrement,
|
||||||
config.minAddress,
|
config.minAddress,
|
||||||
config.maxAddress,
|
config.maxAddress,
|
||||||
memorySize,
|
memorySize,
|
||||||
dataLength);
|
dataLength);
|
||||||
producers.emplace(0, std::move(producer));
|
producers.emplace(0, std::move(producer));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -47,13 +47,10 @@ class RequestProducer;
|
|||||||
class TrafficGenerator : public RequestProducer
|
class TrafficGenerator : public RequestProducer
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
TrafficGenerator(DRAMSys::Config::TrafficGenerator const& config,
|
TrafficGenerator(DRAMSys::Config::TrafficGenerator const& config, uint64_t memorySize);
|
||||||
uint64_t memorySize,
|
|
||||||
unsigned int defaultDataLength);
|
|
||||||
|
|
||||||
TrafficGenerator(DRAMSys::Config::TrafficGeneratorStateMachine const& config,
|
TrafficGenerator(DRAMSys::Config::TrafficGeneratorStateMachine const& config,
|
||||||
uint64_t memorySize,
|
uint64_t memorySize);
|
||||||
unsigned int defaultDataLength);
|
|
||||||
|
|
||||||
uint64_t totalRequests() override;
|
uint64_t totalRequests() override;
|
||||||
Request nextRequest() override;
|
Request nextRequest() override;
|
||||||
|
|||||||
@@ -35,11 +35,11 @@
|
|||||||
|
|
||||||
#include "RowHammer.h"
|
#include "RowHammer.h"
|
||||||
|
|
||||||
RowHammer::RowHammer(DRAMSys::Config::RowHammer const& config, unsigned int dataLength) :
|
RowHammer::RowHammer(DRAMSys::Config::RowHammer const& config) :
|
||||||
generatorPeriod(sc_core::sc_time(1.0 / static_cast<double>(config.clkMhz), sc_core::SC_US)),
|
generatorPeriod(sc_core::sc_time(1.0 / static_cast<double>(config.clkMhz), sc_core::SC_US)),
|
||||||
numberOfRequests(config.numRequests),
|
numberOfRequests(config.numRequests),
|
||||||
rowIncrement(config.rowIncrement),
|
rowIncrement(config.rowIncrement),
|
||||||
dataLength(dataLength)
|
dataLength(config.dataLength)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -44,7 +44,7 @@
|
|||||||
class RowHammer : public RequestProducer
|
class RowHammer : public RequestProducer
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
RowHammer(DRAMSys::Config::RowHammer const& config, unsigned int dataLength);
|
RowHammer(DRAMSys::Config::RowHammer const& config);
|
||||||
|
|
||||||
Request nextRequest() override;
|
Request nextRequest() override;
|
||||||
sc_core::sc_time nextTrigger() override { return generatorPeriod; }
|
sc_core::sc_time nextTrigger() override { return generatorPeriod; }
|
||||||
|
|||||||
@@ -44,15 +44,14 @@
|
|||||||
|
|
||||||
static constexpr std::size_t LINE_BUFFER_SIZE = 10000;
|
static constexpr std::size_t LINE_BUFFER_SIZE = 10000;
|
||||||
|
|
||||||
StlPlayer::StlPlayer(std::filesystem::path const& trace,
|
StlPlayer::StlPlayer(DRAMSys::Config::TracePlayer const& config,
|
||||||
unsigned int clkMhz,
|
std::filesystem::path const& trace,
|
||||||
unsigned int defaultDataLength,
|
|
||||||
TraceType traceType,
|
TraceType traceType,
|
||||||
bool storageEnabled) :
|
bool storageEnabled) :
|
||||||
traceType(traceType),
|
traceType(traceType),
|
||||||
storageEnabled(storageEnabled),
|
storageEnabled(storageEnabled),
|
||||||
playerPeriod(sc_core::sc_time(1.0 / static_cast<double>(clkMhz), sc_core::SC_US)),
|
playerPeriod(sc_core::sc_time(1.0 / static_cast<double>(config.clkMhz), sc_core::SC_US)),
|
||||||
defaultDataLength(defaultDataLength),
|
defaultDataLength(config.dataLength),
|
||||||
traceFile(trace)
|
traceFile(trace)
|
||||||
{
|
{
|
||||||
if (!traceFile.is_open())
|
if (!traceFile.is_open())
|
||||||
|
|||||||
@@ -42,6 +42,8 @@
|
|||||||
|
|
||||||
#include "simulator/request/RequestProducer.h"
|
#include "simulator/request/RequestProducer.h"
|
||||||
|
|
||||||
|
#include <DRAMSys/config/TraceSetup.h>
|
||||||
|
|
||||||
#include <systemc>
|
#include <systemc>
|
||||||
#include <tlm>
|
#include <tlm>
|
||||||
|
|
||||||
@@ -61,9 +63,8 @@ public:
|
|||||||
Relative,
|
Relative,
|
||||||
};
|
};
|
||||||
|
|
||||||
StlPlayer(std::filesystem::path const& trace,
|
StlPlayer(DRAMSys::Config::TracePlayer const& config,
|
||||||
unsigned int clkMhz,
|
std::filesystem::path const& trace,
|
||||||
unsigned int defaultDataLength,
|
|
||||||
TraceType traceType,
|
TraceType traceType,
|
||||||
bool storageEnabled);
|
bool storageEnabled);
|
||||||
|
|
||||||
|
|||||||
@@ -215,6 +215,7 @@
|
|||||||
{
|
{
|
||||||
"type": "player",
|
"type": "player",
|
||||||
"clkMhz": 100,
|
"clkMhz": 100,
|
||||||
|
"dataLength": 64,
|
||||||
"name": "mytrace.stl"
|
"name": "mytrace.stl"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -222,12 +223,14 @@
|
|||||||
"addressDistribution": "random",
|
"addressDistribution": "random",
|
||||||
"clkMhz": 100,
|
"clkMhz": 100,
|
||||||
"name": "MyTestGen",
|
"name": "MyTestGen",
|
||||||
|
"dataLength": 64,
|
||||||
"numRequests": 1000,
|
"numRequests": 1000,
|
||||||
"rwRatio": 0.5
|
"rwRatio": 0.5
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"type": "statemachine",
|
"type": "statemachine",
|
||||||
"clkMhz": 100,
|
"clkMhz": 100,
|
||||||
|
"dataLength": 64,
|
||||||
"maxPendingReadRequests": 8,
|
"maxPendingReadRequests": 8,
|
||||||
"name": "MyTestGen",
|
"name": "MyTestGen",
|
||||||
"states": [
|
"states": [
|
||||||
@@ -260,6 +263,7 @@
|
|||||||
{
|
{
|
||||||
"type": "rowhammer",
|
"type": "rowhammer",
|
||||||
"clkMhz": 100,
|
"clkMhz": 100,
|
||||||
|
"dataLength": 64,
|
||||||
"name": "MyTestHammer",
|
"name": "MyTestHammer",
|
||||||
"numRequests": 4000,
|
"numRequests": 4000,
|
||||||
"rowIncrement": 2097152
|
"rowIncrement": 2097152
|
||||||
|
|||||||
@@ -318,6 +318,7 @@ DRAMSys::Config::TracePlayer ConfigurationTest::createTracePlayer()
|
|||||||
{
|
{
|
||||||
DRAMSys::Config::TracePlayer player;
|
DRAMSys::Config::TracePlayer player;
|
||||||
player.clkMhz = 100;
|
player.clkMhz = 100;
|
||||||
|
player.dataLength = 64;
|
||||||
player.name = "mytrace.stl";
|
player.name = "mytrace.stl";
|
||||||
|
|
||||||
return player;
|
return player;
|
||||||
@@ -327,6 +328,7 @@ DRAMSys::Config::TrafficGenerator ConfigurationTest::createTraceGeneratorOneStat
|
|||||||
{
|
{
|
||||||
DRAMSys::Config::TrafficGenerator gen;
|
DRAMSys::Config::TrafficGenerator gen;
|
||||||
gen.clkMhz = 100;
|
gen.clkMhz = 100;
|
||||||
|
gen.dataLength = 64;
|
||||||
gen.name = "MyTestGen";
|
gen.name = "MyTestGen";
|
||||||
|
|
||||||
gen.numRequests = 1000;
|
gen.numRequests = 1000;
|
||||||
@@ -345,6 +347,7 @@ ConfigurationTest::createTraceGeneratorMultipleStates()
|
|||||||
DRAMSys::Config::TrafficGeneratorStateMachine gen;
|
DRAMSys::Config::TrafficGeneratorStateMachine gen;
|
||||||
|
|
||||||
gen.clkMhz = 100;
|
gen.clkMhz = 100;
|
||||||
|
gen.dataLength = 64;
|
||||||
gen.name = "MyTestGen";
|
gen.name = "MyTestGen";
|
||||||
gen.maxPendingReadRequests = 8;
|
gen.maxPendingReadRequests = 8;
|
||||||
|
|
||||||
@@ -381,6 +384,7 @@ DRAMSys::Config::RowHammer ConfigurationTest::createTraceHammer()
|
|||||||
DRAMSys::Config::RowHammer hammer;
|
DRAMSys::Config::RowHammer hammer;
|
||||||
|
|
||||||
hammer.clkMhz = 100;
|
hammer.clkMhz = 100;
|
||||||
|
hammer.dataLength = 64;
|
||||||
hammer.name = "MyTestHammer";
|
hammer.name = "MyTestHammer";
|
||||||
hammer.numRequests = 4000;
|
hammer.numRequests = 4000;
|
||||||
hammer.rowIncrement = 2097152;
|
hammer.rowIncrement = 2097152;
|
||||||
@@ -720,12 +724,14 @@ TEST_F(ConfigurationTest, TraceSetup)
|
|||||||
{
|
{
|
||||||
"type": "player",
|
"type": "player",
|
||||||
"clkMhz": 100,
|
"clkMhz": 100,
|
||||||
|
"dataLength": 64,
|
||||||
"name": "mytrace.stl"
|
"name": "mytrace.stl"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"type": "generator",
|
"type": "generator",
|
||||||
"addressDistribution": "random",
|
"addressDistribution": "random",
|
||||||
"clkMhz": 100,
|
"clkMhz": 100,
|
||||||
|
"dataLength": 64,
|
||||||
"name": "MyTestGen",
|
"name": "MyTestGen",
|
||||||
"numRequests": 1000,
|
"numRequests": 1000,
|
||||||
"rwRatio": 0.5
|
"rwRatio": 0.5
|
||||||
@@ -733,6 +739,7 @@ TEST_F(ConfigurationTest, TraceSetup)
|
|||||||
{
|
{
|
||||||
"type": "statemachine",
|
"type": "statemachine",
|
||||||
"clkMhz": 100,
|
"clkMhz": 100,
|
||||||
|
"dataLength": 64,
|
||||||
"maxPendingReadRequests": 8,
|
"maxPendingReadRequests": 8,
|
||||||
"name": "MyTestGen",
|
"name": "MyTestGen",
|
||||||
"states": [
|
"states": [
|
||||||
@@ -765,6 +772,7 @@ TEST_F(ConfigurationTest, TraceSetup)
|
|||||||
{
|
{
|
||||||
"type": "rowhammer",
|
"type": "rowhammer",
|
||||||
"clkMhz": 100,
|
"clkMhz": 100,
|
||||||
|
"dataLength": 64,
|
||||||
"name": "MyTestHammer",
|
"name": "MyTestHammer",
|
||||||
"numRequests": 4000,
|
"numRequests": 4000,
|
||||||
"rowIncrement": 2097152
|
"rowIncrement": 2097152
|
||||||
|
|||||||
@@ -137,6 +137,7 @@
|
|||||||
{
|
{
|
||||||
"type": "player",
|
"type": "player",
|
||||||
"clkMhz": 533,
|
"clkMhz": 533,
|
||||||
|
"dataLength": 64,
|
||||||
"name": "traces/trace_test2.stl"
|
"name": "traces/trace_test2.stl"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -213,6 +213,7 @@
|
|||||||
{
|
{
|
||||||
"type": "player",
|
"type": "player",
|
||||||
"clkMhz": 933,
|
"clkMhz": 933,
|
||||||
|
"dataLength": 64,
|
||||||
"name": "traces/trace_test3.stl"
|
"name": "traces/trace_test3.stl"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -220,6 +220,7 @@
|
|||||||
{
|
{
|
||||||
"type": "player",
|
"type": "player",
|
||||||
"clkMhz": 1600,
|
"clkMhz": 1600,
|
||||||
|
"dataLength": 64,
|
||||||
"name": "traces/trace_test3.stl"
|
"name": "traces/trace_test3.stl"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -128,11 +128,13 @@
|
|||||||
{
|
{
|
||||||
"type": "player",
|
"type": "player",
|
||||||
"clkMhz": 1000,
|
"clkMhz": 1000,
|
||||||
|
"dataLength": 64,
|
||||||
"name": "traces/trace1_test4.stl"
|
"name": "traces/trace1_test4.stl"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"type": "player",
|
"type": "player",
|
||||||
"clkMhz": 1000,
|
"clkMhz": 1000,
|
||||||
|
"dataLength": 64,
|
||||||
"name": "traces/trace2_test4.stl"
|
"name": "traces/trace2_test4.stl"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -131,11 +131,13 @@
|
|||||||
{
|
{
|
||||||
"type": "player",
|
"type": "player",
|
||||||
"clkMhz": 1600,
|
"clkMhz": 1600,
|
||||||
|
"dataLength": 32,
|
||||||
"name": "traces/trace1_test4.stl"
|
"name": "traces/trace1_test4.stl"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"type": "player",
|
"type": "player",
|
||||||
"clkMhz": 1600,
|
"clkMhz": 1600,
|
||||||
|
"dataLength": 32,
|
||||||
"name": "traces/trace2_test4.stl"
|
"name": "traces/trace2_test4.stl"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -183,6 +183,7 @@
|
|||||||
{
|
{
|
||||||
"type": "player",
|
"type": "player",
|
||||||
"clkMhz": 1600,
|
"clkMhz": 1600,
|
||||||
|
"dataLength": 32,
|
||||||
"name": "traces/trace_lpddr4.stl"
|
"name": "traces/trace_lpddr4.stl"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -205,6 +205,7 @@
|
|||||||
{
|
{
|
||||||
"type": "player",
|
"type": "player",
|
||||||
"clkMhz": 1600,
|
"clkMhz": 1600,
|
||||||
|
"dataLength": 32,
|
||||||
"name": "traces/trace_lpddr5.stl"
|
"name": "traces/trace_lpddr5.stl"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
Reference in New Issue
Block a user