DebugInfo: Pass MCSymbolRefExprs for labels instead of MCSymbols

This is a precursor to adding debug info support for TLS which requires
non-default relocations applied to TLS symbols.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@185202 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/CodeGen/AsmPrinter/DIE.h b/lib/CodeGen/AsmPrinter/DIE.h
index c29144d..eaa61d9 100644
--- a/lib/CodeGen/AsmPrinter/DIE.h
+++ b/lib/CodeGen/AsmPrinter/DIE.h
@@ -18,11 +18,13 @@
 #include "llvm/ADT/SmallVector.h"
 #include "llvm/Support/Compiler.h"
 #include "llvm/Support/Dwarf.h"
+#include "llvm/MC/MCExpr.h"
 #include <vector>
 
 namespace llvm {
   class AsmPrinter;
   class MCSymbol;
+  class MCSymbolRefExpr;
   class raw_ostream;
 
   //===--------------------------------------------------------------------===//
@@ -264,9 +266,11 @@
   /// DIELabel - A label expression DIE.
   //
   class DIELabel : public DIEValue {
-    const MCSymbol *Label;
+    const MCSymbolRefExpr *Label;
   public:
-    explicit DIELabel(const MCSymbol *L) : DIEValue(isLabel), Label(L) {}
+    explicit DIELabel(const MCSymbolRefExpr *L) : DIEValue(isLabel), Label(L) {}
+    explicit DIELabel(const MCSymbol *Sym, MCContext &Ctxt)
+        : DIEValue(isLabel), Label(MCSymbolRefExpr::Create(Sym, Ctxt)) {}
 
     /// EmitValue - Emit label value.
     ///
@@ -274,7 +278,7 @@
 
     /// getValue - Get MCSymbol.
     ///
-    const MCSymbol *getValue() const { return Label; }
+    const MCSymbolRefExpr *getValue() const { return Label; }
 
     /// SizeOf - Determine size of label value in bytes.
     ///