From 1694b6811f6f4e85bc52d78dd49960efec976462 Mon Sep 17 00:00:00 2001 From: Sahil Date: Wed, 20 Sep 2023 21:04:10 +0000 Subject: [PATCH] PR feedback. Add comment explaining cur_instr_info when at kernel xfer. --- clients/drcachesim/tools/invariant_checker.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/clients/drcachesim/tools/invariant_checker.cpp b/clients/drcachesim/tools/invariant_checker.cpp index 303b7de3bf0..0c2de2cea2a 100644 --- a/clients/drcachesim/tools/invariant_checker.cpp +++ b/clients/drcachesim/tools/invariant_checker.cpp @@ -1075,7 +1075,8 @@ invariant_checker_t::check_for_pc_discontinuity( std::string error_msg = ""; bool have_branch_target = false; addr_t branch_target = 0; - addr_t prev_instr_trace_pc = prev_instr.instr.addr; + const addr_t prev_instr_trace_pc = prev_instr.instr.addr; + // cur_instr_info is a marker (not an instruction) if at_kernel_event is true. const addr_t cur_pc = at_kernel_event ? cur_instr_info.memref.marker.marker_value : cur_instr_info.memref.instr.addr;