Auto merge of #3346 - RalfJung:alloc-accesses, r=RalfJung
Add -Zmiri-track-alloc-accesses to readme and fix its wording I forgot that yesterday...
This commit is contained in:
commit
cdf1071309
2 changed files with 3 additions and 1 deletions
|
@ -412,6 +412,8 @@ to Miri failing to detect cases of undefined behavior in a program.
|
||||||
The default is to search for and remove unreachable provenance once every `10000` basic blocks. Setting
|
The default is to search for and remove unreachable provenance once every `10000` basic blocks. Setting
|
||||||
this to `0` disables the garbage collector, which causes some programs to have explosive memory
|
this to `0` disables the garbage collector, which causes some programs to have explosive memory
|
||||||
usage and/or super-linear runtime.
|
usage and/or super-linear runtime.
|
||||||
|
* `-Zmiri-track-alloc-accesses` show not only allocation and free events for tracked allocations,
|
||||||
|
but also reads and writes.
|
||||||
* `-Zmiri-track-alloc-id=<id1>,<id2>,...` shows a backtrace when the given allocations are
|
* `-Zmiri-track-alloc-id=<id1>,<id2>,...` shows a backtrace when the given allocations are
|
||||||
being allocated or freed. This helps in debugging memory leaks and
|
being allocated or freed. This helps in debugging memory leaks and
|
||||||
use after free bugs. Specifying this argument multiple times does not overwrite the previous
|
use after free bugs. Specifying this argument multiple times does not overwrite the previous
|
||||||
|
|
|
@ -562,7 +562,7 @@ impl<'mir, 'tcx> MiriMachine<'mir, 'tcx> {
|
||||||
align = align.bytes(),
|
align = align.bytes(),
|
||||||
),
|
),
|
||||||
AccessedAlloc(AllocId(id), access_kind) =>
|
AccessedAlloc(AllocId(id), access_kind) =>
|
||||||
format!("{access_kind} access to allocation with id {id}"),
|
format!("{access_kind} to allocation with id {id}"),
|
||||||
FreedAlloc(AllocId(id)) => format!("freed allocation with id {id}"),
|
FreedAlloc(AllocId(id)) => format!("freed allocation with id {id}"),
|
||||||
RejectedIsolatedOp(ref op) =>
|
RejectedIsolatedOp(ref op) =>
|
||||||
format!("{op} was made to return an error due to isolation"),
|
format!("{op} was made to return an error due to isolation"),
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue