diff options
author | Florian Mayer <fmayer@google.com> | 2022-06-02 18:05:02 -0700 |
---|---|---|
committer | Florian Mayer <fmayer@google.com> | 2022-06-08 12:36:32 -0700 |
commit | 0593ce5f0bbb7b9aebc5f15f60876b0bc7aad652 (patch) | |
tree | 4751cdef76588ecbc6b1d1b6b4553b76b6fbd5c2 /llvm/lib/MC/MCStreamer.cpp | |
parent | 56eb8dcf1e00efca01cd6b41c7a85ab2c39b71eb (diff) | |
download | llvm-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/MCStreamer.cpp')
-rw-r--r-- | llvm/lib/MC/MCStreamer.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/llvm/lib/MC/MCStreamer.cpp b/llvm/lib/MC/MCStreamer.cpp index 066a7cd..64b2d26 100644 --- a/llvm/lib/MC/MCStreamer.cpp +++ b/llvm/lib/MC/MCStreamer.cpp @@ -252,6 +252,13 @@ void MCStreamer::emitCFIBKeyFrame() { CurFrame->IsBKeyFrame = true; } +void MCStreamer::emitCFIMTETaggedFrame() { + MCDwarfFrameInfo *CurFrame = getCurrentDwarfFrameInfo(); + if (!CurFrame) + return; + CurFrame->IsMTETaggedFrame = true; +} + void MCStreamer::emitDwarfLocDirective(unsigned FileNo, unsigned Line, unsigned Column, unsigned Flags, unsigned Isa, unsigned Discriminator, |