Skip to content
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 9 additions & 4 deletions llvm/docs/MemTagSanitizer.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,15 @@ memory bugs.
Usage
=====

Compile and link your program with ``-fsanitize=memtag`` flag. This
will only work when targeting AArch64 with MemTag extension. One
possible way to achieve that is to add ``-target
aarch64-linux -march=armv8+memtag`` to compilation flags.
Compile and link your program with the ``-fsanitize=memtag`` flag. This
will only work when targeting AArch64 Android with the memory tagging extension.
One possible way to achieve that is to add ``-target
aarch64-linux-android -march=armv8+memtag`` to your compilation flags.

Note that doing this will override existing flags of the same type. Assuming that
you are already targeting AArch64 Android, an alternative is to add
``-Xclang -target-feature -Xclang +mte`` to your compilation flags. This
adds the memory tagging feature, without changing anything else.

Implementation
==============
Expand Down
Loading