static const FlagsType UNCACHEABLE = 0x00001000;
/** This request is to a memory mapped register. */
static const FlagsType MMAPED_IPR = 0x00002000;
+ /** This request is a clear exclusive. */
+ static const FlagsType CLEAR_LL = 0x00004000;
- /** The request should ignore unaligned access faults */
- static const FlagsType NO_ALIGN_FAULT = 0x00020000;
- /** The request should ignore unaligned access faults */
- static const FlagsType NO_HALF_WORD_ALIGN_FAULT = 0x00040000;
/** The request should not cause a memory access. */
static const FlagsType NO_ACCESS = 0x00080000;
/** This request will lock or unlock the accessed memory. When used with
/**
* The time this request was started. Used to calculate
- * latencies. This field is set to curTick any time paddr or vaddr
+ * latencies. This field is set to curTick() any time paddr or vaddr
* is written.
*/
Tick _time;
/**
* Constructor for physical (e.g. device) requests. Initializes
- * just physical address, size, flags, and timestamp (to curTick).
+ * just physical address, size, flags, and timestamp (to curTick()).
* These fields are adequate to perform a request.
*/
Request(Addr paddr, int size, Flags flags)
setPhys(paddr, size, flags, time);
}
+ Request(Addr paddr, int size, Flags flags, Tick time, Addr pc)
+ {
+ setPhys(paddr, size, flags, time);
+ privateFlags.set(VALID_PC);
+ _pc = pc;
+ }
+
Request(int asid, Addr vaddr, int size, Flags flags, Addr pc,
int cid, ThreadID tid)
{
void
setPhys(Addr paddr, int size, Flags flags)
{
- setPhys(paddr, size, flags, curTick);
+ setPhys(paddr, size, flags, curTick());
}
/**
_vaddr = vaddr;
_size = size;
_pc = pc;
- _time = curTick;
+ _time = curTick();
_flags.clear(~STICKY_FLAGS);
_flags.set(flags);
bool isSwap() const { return _flags.isSet(MEM_SWAP|MEM_SWAP_COND); }
bool isCondSwap() const { return _flags.isSet(MEM_SWAP_COND); }
bool isMmapedIpr() const { return _flags.isSet(MMAPED_IPR); }
-
- bool
- isMisaligned() const
- {
- if (_flags.isSet(NO_ALIGN_FAULT))
- return false;
-
- if ((_vaddr & 0x1))
- return true;
-
- if (_flags.isSet(NO_HALF_WORD_ALIGN_FAULT))
- return false;
-
- if ((_vaddr & 0x2))
- return true;
-
- return false;
- }
+ bool isClearLL() const { return _flags.isSet(CLEAR_LL); }
};
#endif // __MEM_REQUEST_HH__