Skip to content

Commit

Permalink
i#1729 offline traces: handle arm iflush in raw2trace
Browse files Browse the repository at this point in the history
Adds missing support for an ARM instruction cache flush in offline trace
postprocessing (#1729).
  • Loading branch information
derekbruening committed Jun 1, 2017
1 parent fe9a9ae commit 3e33d15
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions clients/drcachesim/tracer/raw2trace.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -512,6 +512,16 @@ raw2trace_t::merge_and_process_thread_files()
VPRINT(2, "Process %u entry\n", (uint)in_entry.pid.pid);
size += instru.append_pid(buf, in_entry.pid.pid);
buf += size;
} else if (in_entry.addr.type == OFFLINE_TYPE_IFLUSH) {
offline_entry_t entry;
if (!thread_files[tidx]->read((char*)&entry, sizeof(entry)) ||
entry.addr.type != OFFLINE_TYPE_IFLUSH)
FATAL_ERROR("Flush missing 2nd entry");
VPRINT(2, "Flush " PFX"-" PFX"\n", (ptr_uint_t)in_entry.addr.addr,
(ptr_uint_t)entry.addr.addr);
size += instru.append_iflush(buf, in_entry.addr.addr,
entry.addr.addr - in_entry.addr.addr);
buf += size;
} else
FATAL_ERROR("Unknown trace type %d", (int)in_entry.timestamp.type);
if (size > 0) {
Expand Down

0 comments on commit 3e33d15

Please sign in to comment.