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/AMDGPU | |
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/AMDGPU')
-rw-r--r-- | llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUAsmBackend.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUAsmBackend.cpp b/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUAsmBackend.cpp index 0a9c2b94c1e..d4d845c5322 100644 --- a/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUAsmBackend.cpp +++ b/llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUAsmBackend.cpp @@ -36,7 +36,7 @@ public: const MCValue &Target, uint64_t &Value, bool &IsResolved) 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 fixupNeedsRelaxation(const MCFixup &Fixup, uint64_t Value, const MCRelaxableFragment *DF, @@ -129,8 +129,8 @@ void AMDGPUAsmBackend::processFixupValue(const MCAssembler &Asm, Value = adjustFixupValue(Fixup, Value, &Asm.getContext()); } -void AMDGPUAsmBackend::applyFixup(const MCFixup &Fixup, char *Data, - unsigned DataSize, uint64_t Value, +void AMDGPUAsmBackend::applyFixup(const MCFixup &Fixup, + MutableArrayRef<char> Data, uint64_t Value, bool IsPCRel, MCContext &Ctx) const { if (!Value) return; // Doesn't change encoding. @@ -142,7 +142,7 @@ void AMDGPUAsmBackend::applyFixup(const MCFixup &Fixup, char *Data, unsigned NumBytes = getFixupKindNumBytes(Fixup.getKind()); uint32_t Offset = Fixup.getOffset(); - assert(Offset + NumBytes <= DataSize && "Invalid fixup offset!"); + assert(Offset + NumBytes <= Data.size() && "Invalid fixup offset!"); // For each byte of the fragment that the fixup touches, mask in the bits from // the fixup value. |