stride.hh (13422:4ec52da74cd5) | stride.hh (13423:a414d6fccc4e) |
---|---|
1/* 2 * Copyright (c) 2012-2013, 2015 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 --- 96 unchanged lines hidden (view full) --- 105 const int pcTableSets; 106 const std::string _name; 107 std::unordered_map<int, StrideEntry**> entries; 108 109 StrideEntry** allocateNewContext(int context); 110 }; 111 PCTable pcTable; 112 | 1/* 2 * Copyright (c) 2012-2013, 2015 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 --- 96 unchanged lines hidden (view full) --- 105 const int pcTableSets; 106 const std::string _name; 107 std::unordered_map<int, StrideEntry**> entries; 108 109 StrideEntry** allocateNewContext(int context); 110 }; 111 PCTable pcTable; 112 |
113 bool pcTableHit(Addr pc, bool is_secure, int master_id, StrideEntry* &entry); | 113 /** 114 * Search for an entry in the pc table. 115 * 116 * @param pc The PC to look for. 117 * @param is_secure True if the target memory space is secure. 118 * @param master_id The context. 119 * @return Pointer to the entry. 120 */ 121 StrideEntry* findEntry(Addr pc, bool is_secure, int master_id); 122 |
114 StrideEntry* pcTableVictim(Addr pc, int master_id); 115 116 Addr pcHash(Addr pc) const; 117 public: 118 119 StridePrefetcher(const StridePrefetcherParams *p); 120 121 void calculatePrefetch(const PacketPtr &pkt, 122 std::vector<AddrPriority> &addresses) override; 123}; 124 125#endif // __MEM_CACHE_PREFETCH_STRIDE_HH__ | 123 StrideEntry* pcTableVictim(Addr pc, int master_id); 124 125 Addr pcHash(Addr pc) const; 126 public: 127 128 StridePrefetcher(const StridePrefetcherParams *p); 129 130 void calculatePrefetch(const PacketPtr &pkt, 131 std::vector<AddrPriority> &addresses) override; 132}; 133 134#endif // __MEM_CACHE_PREFETCH_STRIDE_HH__ |