Skip to content

Commit 6877be0

Browse files
committed
no volatile rw
1 parent 0ea9ff2 commit 6877be0

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

libafl_targets/src/sancov_pcguard.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,12 +19,12 @@ pub unsafe extern "C" fn __sanitizer_cov_trace_pc_guard(guard: *mut u32) {
1919
let pos = *guard as usize;
2020
#[cfg(feature = "sancov_pcguard_edges")]
2121
{
22-
(EDGES_MAP_PTR as *mut u8).add(pos).write_volatile(1);
22+
(EDGES_MAP_PTR as *mut u8).add(pos).write(1);
2323
}
2424
#[cfg(feature = "sancov_pcguard_hitcounts")]
2525
{
26-
let val = (EDGES_MAP_PTR as *mut u8).add(pos).read_volatile();
27-
(EDGES_MAP_PTR as *mut u8).add(pos).write_volatile(val + 1);
26+
let val = (EDGES_MAP_PTR as *mut u8).add(pos).read();
27+
(EDGES_MAP_PTR as *mut u8).add(pos).write(val + 1);
2828
}
2929
}
3030

0 commit comments

Comments
 (0)