summaryrefslogtreecommitdiffstats
path: root/llvm/lib/MC/MCObjectStreamer.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/MC/MCObjectStreamer.cpp')
-rw-r--r--llvm/lib/MC/MCObjectStreamer.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/MC/MCObjectStreamer.cpp b/llvm/lib/MC/MCObjectStreamer.cpp
index 102aa4d4513..9a55ac0a84a 100644
--- a/llvm/lib/MC/MCObjectStreamer.cpp
+++ b/llvm/lib/MC/MCObjectStreamer.cpp
@@ -446,12 +446,12 @@ void MCObjectStreamer::EmitCVLocDirective(unsigned FunctionId, unsigned FileNo,
unsigned Line, unsigned Column,
bool PrologueEnd, bool IsStmt,
StringRef FileName, SMLoc Loc) {
- // In case we see two .cv_loc directives in a row, make sure the
- // first one gets a line entry.
- MCCVLineEntry::Make(this);
-
+ // Unlike dwarf locations, we don't save the MCCVLineEntry until the next
+ // instruction. We create the label exactly where the directive appears in the
+ // assembly.
this->MCStreamer::EmitCVLocDirective(FunctionId, FileNo, Line, Column,
PrologueEnd, IsStmt, FileName, Loc);
+ MCCVLineEntry::Make(this);
}
void MCObjectStreamer::EmitCVLinetableDirective(unsigned FunctionId,
OpenPOWER on IntegriCloud