Support new prefetching methodology for stride prefetcher - #7
Support new prefetching methodology for stride prefetcher#7SabaJamilan wants to merge 2 commits into
Conversation
hlitz
left a comment
There was a problem hiding this comment.
Hi Saba,
thanks for your patch!
The code does not compile on my side. Also added 6 nits. Please fix and send another pull request.
--
build/opt/trace_init.cpp: In function ‘CacheGroup* BuildCacheGroup(Config&, const string&, bool)’:
build/opt/trace_init.cpp:435:73: error: no matching function for call to ‘StreamPrefetcher::StreamPrefetcher(g_string&, uint32_t&, uint32_t&, uint32_t&)’
log_distance, degree);
^
In file included from build/opt/trace_init.cpp:59:0:
build/opt/prefetcher.h:132:18: note: candidate: StreamPrefetcher::StreamPrefetcher(const g_string&, uint32_t, uint32_t, uint32_t, const g_string&)
explicit StreamPrefetcher(const g_string& _name,
^~~~~~~~~~~~~~~~
build/opt/prefetcher.h:132:18: note: candidate expects 5 arguments, 4 provided
In file included from build/opt/trace_init.cpp:59:0:
build/opt/prefetcher.h:68:7: note: candidate: StreamPrefetcher::StreamPrefetcher(const StreamPrefetcher&)
class StreamPrefetcher : public BaseCache{
^~~~~~~~~~~~~~~~
build/opt/prefetcher.h:68:7: note: candidate expects 1 argument, 4 provided
build/opt/prefetcher.h:68:7: note: candidate: StreamPrefetcher::StreamPrefetcher(StreamPrefetcher&&)
build/opt/prefetcher.h:68:7: note: candidate expects 1 argument, 4 provided
scons: *** [build/opt/trace_init.o] Error 1
scons: building terminated because of errors.
| profPrefSavedCycles.inc(array[id].availCycle - array[id].startCycle); | ||
| } | ||
| } | ||
| //line is in flight, compensate for potential OOO |
| profPrefHit.inc(); | ||
| } | ||
| array[id].prefetch = false; | ||
|
|
| uint32_t candidate = rp->rankCands(req, SetAssocCands(first, first+assoc)); | ||
|
|
||
| *wbLineAddr = array[candidate].addr; | ||
|
|
| #include "cache_arrays.h" | ||
| #include "hash.h" | ||
| #include "repl_policies.h" | ||
| #include <inttypes.h> |
There was a problem hiding this comment.
not clear why these are needed. There should be no changes to cache_arrays.cpp in this pull request.
| profStrideSwitches.init("strideSwitches", "Predicted stride switches"); s->append(&profStrideSwitches); | ||
| profLowConfAccs.init("lcAccs", "Low-confidence accesses with no prefetches"); s->append(&profLowConfAccs); | ||
| parentStat->append(s); | ||
| prof_emitted_prefetches_.init("pff", "Total prefetches emitted"); |
| * FIXME: For now, mostly hardcoded; 64-line entries (4KB w/64-byte lines), fixed granularities, etc. | ||
| * TODO: Adapt to use weave models | ||
| */ | ||
| class StreamPrefetcher : public BaseCache { |
| //#define DBG(args...) info(args) | ||
| #define DBG(args...) | ||
|
|
||
| void StreamPrefetcher::postInit() { |
There was a problem hiding this comment.
why is this copied from basecache? This class should just inherit from basecache.
|
Hi Heiner, |
No description provided.