aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/MC/MCDwarf.cpp
diff options
context:
space:
mode:
authorFlorian Mayer <fmayer@google.com>2022-06-02 18:05:02 -0700
committerFlorian Mayer <fmayer@google.com>2022-06-08 12:36:32 -0700
commit0593ce5f0bbb7b9aebc5f15f60876b0bc7aad652 (patch)
tree4751cdef76588ecbc6b1d1b6b4553b76b6fbd5c2 /llvm/lib/MC/MCDwarf.cpp
parent56eb8dcf1e00efca01cd6b41c7a85ab2c39b71eb (diff)
downloadllvm-0593ce5f0bbb7b9aebc5f15f60876b0bc7aad652.zip
llvm-0593ce5f0bbb7b9aebc5f15f60876b0bc7aad652.tar.gz
llvm-0593ce5f0bbb7b9aebc5f15f60876b0bc7aad652.tar.bz2
[MC] Add 'G' to augmentation string for MTE instrumented functions
This was agreed on in https://lists.llvm.org/pipermail/llvm-dev/2020-May/141345.html The thread proposed two options * add a character to augmentation string and handle in libuwind * use a separate personality function. It was determined that this is the simpler and better option. This is part of ARM's Aarch64 ABI: https://github.com/ARM-software/abi-aa/blob/main/aadwarf64/aadwarf64.rst#id22 The next step after this is teaching libunwind to untag when this augmentation character is set. Reviewed By: MaskRay, eugenis Differential Revision: https://reviews.llvm.org/D127007
Diffstat (limited to 'llvm/lib/MC/MCDwarf.cpp')
-rw-r--r--llvm/lib/MC/MCDwarf.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/llvm/lib/MC/MCDwarf.cpp b/llvm/lib/MC/MCDwarf.cpp
index 0f45f2f..4db409a 100644
--- a/llvm/lib/MC/MCDwarf.cpp
+++ b/llvm/lib/MC/MCDwarf.cpp
@@ -1604,6 +1604,8 @@ const MCSymbol &FrameEmitterImpl::EmitCIE(const MCDwarfFrameInfo &Frame) {
Augmentation += "S";
if (Frame.IsBKeyFrame)
Augmentation += "B";
+ if (Frame.IsMTETaggedFrame)
+ Augmentation += "G";
Streamer.emitBytes(Augmentation);
}
Streamer.emitInt8(0);