gem5  v20.1.0.0
request.hh
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2012-2013,2017-2020 ARM Limited
3  * All rights reserved
4  *
5  * The license below extends only to copyright in the software and shall
6  * not be construed as granting a license to any other intellectual
7  * property including but not limited to intellectual property relating
8  * to a hardware implementation of the functionality of the software
9  * licensed hereunder. You may use the software subject to the license
10  * terms below provided that you ensure that this notice is replicated
11  * unmodified and in its entirety in all distributions of the software,
12  * modified or unmodified, in source code or in binary form.
13  *
14  * Copyright (c) 2002-2005 The Regents of The University of Michigan
15  * Copyright (c) 2010,2015 Advanced Micro Devices, Inc.
16  * All rights reserved.
17  *
18  * Redistribution and use in source and binary forms, with or without
19  * modification, are permitted provided that the following conditions are
20  * met: redistributions of source code must retain the above copyright
21  * notice, this list of conditions and the following disclaimer;
22  * redistributions in binary form must reproduce the above copyright
23  * notice, this list of conditions and the following disclaimer in the
24  * documentation and/or other materials provided with the distribution;
25  * neither the name of the copyright holders nor the names of its
26  * contributors may be used to endorse or promote products derived from
27  * this software without specific prior written permission.
28  *
29  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
30  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
31  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
32  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
33  * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
34  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
35  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
36  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
37  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
38  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
39  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
40  */
41 
48 #ifndef __MEM_REQUEST_HH__
49 #define __MEM_REQUEST_HH__
50 
51 #include <cassert>
52 #include <climits>
53 
54 #include "base/amo.hh"
55 #include "base/flags.hh"
56 #include "base/logging.hh"
57 #include "base/types.hh"
58 #include "cpu/inst_seq.hh"
59 #include "mem/htm.hh"
60 #include "sim/core.hh"
61 
71  enum TaskId {
72  MaxNormalTaskId = 1021, /* Maximum number of normal tasks */
73  Prefetcher = 1022, /* For cache lines brought in by prefetcher */
74  DMA = 1023, /* Mostly Table Walker */
75  Unknown = 1024,
77  };
78 }
79 
80 class Packet;
81 class Request;
83 
84 typedef std::shared_ptr<Request> RequestPtr;
85 typedef uint16_t RequestorID;
86 
87 class Request
88 {
89  public:
90  typedef uint64_t FlagsType;
91  typedef uint8_t ArchFlagsType;
92  typedef ::Flags<FlagsType> Flags;
93 
94  enum : FlagsType {
102  ARCH_BITS = 0x000000FF,
104  INST_FETCH = 0x00000100,
106  PHYSICAL = 0x00000200,
114  UNCACHEABLE = 0x00000400,
124  STRICT_ORDER = 0x00000800,
126  PRIVILEGED = 0x00008000,
127 
132  CACHE_BLOCK_ZERO = 0x00010000,
133 
135  NO_ACCESS = 0x00080000,
143  LOCKED_RMW = 0x00100000,
145  LLSC = 0x00200000,
147  MEM_SWAP = 0x00400000,
148  MEM_SWAP_COND = 0x00800000,
149 
151  PREFETCH = 0x01000000,
153  PF_EXCLUSIVE = 0x02000000,
155  EVICT_NEXT = 0x04000000,
157  ACQUIRE = 0x00020000,
159  RELEASE = 0x00040000,
160 
162  ATOMIC_RETURN_OP = 0x40000000,
164  ATOMIC_NO_RETURN_OP = 0x80000000,
165 
170  KERNEL = 0x00001000,
171 
173  SECURE = 0x10000000,
175  PT_WALK = 0x20000000,
176 
178  INVALIDATE = 0x0000000100000000,
180  CLEAN = 0x0000000200000000,
181 
183  DST_POU = 0x0000001000000000,
184 
186  DST_POC = 0x0000002000000000,
187 
189  DST_BITS = 0x0000003000000000,
190 
194  HTM_START = 0x0000010000000000,
195 
197  HTM_COMMIT = 0x0000020000000000,
198 
200  HTM_CANCEL = 0x0000040000000000,
201 
203  HTM_ABORT = 0x0000080000000000,
204 
205  // What is the different between HTM cancel and abort?
206  //
207  // HTM_CANCEL will originate from a user instruction, e.g.
208  // Arm's TCANCEL or x86's XABORT. This is an explicit request
209  // to end a transaction and restore from the last checkpoint.
210  //
211  // HTM_ABORT is an internally generated request used to synchronize
212  // a transaction's failure between the core and memory subsystem.
213  // If a transaction fails in the core, e.g. because an instruction
214  // within the transaction generates an exception, the core will prepare
215  // itself to stop fetching/executing more instructions and send an
216  // HTM_ABORT to the memory subsystem before restoring the checkpoint.
217  // Similarly, the transaction could fail in the memory subsystem and
218  // this will be communicated to the core via the Packet object.
219  // Once the core notices, it will do the same as the above and send
220  // a HTM_ABORT to the memory subsystem.
221  // A HTM_CANCEL sent to the memory subsystem will ultimately return
222  // to the core which in turn will send a HTM_ABORT.
223  //
224  // This separation is necessary to ensure the disjoint components
225  // of the system work correctly together.
226 
232  };
234  CLEAN | INVALIDATE;
235 
238 
241  enum : RequestorID {
255  invldRequestorId = std::numeric_limits<RequestorID>::max()
256  };
259  typedef uint64_t CacheCoherenceFlagsType;
260  typedef ::Flags<CacheCoherenceFlagsType> CacheCoherenceFlags;
261 
282  enum : CacheCoherenceFlagsType {
284  INV_L1 = 0x00000001,
285  WB_L2 = 0x00000020,
288  SLC_BIT = 0x00000080,
289  GLC_BIT = 0x00000100,
290  };
291 
292  using LocalAccessor =
293  std::function<Cycles(ThreadContext *tc, Packet *pkt)>;
294 
295  private:
296  typedef uint16_t PrivateFlagsType;
297  typedef ::Flags<PrivateFlagsType> PrivateFlags;
298 
299  enum : PrivateFlagsType {
301  VALID_SIZE = 0x00000001,
303  VALID_PADDR = 0x00000002,
305  VALID_VADDR = 0x00000004,
307  VALID_INST_SEQ_NUM = 0x00000008,
309  VALID_PC = 0x00000010,
311  VALID_CONTEXT_ID = 0x00000020,
313  VALID_EXTRA_DATA = 0x00000080,
315  VALID_STREAM_ID = 0x00000100,
316  VALID_SUBSTREAM_ID = 0x00000200,
317  // hardware transactional memory
319  VALID_HTM_ABORT_CAUSE = 0x00000400,
321  VALID_INST_COUNT = 0x00000800,
327  };
328 
329  private:
330 
336 
342  unsigned _size = 0;
343 
346 
351 
354 
357 
360 
367 
372 
378  uint32_t _streamId = 0;
379 
386  uint32_t _substreamId = 0;
387 
390 
394  uint64_t _extraData = 0;
395 
398 
401 
404 
407 
409 
412 
415 
416  public:
417 
423  Request() {}
424 
430  Request(Addr paddr, unsigned size, Flags flags, RequestorID id) :
431  _paddr(paddr), _size(size), _requestorId(id), _time(curTick())
432  {
433  _flags.set(flags);
435  }
436 
437  Request(Addr vaddr, unsigned size, Flags flags,
438  RequestorID id, Addr pc, ContextID cid,
439  AtomicOpFunctorPtr atomic_op=nullptr)
440  {
441  setVirt(vaddr, size, flags, id, pc, std::move(atomic_op));
442  setContext(cid);
443  }
444 
445  Request(const Request& other)
446  : _paddr(other._paddr), _size(other._size),
447  _byteEnable(other._byteEnable),
448  _requestorId(other._requestorId),
449  _flags(other._flags),
451  privateFlags(other.privateFlags),
452  _time(other._time),
453  _taskId(other._taskId), _vaddr(other._vaddr),
455  _pc(other._pc), _reqInstSeqNum(other._reqInstSeqNum),
458  accessDelta(other.accessDelta), depth(other.depth)
459  {
460  atomicOpFunctor.reset(other.atomicOpFunctor ?
461  other.atomicOpFunctor->clone() : nullptr);
462  }
463 
464  ~Request() {}
465 
469  void
470  setContext(ContextID context_id)
471  {
472  _contextId = context_id;
474  }
475 
476  void
477  setStreamId(uint32_t sid)
478  {
479  _streamId = sid;
481  }
482 
483  void
484  setSubStreamId(uint32_t ssid)
485  {
487  _substreamId = ssid;
489  }
490 
495  void
496  setVirt(Addr vaddr, unsigned size, Flags flags, RequestorID id, Addr pc,
497  AtomicOpFunctorPtr amo_op=nullptr)
498  {
499  _vaddr = vaddr;
500  _size = size;
501  _requestorId = id;
502  _pc = pc;
503  _time = curTick();
504 
506  _flags.set(flags);
509  depth = 0;
510  accessDelta = 0;
511  translateDelta = 0;
512  atomicOpFunctor = std::move(amo_op);
513  _localAccessor = nullptr;
514  }
515 
520  void
521  setPaddr(Addr paddr)
522  {
523  _paddr = paddr;
525  }
526 
531  // TODO: this function is still required by TimingSimpleCPU - should be
532  // removed once TimingSimpleCPU will support arbitrarily long multi-line
533  // mem. accesses
534  void splitOnVaddr(Addr split_addr, RequestPtr &req1, RequestPtr &req2)
535  {
536  assert(privateFlags.isSet(VALID_VADDR));
538  assert(split_addr > _vaddr && split_addr < _vaddr + _size);
539  req1 = std::make_shared<Request>(*this);
540  req2 = std::make_shared<Request>(*this);
541  req1->_size = split_addr - _vaddr;
542  req2->_vaddr = split_addr;
543  req2->_size = _size - req1->_size;
544  if (!_byteEnable.empty()) {
545  req1->_byteEnable = std::vector<bool>(
546  _byteEnable.begin(),
547  _byteEnable.begin() + req1->_size);
548  req2->_byteEnable = std::vector<bool>(
549  _byteEnable.begin() + req1->_size,
550  _byteEnable.end());
551  }
552  }
553 
557  bool
558  hasPaddr() const
559  {
561  }
562 
563  Addr
564  getPaddr() const
565  {
566  assert(privateFlags.isSet(VALID_PADDR));
567  return _paddr;
568  }
569 
574  {
576  return _instCount;
577  }
578 
580  {
582  _instCount = val;
583  }
584 
589 
595 
600  mutable int depth = 0;
601 
605  bool
606  hasSize() const
607  {
608  return privateFlags.isSet(VALID_SIZE);
609  }
610 
611  unsigned
612  getSize() const
613  {
614  assert(privateFlags.isSet(VALID_SIZE));
615  return _size;
616  }
617 
618  const std::vector<bool>&
620  {
621  return _byteEnable;
622  }
623 
624  void
626  {
627  assert(be.empty() || be.size() == _size);
628  _byteEnable = be;
629  }
630 
636  bool
637  isMasked() const
638  {
639  return std::find(
640  _byteEnable.begin(),
641  _byteEnable.end(),
642  false) != _byteEnable.end();
643  }
644 
646  Tick
647  time() const
648  {
650  return _time;
651  }
652 
654  bool isLocalAccess() { return (bool)_localAccessor; }
658  Cycles
660  {
661  return _localAccessor(tc, pkt);
662  }
663 
667  bool
669  {
670  return (bool)atomicOpFunctor;
671  }
672 
675  {
676  assert(atomicOpFunctor);
677  return atomicOpFunctor.get();
678  }
679 
685  {
687  return _htmAbortCause;
688  }
689 
690  void
692  {
693  assert(isHTMAbort());
696  }
697 
699  Flags
701  {
703  return _flags;
704  }
705 
710  void
712  {
714  _flags.set(flags);
715  }
716 
717  void
719  {
720  // TODO: do mem_sync_op requests have valid paddr/vaddr?
722  _cacheCoherenceFlags.set(extraFlags);
723  }
724 
726  bool
727  hasVaddr() const
728  {
730  }
731 
732  Addr
733  getVaddr() const
734  {
735  assert(privateFlags.isSet(VALID_VADDR));
736  return _vaddr;
737  }
738 
741  requestorId() const
742  {
743  return _requestorId;
744  }
745 
746  uint32_t
747  taskId() const
748  {
749  return _taskId;
750  }
751 
752  void
753  taskId(uint32_t id) {
754  _taskId = id;
755  }
756 
759  getArchFlags() const
760  {
762  return _flags & ARCH_BITS;
763  }
764 
766  bool
768  {
770  }
771 
773  uint64_t
774  getExtraData() const
775  {
777  return _extraData;
778  }
779 
781  void
782  setExtraData(uint64_t extraData)
783  {
784  _extraData = extraData;
786  }
787 
788  bool
789  hasContextId() const
790  {
792  }
793 
795  ContextID
796  contextId() const
797  {
799  return _contextId;
800  }
801 
802  uint32_t
803  streamId() const
804  {
806  return _streamId;
807  }
808 
809  bool
811  {
813  }
814 
815  uint32_t
816  substreamId() const
817  {
819  return _substreamId;
820  }
821 
822  void
824  {
826  _pc = pc;
827  }
828 
829  bool
830  hasPC() const
831  {
832  return privateFlags.isSet(VALID_PC);
833  }
834 
836  Addr
837  getPC() const
838  {
839  assert(privateFlags.isSet(VALID_PC));
840  return _pc;
841  }
842 
847  void incAccessDepth() const { depth++; }
848  int getAccessDepth() const { return depth; }
849 
855 
861  Tick getAccessLatency() const { return accessDelta; }
862 
867  bool
869  {
871  }
872 
873  InstSeqNum
875  {
877  return _reqInstSeqNum;
878  }
879 
880  void
882  {
884  _reqInstSeqNum = seq_num;
885  }
886 
889  bool isUncacheable() const { return _flags.isSet(UNCACHEABLE); }
890  bool isStrictlyOrdered() const { return _flags.isSet(STRICT_ORDER); }
891  bool isInstFetch() const { return _flags.isSet(INST_FETCH); }
892  bool isPrefetch() const { return (_flags.isSet(PREFETCH) ||
894  bool isPrefetchEx() const { return _flags.isSet(PF_EXCLUSIVE); }
895  bool isLLSC() const { return _flags.isSet(LLSC); }
896  bool isPriv() const { return _flags.isSet(PRIVILEGED); }
897  bool isLockedRMW() const { return _flags.isSet(LOCKED_RMW); }
898  bool isSwap() const { return _flags.isSet(MEM_SWAP|MEM_SWAP_COND); }
899  bool isCondSwap() const { return _flags.isSet(MEM_SWAP_COND); }
900  bool isSecure() const { return _flags.isSet(SECURE); }
901  bool isPTWalk() const { return _flags.isSet(PT_WALK); }
902  bool isRelease() const { return _flags.isSet(RELEASE); }
903  bool isKernel() const { return _flags.isSet(KERNEL); }
904  bool isAtomicReturn() const { return _flags.isSet(ATOMIC_RETURN_OP); }
906  // hardware transactional memory
907  bool isHTMStart() const { return _flags.isSet(HTM_START); }
908  bool isHTMCommit() const { return _flags.isSet(HTM_COMMIT); }
909  bool isHTMCancel() const { return _flags.isSet(HTM_CANCEL); }
910  bool isHTMAbort() const { return _flags.isSet(HTM_ABORT); }
911  bool
912  isHTMCmd() const
913  {
914  return (isHTMStart() || isHTMCommit() ||
915  isHTMCancel() || isHTMAbort());
916  }
917 
918  bool
919  isAtomic() const
920  {
921  return _flags.isSet(ATOMIC_RETURN_OP) ||
923  }
924 
932  bool isToPOU() const { return _flags.isSet(DST_POU); }
933  bool isToPOC() const { return _flags.isSet(DST_POC); }
934  Flags getDest() const { return _flags & DST_BITS; }
935 
936  bool isAcquire() const { return _cacheCoherenceFlags.isSet(ACQUIRE); }
937 
944  bool isSLC() const { return _cacheCoherenceFlags.isSet(SLC_BIT); }
945  bool isGLC() const { return _cacheCoherenceFlags.isSet(GLC_BIT); }
946 
959  bool isCacheClean() const { return _flags.isSet(CLEAN); }
960  bool isCacheInvalidate() const { return _flags.isSet(INVALIDATE); }
961  bool isCacheMaintenance() const { return _flags.isSet(CLEAN|INVALIDATE); }
963 };
964 
965 #endif // __MEM_REQUEST_HH__
Request::intRequestorId
@ intRequestorId
This requestor id is used for message signaled interrupts.
Definition: request.hh:250
Request::isHTMCmd
bool isHTMCmd() const
Definition: request.hh:912
Request::_pc
Addr _pc
program counter of initiating access; for tracing/debugging
Definition: request.hh:400
Request::HTM_CANCEL
@ HTM_CANCEL
The request cancels a HTM transaction.
Definition: request.hh:200
Request::isToPOC
bool isToPOC() const
Definition: request.hh:933
AtomicOpFunctorPtr
std::unique_ptr< AtomicOpFunctor > AtomicOpFunctorPtr
Definition: amo.hh:239
Request::_vaddr
Addr _vaddr
The virtual address of the request.
Definition: request.hh:389
Request::_requestorId
RequestorID _requestorId
The requestor ID which is unique in the system for all ports that are capable of issuing a transactio...
Definition: request.hh:350
Request::ACQUIRE
@ ACQUIRE
The request should be marked with ACQUIRE.
Definition: request.hh:157
Request::getAccessDepth
int getAccessDepth() const
Definition: request.hh:848
Request::CLEAN
@ CLEAN
The request cleans a memory location.
Definition: request.hh:180
Request::incAccessDepth
void incAccessDepth() const
Increment/Get the depth at which this request is responded to.
Definition: request.hh:847
Request::setByteEnable
void setByteEnable(const std::vector< bool > &be)
Definition: request.hh:625
Request::isPrefetch
bool isPrefetch() const
Definition: request.hh:892
Request::RELEASE
@ RELEASE
The request should be marked with RELEASE.
Definition: request.hh:159
Flags::noneSet
bool noneSet() const
Definition: flags.hh:83
Request::setReqInstSeqNum
void setReqInstSeqNum(const InstSeqNum seq_num)
Definition: request.hh:881
Request::getInstCount
Counter getInstCount() const
Accessor for instruction count.
Definition: request.hh:573
Request::isLLSC
bool isLLSC() const
Definition: request.hh:895
Request::_taskId
uint32_t _taskId
The task id associated with this request.
Definition: request.hh:371
Request::_htmAbortCause
HtmFailureFaultCause _htmAbortCause
The cause for HTM transaction abort.
Definition: request.hh:414
Request::setHtmAbortCause
void setHtmAbortCause(HtmFailureFaultCause val)
Definition: request.hh:691
Request::isAtomic
bool isAtomic() const
Definition: request.hh:919
ContextSwitchTaskId::MaxNormalTaskId
@ MaxNormalTaskId
Definition: request.hh:72
Request::isSecure
bool isSecure() const
Definition: request.hh:900
Request::FlagsType
uint64_t FlagsType
Definition: request.hh:90
amo.hh
Request::isLockedRMW
bool isLockedRMW() const
Definition: request.hh:897
Request::privateFlags
PrivateFlags privateFlags
Private flags for field validity checking.
Definition: request.hh:359
Request::setInstCount
void setInstCount(Counter val)
Definition: request.hh:579
Request::Request
Request(Addr vaddr, unsigned size, Flags flags, RequestorID id, Addr pc, ContextID cid, AtomicOpFunctorPtr atomic_op=nullptr)
Definition: request.hh:437
Request::STICKY_FLAGS
@ STICKY_FLAGS
These flags are not cleared when a Request object is reused (assigned a new address).
Definition: request.hh:231
Request::isInstFetch
bool isInstFetch() const
Definition: request.hh:891
Flags< FlagsType >
Request::_localAccessor
LocalAccessor _localAccessor
Definition: request.hh:408
Request::NO_ACCESS
@ NO_ACCESS
The request should not cause a memory access.
Definition: request.hh:135
Request::isHTMCancel
bool isHTMCancel() const
Definition: request.hh:909
ContextID
int ContextID
Globally unique thread context ID.
Definition: types.hh:231
htm.hh
Request::isStrictlyOrdered
bool isStrictlyOrdered() const
Definition: request.hh:890
Request::getVaddr
Addr getVaddr() const
Definition: request.hh:733
Tick
uint64_t Tick
Tick count type.
Definition: types.hh:63
Request::CacheCoherenceFlags
::Flags< CacheCoherenceFlagsType > CacheCoherenceFlags
Definition: request.hh:260
Request::isLocalAccess
bool isLocalAccess()
Is this request for a local memory mapped resource/register?
Definition: request.hh:654
Request::WB_L2
@ WB_L2
Definition: request.hh:285
Request::ARCH_BITS
@ ARCH_BITS
Architecture specific flags.
Definition: request.hh:102
RequestPtr
std::shared_ptr< Request > RequestPtr
Definition: request.hh:82
Request::PRIVILEGED
@ PRIVILEGED
This request is made in privileged mode.
Definition: request.hh:126
Request::DST_POC
@ DST_POC
The request targets the point of coherence.
Definition: request.hh:186
std::vector< bool >
Request::hasInstSeqNum
bool hasInstSeqNum() const
Accessor for the sequence number of instruction that creates the request.
Definition: request.hh:868
InvalidContextID
const ContextID InvalidContextID
Definition: types.hh:232
Request::VALID_HTM_ABORT_CAUSE
@ VALID_HTM_ABORT_CAUSE
Whether or not the abort cause is valid.
Definition: request.hh:319
Request::extraDataValid
bool extraDataValid() const
Accessor function to check if sc result is valid.
Definition: request.hh:767
HtmFailureFaultCause
HtmFailureFaultCause
Definition: htm.hh:44
Request::HTM_CMD
static const FlagsType HTM_CMD
Definition: request.hh:236
Request::isCacheInvalidate
bool isCacheInvalidate() const
Definition: request.hh:960
Request::HTM_START
@ HTM_START
hardware transactional memory
Definition: request.hh:194
Request::MEM_SWAP_COND
@ MEM_SWAP_COND
Definition: request.hh:148
Request::getPaddr
Addr getPaddr() const
Definition: request.hh:564
Request::VALID_VADDR
@ VALID_VADDR
Whether or not the vaddr is valid.
Definition: request.hh:305
Request::DST_BITS
@ DST_BITS
Bits to define the destination of a request.
Definition: request.hh:189
Request::_reqInstSeqNum
InstSeqNum _reqInstSeqNum
Sequence number of the instruction that creates the request.
Definition: request.hh:403
MaxAddr
const Addr MaxAddr
Definition: types.hh:166
ContextSwitchTaskId::DMA
@ DMA
Definition: request.hh:74
Request::CacheCoherenceFlagsType
uint64_t CacheCoherenceFlagsType
Definition: request.hh:259
ContextSwitchTaskId::Unknown
@ Unknown
Definition: request.hh:75
Request::_instCount
Counter _instCount
The instruction count at the time this request is created.
Definition: request.hh:411
Request::accessDelta
Tick accessDelta
Access latency to complete this memory transaction not including translation time.
Definition: request.hh:594
ContextSwitchTaskId::NumTaskId
@ NumTaskId
Definition: request.hh:76
Request::isSLC
bool isSLC() const
Accessor functions for the memory space configuration flags and used by GPU ISAs such as the Heteroge...
Definition: request.hh:944
Request::INST_FETCH
@ INST_FETCH
The request was an instruction fetch.
Definition: request.hh:104
Request::depth
int depth
Level of the cache hierachy where this request was responded to (e.g.
Definition: request.hh:600
Request::hasVaddr
bool hasVaddr() const
Accessor function for vaddr.
Definition: request.hh:727
AtomicOpFunctor
Definition: amo.hh:40
Request::setFlags
void setFlags(Flags flags)
Note that unlike other accessors, this function sets specific flags (ORs them in); it does not assign...
Definition: request.hh:711
Request::LocalAccessor
std::function< Cycles(ThreadContext *tc, Packet *pkt)> LocalAccessor
Definition: request.hh:293
Request::getExtraData
uint64_t getExtraData() const
Accessor function for store conditional return value.
Definition: request.hh:774
Request::getHtmAbortCause
HtmFailureFaultCause getHtmAbortCause() const
Accessor for hardware transactional memory abort cause.
Definition: request.hh:684
Request::hasSize
bool hasSize() const
Accessor for size.
Definition: request.hh:606
Request::isPriv
bool isPriv() const
Definition: request.hh:896
Request::isCacheMaintenance
bool isCacheMaintenance() const
Definition: request.hh:961
RequestorID
uint16_t RequestorID
Definition: request.hh:85
Counter
int64_t Counter
Statistics counter type.
Definition: types.hh:58
Request::STRICT_ORDER
@ STRICT_ORDER
The request is required to be strictly ordered by CPU models and is non-speculative.
Definition: request.hh:124
Request::PHYSICAL
@ PHYSICAL
The virtual address is also the physical address.
Definition: request.hh:106
Request::splitOnVaddr
void splitOnVaddr(Addr split_addr, RequestPtr &req1, RequestPtr &req2)
Generate two requests as if this request had been split into two pieces.
Definition: request.hh:534
Request::CACHE_BLOCK_ZERO
@ CACHE_BLOCK_ZERO
This is a write that is targeted and zeroing an entire cache block.
Definition: request.hh:132
Request::PrivateFlagsType
uint16_t PrivateFlagsType
Definition: request.hh:296
Request::SECURE
@ SECURE
The request targets the secure memory space.
Definition: request.hh:173
inst_seq.hh
ThreadContext
ThreadContext is the external interface to all thread state for anything outside of the CPU.
Definition: thread_context.hh:88
Request::_extraData
uint64_t _extraData
Extra data for the request, such as the return value of store conditional or the compare value for a ...
Definition: request.hh:394
Request::VALID_EXTRA_DATA
@ VALID_EXTRA_DATA
Whether or not the sc result is valid.
Definition: request.hh:313
Request::getPC
Addr getPC() const
Accessor function for pc.
Definition: request.hh:837
Flags::clear
void clear()
Definition: flags.hh:85
Request::getByteEnable
const std::vector< bool > & getByteEnable() const
Definition: request.hh:619
Request::atomicOpFunctor
AtomicOpFunctorPtr atomicOpFunctor
A pointer to an atomic operation.
Definition: request.hh:406
Request::Request
Request(const Request &other)
Definition: request.hh:445
Request::~Request
~Request()
Definition: request.hh:464
Request::PREFETCH
@ PREFETCH
The request is a prefetch.
Definition: request.hh:151
Request::setExtraData
void setExtraData(uint64_t extraData)
Accessor function for store conditional return value.
Definition: request.hh:782
Request::taskId
void taskId(uint32_t id)
Definition: request.hh:753
Request::VALID_INST_COUNT
@ VALID_INST_COUNT
Whether or not the instruction count is valid.
Definition: request.hh:321
Request::GLC_BIT
@ GLC_BIT
Definition: request.hh:289
MipsISA::vaddr
vaddr
Definition: pra_constants.hh:275
MipsISA::pc
Bitfield< 4 > pc
Definition: pra_constants.hh:240
Request::wbRequestorId
@ wbRequestorId
This requestor id is used for writeback requests by the caches.
Definition: request.hh:243
Request::isAtomicNoReturn
bool isAtomicNoReturn() const
Definition: request.hh:905
Request::SLC_BIT
@ SLC_BIT
user-policy flags
Definition: request.hh:288
Request::_streamId
uint32_t _streamId
The stream ID uniquely identifies a device behind the SMMU/IOMMU Each transaction arriving at the SMM...
Definition: request.hh:378
Request::setSubStreamId
void setSubStreamId(uint32_t ssid)
Definition: request.hh:484
Request::getReqInstSeqNum
InstSeqNum getReqInstSeqNum() const
Definition: request.hh:874
Request::ATOMIC_RETURN_OP
@ ATOMIC_RETURN_OP
The request is an atomic that returns data.
Definition: request.hh:162
MipsISA::be
Bitfield< 15 > be
Definition: pra_constants.hh:220
Request::LOCKED_RMW
@ LOCKED_RMW
This request will lock or unlock the accessed memory.
Definition: request.hh:143
Request::localAccessor
Cycles localAccessor(ThreadContext *tc, Packet *pkt)
Perform the installed local access.
Definition: request.hh:659
Request::MEM_SWAP
@ MEM_SWAP
This request is for a memory swap.
Definition: request.hh:147
Request::invldRequestorId
@ invldRequestorId
Invalid requestor id for assertion checking only.
Definition: request.hh:255
Prefetcher
Copyright (c) 2018 Metempsy Technology Consulting All rights reserved.
Definition: base.hh:78
Request::isPTWalk
bool isPTWalk() const
Definition: request.hh:901
Request::isSwap
bool isSwap() const
Definition: request.hh:898
Flags::set
void set(Type flags)
Definition: flags.hh:87
Request::isToPOU
bool isToPOU() const
Accessor functions for the destination of a memory request.
Definition: request.hh:932
Request::isHTMAbort
bool isHTMAbort() const
Definition: request.hh:910
Request::isAcquire
bool isAcquire() const
Definition: request.hh:936
Request::translateDelta
Tick translateDelta
Time for the TLB/table walker to successfully translate this request.
Definition: request.hh:588
Request::isGLC
bool isGLC() const
Definition: request.hh:945
Request::UNCACHEABLE
@ UNCACHEABLE
The request is to an uncacheable address.
Definition: request.hh:114
Request::isHTMStart
bool isHTMStart() const
Definition: request.hh:907
Request::setPaddr
void setPaddr(Addr paddr)
Set just the physical address.
Definition: request.hh:521
ContextSwitchTaskId
Special TaskIds that are used for per-context-switch stats dumps and Cache Occupancy.
Definition: request.hh:70
Request::VALID_CONTEXT_ID
@ VALID_CONTEXT_ID
Whether or not the context ID is valid.
Definition: request.hh:311
X86ISA::val
Bitfield< 63 > val
Definition: misc.hh:769
InstSeqNum
uint64_t InstSeqNum
Definition: inst_seq.hh:37
Request::isPrefetchEx
bool isPrefetchEx() const
Definition: request.hh:894
Request::_paddr
Addr _paddr
The physical address of the request.
Definition: request.hh:335
core.hh
Request::INVALIDATE
@ INVALIDATE
The request invalidates a memory location.
Definition: request.hh:178
Addr
uint64_t Addr
Address type This will probably be moved somewhere else in the near future.
Definition: types.hh:142
ContextSwitchTaskId::TaskId
TaskId
Definition: request.hh:71
Request::DST_POU
@ DST_POU
The request targets the point of unification.
Definition: request.hh:183
Request::_size
unsigned _size
The size of the request.
Definition: request.hh:342
Request
Definition: request.hh:87
Request::setAccessLatency
void setAccessLatency()
Set/Get the time taken to complete this request's access, not including the time to successfully tran...
Definition: request.hh:860
flags.hh
Request::substreamId
uint32_t substreamId() const
Definition: request.hh:816
Request::setStreamId
void setStreamId(uint32_t sid)
Definition: request.hh:477
Request::HTM_COMMIT
@ HTM_COMMIT
The request commits a HTM transaction.
Definition: request.hh:197
Request::funcRequestorId
@ funcRequestorId
This requestor id is used for functional requests that don't come from a particular device.
Definition: request.hh:248
Request::isRelease
bool isRelease() const
Definition: request.hh:902
Request::_time
Tick _time
The time this request was started.
Definition: request.hh:366
Request::getAccessLatency
Tick getAccessLatency() const
Definition: request.hh:861
Request::STICKY_PRIVATE_FLAGS
@ STICKY_PRIVATE_FLAGS
These flags are not cleared when a Request object is reused (assigned a new address).
Definition: request.hh:326
Request::getFlags
Flags getFlags()
Accessor for flags.
Definition: request.hh:700
Request::isAtomicReturn
bool isAtomicReturn() const
Definition: request.hh:904
Request::PF_EXCLUSIVE
@ PF_EXCLUSIVE
The request should be prefetched into the exclusive state.
Definition: request.hh:153
Request::_cacheCoherenceFlags
CacheCoherenceFlags _cacheCoherenceFlags
Flags that control how downstream cache system maintains coherence.
Definition: request.hh:356
Request::PT_WALK
@ PT_WALK
The request is a page table walk.
Definition: request.hh:175
Request::setContext
void setContext(ContextID context_id)
Set up Context numbers.
Definition: request.hh:470
Request::hasAtomicOpFunctor
bool hasAtomicOpFunctor()
Accessor for atomic-op functor.
Definition: request.hh:668
Request::isCacheClean
bool isCacheClean() const
Accessor functions to determine whether this request is part of a cache maintenance operation.
Definition: request.hh:959
Request::HTM_ABORT
@ HTM_ABORT
The request aborts a HTM transaction.
Definition: request.hh:203
Request::hasPC
bool hasPC() const
Definition: request.hh:830
types.hh
Request::isMasked
bool isMasked() const
Returns true if the memory request is masked, which means there is at least one byteEnable element wh...
Definition: request.hh:637
Request::isHTMCommit
bool isHTMCommit() const
Definition: request.hh:908
Request::setVirt
void setVirt(Addr vaddr, unsigned size, Flags flags, RequestorID id, Addr pc, AtomicOpFunctorPtr amo_op=nullptr)
Set up a virtual (e.g., CPU) request in a previously allocated Request object.
Definition: request.hh:496
Request::hasPaddr
bool hasPaddr() const
Accessor for paddr.
Definition: request.hh:558
Packet
A Packet is used to encapsulate a transfer between two objects in the memory system (e....
Definition: packet.hh:257
Request::KERNEL
@ KERNEL
The request should be marked with KERNEL.
Definition: request.hh:170
Request::VALID_PADDR
@ VALID_PADDR
Whether or not paddr is valid (has been written yet).
Definition: request.hh:303
Request::setPC
void setPC(Addr pc)
Definition: request.hh:823
Request::ATOMIC_NO_RETURN_OP
@ ATOMIC_NO_RETURN_OP
The request is an atomic that does not return data.
Definition: request.hh:164
Request::hasSubstreamId
bool hasSubstreamId() const
Definition: request.hh:810
Request::INV_L1
@ INV_L1
mem_sync_op flags
Definition: request.hh:284
Request::_flags
Flags _flags
Flag structure for the request.
Definition: request.hh:353
logging.hh
Cycles
Cycles is a wrapper class for representing cycle counts, i.e.
Definition: types.hh:83
Request::PrivateFlags
::Flags< PrivateFlagsType > PrivateFlags
Definition: request.hh:297
Request::setLocalAccessor
void setLocalAccessor(LocalAccessor acc)
Set the function which will enact that access.
Definition: request.hh:656
Request::Flags
::Flags< FlagsType > Flags
Definition: request.hh:92
Request::setTranslateLatency
void setTranslateLatency()
Set/Get the time taken for this request to be successfully translated.
Definition: request.hh:853
Request::getAtomicOpFunctor
AtomicOpFunctor * getAtomicOpFunctor()
Definition: request.hh:674
Request::Request
Request(Addr paddr, unsigned size, Flags flags, RequestorID id)
Constructor for physical (e.g.
Definition: request.hh:430
Request::hasContextId
bool hasContextId() const
Definition: request.hh:789
Flags::isSet
bool isSet() const
Definition: flags.hh:79
Request::contextId
ContextID contextId() const
Accessor function for context ID.
Definition: request.hh:796
Request::getArchFlags
ArchFlagsType getArchFlags() const
Accessor function for architecture-specific flags.
Definition: request.hh:759
Request::Request
Request()
Minimal constructor.
Definition: request.hh:423
HtmFailureFaultCause::INVALID
@ INVALID
Request::STORE_NO_DATA
static const FlagsType STORE_NO_DATA
Definition: request.hh:233
Request::_byteEnable
std::vector< bool > _byteEnable
Byte-enable mask for writes.
Definition: request.hh:345
Request::getTranslateLatency
Tick getTranslateLatency() const
Definition: request.hh:854
Request::LLSC
@ LLSC
The request is a Load locked/store conditional.
Definition: request.hh:145
Request::getDest
Flags getDest() const
Definition: request.hh:934
Request::EVICT_NEXT
@ EVICT_NEXT
The request should be marked as LRU.
Definition: request.hh:155
Request::VALID_SUBSTREAM_ID
@ VALID_SUBSTREAM_ID
Definition: request.hh:316
Request::setCacheCoherenceFlags
void setCacheCoherenceFlags(CacheCoherenceFlags extraFlags)
Definition: request.hh:718
Request::VALID_PC
@ VALID_PC
Whether or not the pc is valid.
Definition: request.hh:309
Request::VALID_INST_SEQ_NUM
@ VALID_INST_SEQ_NUM
Whether or not the instruction sequence number is valid.
Definition: request.hh:307
Request::VALID_SIZE
@ VALID_SIZE
Whether or not the size is valid.
Definition: request.hh:301
Request::_substreamId
uint32_t _substreamId
The substream ID identifies an "execution context" within a device behind an SMMU/IOMMU.
Definition: request.hh:386
MaxTick
const Tick MaxTick
Definition: types.hh:65
Request::getSize
unsigned getSize() const
Definition: request.hh:612
Request::requestorId
RequestorID requestorId() const
Accesssor for the requestor id.
Definition: request.hh:741
Request::streamId
uint32_t streamId() const
Definition: request.hh:803
Request::isUncacheable
bool isUncacheable() const
Accessor functions for flags.
Definition: request.hh:889
Request::isCondSwap
bool isCondSwap() const
Definition: request.hh:899
ArmISA::id
Bitfield< 33 > id
Definition: miscregs_types.hh:247
Request::taskId
uint32_t taskId() const
Definition: request.hh:747
Request::ArchFlagsType
uint8_t ArchFlagsType
Definition: request.hh:91
Request::VALID_STREAM_ID
@ VALID_STREAM_ID
Whether or not the stream ID and substream ID is valid.
Definition: request.hh:315
Request::isKernel
bool isKernel() const
Definition: request.hh:903
Request::_contextId
ContextID _contextId
The context ID (for statistics, locks, and wakeups).
Definition: request.hh:397
curTick
Tick curTick()
The current simulated tick.
Definition: core.hh:45
Request::time
Tick time() const
Accessor for time.
Definition: request.hh:647

Generated on Wed Sep 30 2020 14:02:13 for gem5 by doxygen 1.8.17