diff options
author | Rafael Espindola <rafael.espindola@gmail.com> | 2017-06-21 23:06:53 +0000 |
---|---|---|
committer | Rafael Espindola <rafael.espindola@gmail.com> | 2017-06-21 23:06:53 +0000 |
commit | 88d9e37ec84c86942284d69f3794b824a99e5fab (patch) | |
tree | 4c7263115d8cbdc49e6170a891c5013b8ff0a308 /llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCAsmBackend.cpp | |
parent | 6da25f4fc47353834ba0f1f8e6b9ef570caa662a (diff) | |
download | bcm5719-llvm-88d9e37ec84c86942284d69f3794b824a99e5fab.tar.gz bcm5719-llvm-88d9e37ec84c86942284d69f3794b824a99e5fab.zip |
Use a MutableArrayRef. NFC.
llvm-svn: 305968
Diffstat (limited to 'llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCAsmBackend.cpp')
-rw-r--r-- | llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCAsmBackend.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCAsmBackend.cpp b/llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCAsmBackend.cpp index fd1fd7bc40d..86144dbff88 100644 --- a/llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCAsmBackend.cpp +++ b/llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCAsmBackend.cpp @@ -50,7 +50,7 @@ public: return SystemZ::NumTargetFixupKinds; } const MCFixupKindInfo &getFixupKindInfo(MCFixupKind Kind) const override; - void applyFixup(const MCFixup &Fixup, char *Data, unsigned DataSize, + void applyFixup(const MCFixup &Fixup, MutableArrayRef<char> Data, uint64_t Value, bool IsPCRel, MCContext &Ctx) const override; bool mayNeedRelaxation(const MCInst &Inst) const override { return false; @@ -89,15 +89,15 @@ SystemZMCAsmBackend::getFixupKindInfo(MCFixupKind Kind) const { return Infos[Kind - FirstTargetFixupKind]; } -void SystemZMCAsmBackend::applyFixup(const MCFixup &Fixup, char *Data, - unsigned DataSize, uint64_t Value, +void SystemZMCAsmBackend::applyFixup(const MCFixup &Fixup, + MutableArrayRef<char> Data, uint64_t Value, bool IsPCRel, MCContext &Ctx) const { MCFixupKind Kind = Fixup.getKind(); unsigned Offset = Fixup.getOffset(); unsigned BitSize = getFixupKindInfo(Kind).TargetSize; unsigned Size = (BitSize + 7) / 8; - assert(Offset + Size <= DataSize && "Invalid fixup offset!"); + assert(Offset + Size <= Data.size() && "Invalid fixup offset!"); // Big-endian insertion of Size bytes. Value = extractBitsForFixup(Kind, Value); |