Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

i#6367: Insert FILTER_ENDPOINT when going to TRACE from COUNT also. #6368

Merged
merged 8 commits into from
Oct 20, 2023
7 changes: 6 additions & 1 deletion clients/drcachesim/tracer/output.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1099,9 +1099,14 @@ process_and_output_buffer(void *drcontext, bool skip_size_cap)
}
// Switch to instruction-tracing mode by adding FILTER_ENDPOINT marker if another
prasun3 marked this conversation as resolved.
Show resolved Hide resolved
prasun3 marked this conversation as resolved.
Show resolved Hide resolved
// thread triggered the switch.
ptr_int_t local_mode = get_local_mode(data);
ptr_int_t mode = tracing_mode.load(std::memory_order_acquire);
if (get_local_mode(data) != mode) {
if (get_local_mode(data) == BBDUP_MODE_L0_FILTER) {
if (op_L0_filter_until_instrs.get_value() && mode == BBDUP_MODE_TRACE) {
// It is possible that the local mode was COUNT, but tracing_mode changed
// to L0_FILTER and then to TRACE.
DR_ASSERT(local_mode == BBDUP_MODE_COUNT ||
local_mode == BBDUP_MODE_L0_FILTER);
NOTIFY(0, "Thread %d: filter mode changed\n", dr_get_thread_id(drcontext));

// If a switch occurred, then it is possible that the buffer
Expand Down
Loading