Skip to content

Commit

Permalink
updated params and debugged mem and prefetch files
Browse files Browse the repository at this point in the history
  • Loading branch information
mgoldstein322 committed Jul 22, 2024
1 parent c3578ac commit 7090101
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 7 deletions.
12 changes: 6 additions & 6 deletions bin/params.in
Original file line number Diff line number Diff line change
Expand Up @@ -65,11 +65,10 @@ l2_large_bypass 0
memory_type igpu_network

# LLC
num_l3 1
l3_num_set 16384 # 128 MB
l3_assoc 64
l3_line_size 128
l3_latency 50
llc_num_set 16384 # 128 MB
llc_assoc 64
llc_line_size 128
llc_latency 50

# DRAM
dram_bus_width 4
Expand All @@ -93,6 +92,7 @@ pref_stream_on_large_core 1
stream_length 64
stream_buffer_n 256
pref_acc_on 1
pref_acc_study 1

# ETC
bug_detector_enable 1
Expand All @@ -111,7 +111,7 @@ debug_exec_stage 0
debug_dcu_stage 0
debug_retire_stage 0
debug_map_stage 0
debug_mem 1
debug_mem 0
debug_pref 1
debug_trace_read 0
debug_sim_thread_schedule 0
Expand Down
1 change: 1 addition & 0 deletions src/memory.cc
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ POSSIBILITY OF SUCH DAMAGE.
#include "statistics.h"

#define DEBUG(args...) _DEBUG(*m_simBase->m_knobs->KNOB_DEBUG_MEM, ##args)
#define DEBUG_PREF(args...) _DEBUG(*m_simBase->m_knobs->KNOB_DEBUG_PREF, ##args)
#define DEBUG_CORE(m_core_id, args...) \
if (m_core_id == *m_simBase->m_knobs->KNOB_DEBUG_CORE_ID) { \
_DEBUG(*m_simBase->m_knobs->KNOB_DEBUG_MEM, ##args); \
Expand Down
7 changes: 6 additions & 1 deletion src/pref_common.cc
Original file line number Diff line number Diff line change
Expand Up @@ -500,20 +500,23 @@ bool hwp_common_c::pref_addto_l1req_queue(Addr line_index, uns8 prefetcher_id) {

// send a new request to l2 request queue
bool hwp_common_c::pref_addto_l2req_queue(Addr line_index, uns8 prefetcher_id) {
DEBUG("l2 demand addr: %llx\n", line_index);
return pref_addto_l2req_queue_set(line_index, prefetcher_id, false, false, 0,
0);
}

// send a new request to l2 request queue
bool hwp_common_c::pref_addto_l2req_queue(Addr line_index, uns8 prefetcher_id,
Addr loadPC) {
DEBUG("l2 demand addr: %llx\n", line_index);
return pref_addto_l2req_queue_set(line_index, prefetcher_id, false, false,
loadPC, 0);
}

// send a new request to l2 request queue
bool hwp_common_c::pref_addto_l2req_queue(Addr line_index, uns8 prefetcher_id,
Addr loadPC, int tid) {
DEBUG("l2 demand addr: %llx\n", line_index);
return pref_addto_l2req_queue_set(line_index, prefetcher_id, false, false,
loadPC, tid);
}
Expand All @@ -522,6 +525,7 @@ bool hwp_common_c::pref_addto_l2req_queue(Addr line_index, uns8 prefetcher_id,
bool hwp_common_c::pref_addto_l2req_queue_set(Addr line_index,
uns8 prefetcher_id, bool Begin,
bool End, Addr loadPC) {
DEBUG("l2 demand addr: %llx\n", line_index);
return pref_addto_l2req_queue_set(line_index, prefetcher_id, Begin, End,
loadPC, 0);
}
Expand All @@ -535,7 +539,7 @@ bool hwp_common_c::pref_addto_l2req_queue_set(Addr line_index,
Addr line_addr;
if (!line_index) // addr = 0
return true;

DEBUG("l2 demand addr: %llx\n", line_index);
line_addr = (line_index) << m_shift_bit;

if (*m_simBase->m_knobs->KNOB_PREF_UPDATE_INTERVAL != 0 &&
Expand Down Expand Up @@ -674,6 +678,7 @@ bool hwp_common_c::pref_addto_l2req_queue_set(Addr line_index,
for (ii = 0; ii < *m_simBase->m_knobs->KNOB_PREF_UL1REQ_QUEUE_SIZE; ++ii) {
if (m_l2req_queue[ii].line_index == line_index) {
STAT_EVENT(PREF_UL2REQ_QUEUE_MATCHED_REQ);
DEBUG("match prefetched address in queue: addr %llx\n", line_index);
return true; // Hit another request
}
}
Expand Down

0 comments on commit 7090101

Please sign in to comment.