aboutsummaryrefslogtreecommitdiffstats
path: root/executor
diff options
context:
space:
mode:
authorDmitry Vyukov <dvyukov@google.com>2024-06-10 11:06:32 +0200
committerDmitry Vyukov <dvyukov@google.com>2024-06-11 05:18:24 +0000
commita1d9c91febfe78c574f0fdb58ee59f23ac970440 (patch)
tree796ef1c2b17382df405a4bc1e679c9ec9e065cbb /executor
parent2a003ea76245ebf8417137c75d95874a91d1a09f (diff)
executor: ignore kernel text addresses in comparisons
We ignore comparisons of kernel data/physical addresses b/c these are not coming from user space. Ignore kernel text addresses for the same reason.
Diffstat (limited to 'executor')
-rw-r--r--executor/executor.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/executor/executor.cc b/executor/executor.cc
index 458931684..c2c361ccf 100644
--- a/executor/executor.cc
+++ b/executor/executor.cc
@@ -1583,8 +1583,8 @@ bool kcov_comparison_t::ignore() const
return true;
// Filter out kernel physical memory addresses.
// These are internal kernel comparisons and should not be interesting.
- bool kptr1 = is_kernel_data(arg1) || arg1 == 0;
- bool kptr2 = is_kernel_data(arg2) || arg2 == 0;
+ bool kptr1 = is_kernel_data(arg1) || is_kernel_pc(arg1) > 0 || arg1 == 0;
+ bool kptr2 = is_kernel_data(arg2) || is_kernel_pc(arg2) > 0 || arg2 == 0;
if (kptr1 && kptr2)
return true;
return !coverage_filter(pc);