aboutsummaryrefslogtreecommitdiffstats
path: root/executor/executor.cc
diff options
context:
space:
mode:
authorDmitry Vyukov <dvyukov@google.com>2020-12-15 19:21:25 +0100
committerDmitry Vyukov <dvyukov@google.com>2020-12-16 05:49:44 +0100
commit1b84ed358f51f36c0dd1f69ce45a158f82b5f140 (patch)
tree89605c73b327818ad6dd5f899fdc78ea6a22a65f /executor/executor.cc
parentf213e07ead587b07a84e60c356520bce7277166c (diff)
executor: don't use coverage edges for gvisor
gvisor coverage is not a trace, so producing edges won't work.
Diffstat (limited to 'executor/executor.cc')
-rw-r--r--executor/executor.cc8
1 files changed, 3 insertions, 5 deletions
diff --git a/executor/executor.cc b/executor/executor.cc
index 3c00fd6a2..cbd3048f9 100644
--- a/executor/executor.cc
+++ b/executor/executor.cc
@@ -873,11 +873,9 @@ void write_coverage_signal(cover_t* cov, uint32* signal_count_pos, uint32* cover
bool prev_filter = true;
for (uint32 i = 0; i < cov->size; i++) {
cover_data_t pc = cover_data[i];
- if (!cover_check(pc)) {
- debug("got bad pc: 0x%llx\n", (uint64)pc);
- doexit(0);
- }
- cover_data_t sig = pc ^ hash(prev_pc);
+ uint32 sig = pc;
+ if (use_cover_edges(pc))
+ sig ^= hash(prev_pc);
bool filter = coverage_filter(pc);
// Ignore the edge only if both current and previous PCs are filtered out
// to capture all incoming and outcoming edges into the interesting code.