summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCAsmBackend.cpp
diff options
context:
space:
mode:
authorRafael Espindola <rafael.espindola@gmail.com>2017-06-23 22:52:36 +0000
committerRafael Espindola <rafael.espindola@gmail.com>2017-06-23 22:52:36 +0000
commit801b42de3132c4927b2e4a66baefbbce9143f66a (patch)
tree86100627c3fd311bbbee1176f41cc6ffab89de64 /llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCAsmBackend.cpp
parentf6242c3e90023baf746bca765f843e6c7f0d5660 (diff)
downloadbcm5719-llvm-801b42de3132c4927b2e4a66baefbbce9143f66a.tar.gz
bcm5719-llvm-801b42de3132c4927b2e4a66baefbbce9143f66a.zip
ARM: move some logic from processFixupValue to applyFixup.
processFixupValue is called on every relaxation iteration. applyFixup is only called once at the very end. applyFixup is then the correct place to do last minute changes and value checks. While here, do proper range checks again for fixup_arm_thumb_bl. We used to do it, but dropped because of thumb2. We now do it again, but use the thumb2 range. llvm-svn: 306177
Diffstat (limited to 'llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCAsmBackend.cpp')
-rw-r--r--llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCAsmBackend.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCAsmBackend.cpp b/llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCAsmBackend.cpp
index 86144dbff88..69e275ef203 100644
--- a/llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCAsmBackend.cpp
+++ b/llvm/lib/Target/SystemZ/MCTargetDesc/SystemZMCAsmBackend.cpp
@@ -50,7 +50,8 @@ public:
return SystemZ::NumTargetFixupKinds;
}
const MCFixupKindInfo &getFixupKindInfo(MCFixupKind Kind) const override;
- void applyFixup(const MCFixup &Fixup, MutableArrayRef<char> Data,
+ void applyFixup(const MCAssembler &Asm, const MCFixup &Fixup,
+ const MCValue &Target, MutableArrayRef<char> Data,
uint64_t Value, bool IsPCRel, MCContext &Ctx) const override;
bool mayNeedRelaxation(const MCInst &Inst) const override {
return false;
@@ -89,7 +90,9 @@ SystemZMCAsmBackend::getFixupKindInfo(MCFixupKind Kind) const {
return Infos[Kind - FirstTargetFixupKind];
}
-void SystemZMCAsmBackend::applyFixup(const MCFixup &Fixup,
+void SystemZMCAsmBackend::applyFixup(const MCAssembler &Asm,
+ const MCFixup &Fixup,
+ const MCValue &Target,
MutableArrayRef<char> Data, uint64_t Value,
bool IsPCRel, MCContext &Ctx) const {
MCFixupKind Kind = Fixup.getKind();
OpenPOWER on IntegriCloud