diff options
author | Sanjin Sijaric <ssijaric@codeaurora.org> | 2018-10-27 06:13:06 +0000 |
---|---|---|
committer | Sanjin Sijaric <ssijaric@codeaurora.org> | 2018-10-27 06:13:06 +0000 |
commit | 96f2ea3dd407792054ea3592e9d243f34695e4af (patch) | |
tree | 0c93a674e81cfae7113347479003aaae44b384c2 /llvm/lib/MC/MCStreamer.cpp | |
parent | 1f6c41f4e072550703c95ab7d675bff903cb637f (diff) | |
download | bcm5719-llvm-96f2ea3dd407792054ea3592e9d243f34695e4af.tar.gz bcm5719-llvm-96f2ea3dd407792054ea3592e9d243f34695e4af.zip |
[ARM64][Windows] MCLayer support for exception handling
Add ARM64 unwind codes to MCLayer, as well SEH directives that will be emitted
by the frame lowering patch to follow. We only emit unwind codes into object
object files for now.
Differential Revision: https://reviews.llvm.org/D50166
llvm-svn: 345450
Diffstat (limited to 'llvm/lib/MC/MCStreamer.cpp')
-rw-r--r-- | llvm/lib/MC/MCStreamer.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/llvm/lib/MC/MCStreamer.cpp b/llvm/lib/MC/MCStreamer.cpp index 1b704b89320..3722c0ad3c8 100644 --- a/llvm/lib/MC/MCStreamer.cpp +++ b/llvm/lib/MC/MCStreamer.cpp @@ -627,6 +627,17 @@ void MCStreamer::EmitWinCFIEndProc(SMLoc Loc) { CurFrame->End = Label; } +void MCStreamer::EmitWinCFIFuncletOrFuncEnd(SMLoc Loc) { + WinEH::FrameInfo *CurFrame = EnsureValidWinFrameInfo(Loc); + if (!CurFrame) + return; + if (CurFrame->ChainedParent) + getContext().reportError(Loc, "Not all chained regions terminated!"); + + MCSymbol *Label = EmitCFILabel(); + CurFrame->FuncletOrFuncEnd = Label; +} + void MCStreamer::EmitWinCFIStartChained(SMLoc Loc) { WinEH::FrameInfo *CurFrame = EnsureValidWinFrameInfo(Loc); if (!CurFrame) |