SMAUG
Simulating Machine Learning Applications on gem5-Aladdin
|
7 std::string traceName =
8 "dynamic_trace_acc" + std::to_string(accelIdx) +
".gz";
13 const char* arrayName,
17 mapArrayToAccelerator(reqCode, arrayName, baseAddr, size);
22 const char* arrayName,
25 setArrayMemoryType(reqCode, arrayName, memType);
37 size_t n = request / align;
40 size_t remainder = request % align;
42 return (n + 1) * align;
void setArrayMemTypeIfSimulating(unsigned reqCode, const char *arrayName, MemoryType memType)
Sets what memory access mechanism the accelerator will use when accessing this array.
bool runningInSimulation
This is true if the user chooses to run the network in gem5 simulation.
std::string getTraceName(int accelIdx)
Return the name of the dynamic trace for this accelerator.
The smaug namespace is the parent namespace of all C++ code in SMAUG.
Utilities for writing and invoking Aladdin kernels from Operators.
#define ALWAYS_INLINE
We have to disable all function inlining at the global level for Aladdin + LLVM-Tracer to work,...
size_t next_multiple(size_t request, size_t align)
Returns the smallest multiple of align that is >= request.
void mapArrayToAccel(unsigned reqCode, const char *arrayName, void *baseAddr, size_t size)
Maps an array of data to the accelerator.