Commit 200a8ba7 authored by Davide Pala's avatar Davide Pala
Browse files

Handle NONE memOpType case and const parameters

parent 0f19e191
Pipeline #247187 passed with stages
in 18 minutes and 43 seconds
...@@ -27,7 +27,7 @@ protected: ...@@ -27,7 +27,7 @@ protected:
bool wait; bool wait;
public: public:
virtual void process(ac_int<32, false> addr, memMask mask, memOpType opType, ac_int<INTERFACE_SIZE * 8, false> dataIn, virtual void process(const ac_int<32, false> addr, const memMask mask, const memOpType opType, const ac_int<INTERFACE_SIZE * 8, false> dataIn,
ac_int<INTERFACE_SIZE * 8, false>& dataOut, bool& waitOut) = 0; ac_int<INTERFACE_SIZE * 8, false>& dataOut, bool& waitOut) = 0;
}; };
...@@ -37,7 +37,7 @@ public: ...@@ -37,7 +37,7 @@ public:
public: public:
IncompleteMemory(ac_int<32, false>* arg) { data = arg; } IncompleteMemory(ac_int<32, false>* arg) { data = arg; }
void process(ac_int<32, false> addr, memMask mask, memOpType opType, ac_int<INTERFACE_SIZE * 8, false> dataIn, void process(const ac_int<32, false> addr, const memMask mask, const memOpType opType, const ac_int<INTERFACE_SIZE * 8, false> dataIn,
ac_int<INTERFACE_SIZE * 8, false>& dataOut, bool& waitOut) ac_int<INTERFACE_SIZE * 8, false>& dataOut, bool& waitOut)
{ {
// Incomplete memory only works for 32 bits // Incomplete memory only works for 32 bits
...@@ -58,7 +58,7 @@ public: ...@@ -58,7 +58,7 @@ public:
ac_int<32, false>* data; ac_int<32, false>* data;
SimpleMemory(ac_int<32, false>* arg) { data = arg; } SimpleMemory(ac_int<32, false>* arg) { data = arg; }
void process(ac_int<32, false> addr, memMask mask, memOpType opType, ac_int<INTERFACE_SIZE * 8, false> dataIn, void process(const ac_int<32, false> addr, const memMask mask, const memOpType opType, const ac_int<INTERFACE_SIZE * 8, false> dataIn,
ac_int<INTERFACE_SIZE * 8, false>& dataOut, bool& waitOut) ac_int<INTERFACE_SIZE * 8, false>& dataOut, bool& waitOut)
{ {
// no latency, wait is always set to false // no latency, wait is always set to false
...@@ -80,7 +80,6 @@ public: ...@@ -80,7 +80,6 @@ public:
case HALF_U: case HALF_U:
temp = data[addr >> 2]; temp = data[addr >> 2];
data[addr >> 2].set_slc(addr[1] ? 16 : 0, dataIn.template slc<16>(0)); data[addr >> 2].set_slc(addr[1] ? 16 : 0, dataIn.template slc<16>(0));
break; break;
case WORD: case WORD:
temp = data[addr >> 2]; temp = data[addr >> 2];
...@@ -120,7 +119,9 @@ public: ...@@ -120,7 +119,9 @@ public:
dataOut = data[addr >> 2].slc<16>(addr[1] ? 16 : 0) & 0xffff; dataOut = data[addr >> 2].slc<16>(addr[1] ? 16 : 0) & 0xffff;
break; break;
} }
break;
default: // case NONE
break; break;
} }
waitOut = false; waitOut = false;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment