aboutsummaryrefslogtreecommitdiff
path: root/lib/MC/MCStreamer.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/MC/MCStreamer.cpp')
-rw-r--r--lib/MC/MCStreamer.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/MC/MCStreamer.cpp b/lib/MC/MCStreamer.cpp
index f5e0d20e09..4d7d486ea9 100644
--- a/lib/MC/MCStreamer.cpp
+++ b/lib/MC/MCStreamer.cpp
@@ -186,6 +186,14 @@ bool MCStreamer::EmitCFIDefCfaOffset(int64_t Offset) {
bool MCStreamer::EmitCFIDefCfaRegister(int64_t Register) {
EnsureValidFrame();
+ MCDwarfFrameInfo *CurFrame = getCurrentFrameInfo();
+ MCSymbol *Label = getContext().CreateTempSymbol();
+ EmitLabel(Label);
+ MachineLocation Dest(Register);
+ MachineLocation Source(MachineLocation::VirtualFP);
+ MCCFIInstruction Instruction(Label, Dest, Source);
+ CurFrame->Instructions.push_back(Instruction);
+ return false;
return false;
}