Pass MCSymbols to the helper functions in MCELF.h.
[oota-llvm.git] / lib / Target / PowerPC / MCTargetDesc / PPCAsmBackend.cpp
index 1bfa1534ae6c7e7239e3d0b0b3672e7281ee243d..0fe3534ad62074c4061396bccd8f9dcecf9bbff8 100644 (file)
@@ -142,11 +142,10 @@ public:
       // to resolve the fixup directly.  Emit a relocation and leave
       // resolution of the final target address to the linker.
       if (const MCSymbolRefExpr *A = Target.getSymA()) {
-        const MCSymbolData &Data = A->getSymbol().getData();
         // The "other" values are stored in the last 6 bits of the second byte.
         // The traditional defines for STO values assume the full byte and thus
         // the shift to pack it.
-        unsigned Other = MCELF::getOther(Data) << 2;
+        unsigned Other = MCELF::getOther(A->getSymbol()) << 2;
         if ((Other & ELF::STO_PPC64_LOCAL_MASK) != 0)
           IsResolved = false;
       }