Skip to content

Commit b423542

Browse files
author
Sherman Jun Hong Lim
committed
bugfix support belady for lcs
1 parent 289796e commit b423542

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

libCacheSim/bin/cachesim/cache_init.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -125,9 +125,9 @@ static inline cache_t *create_cache(const char *trace_path,
125125
cache = WTinyLFU_init(cc_params, eviction_params);
126126
}
127127
}
128-
} else if (strcasecmp(eviction_algo, "belady") == 0 &&
129-
strcasestr(trace_path, "lcs") == NULL) {
130-
if (strcasestr(trace_path, "oracleGeneral") == NULL) {
128+
} else if (strcasecmp(eviction_algo, "belady") == 0) {
129+
if (strcasestr(trace_path, "oracleGeneral") == NULL &&
130+
strcasestr(trace_path, "lcs") == NULL) {
131131
WARN("belady is only supported for oracleGeneral and lcs trace\n");
132132
WARN("to convert a trace to lcs format\n");
133133
WARN("./bin/traceConv input_trace trace_format output_trace\n");

0 commit comments

Comments
 (0)