diff options
author | Petar Jovanovic <petar.jovanovic@rt-rk.com> | 2013-10-11 03:47:53 +0200 |
---|---|---|
committer | Petar Jovanovic <petar.jovanovic@rt-rk.com> | 2013-10-11 03:47:53 +0200 |
commit | 6a1116e13a072e4f037ad9bd29763086d5124f04 (patch) | |
tree | faf7a84ff2aa071caed16b31626494b6e537ccad /lib/Target/Mips/MipsTargetMachine.cpp | |
parent | cf1867ae88e6bcac7061ae89694dbc44000e421e (diff) |
Apply upstream: [mips] Define method MipsSubtarget::enableLongBranchPass.
Cherry-pick r192122 from upstream.
Original commit message:
Author: Akira Hatanaka <ahatanaka@mips.com>
Date: Mon Oct 7 19:06:57 2013 +0000
[mips] Define method MipsSubtarget::enableLongBranchPass.
This is a helper function/change for a subsequent fix in LongBranchPass,
so we need to cherrypick it to be able to pick the next change as is.
TBR= mseaborn@chromium.org, dschuff@chromium.org
Review URL: https://codereview.chromium.org/26754006
Diffstat (limited to 'lib/Target/Mips/MipsTargetMachine.cpp')
-rw-r--r-- | lib/Target/Mips/MipsTargetMachine.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/Target/Mips/MipsTargetMachine.cpp b/lib/Target/Mips/MipsTargetMachine.cpp index a2fb63d74c..693558770a 100644 --- a/lib/Target/Mips/MipsTargetMachine.cpp +++ b/lib/Target/Mips/MipsTargetMachine.cpp @@ -191,8 +191,7 @@ bool MipsPassConfig::addPreEmitPass() { const MipsSubtarget &Subtarget = TM.getSubtarget<MipsSubtarget>(); addPass(createMipsDelaySlotFillerPass(TM)); - if (Subtarget.hasStandardEncoding() || - Subtarget.allowMixed16_32()) + if (Subtarget.enableLongBranchPass()) addPass(createMipsLongBranchPass(TM)); if (Subtarget.inMips16Mode() || Subtarget.allowMixed16_32()) |