[llvm] r192124 - [mips] Disable tail merging when long branch pass is enabled.
Rafael EspĂndola
rafael.espindola at gmail.com
Mon Oct 7 12:51:56 PDT 2013
testcase?
On 7 October 2013 15:13, Akira Hatanaka <ahatanaka at mips.com> wrote:
> Author: ahatanak
> Date: Mon Oct 7 14:13:53 2013
> New Revision: 192124
>
> URL: http://llvm.org/viewvc/llvm-project?rev=192124&view=rev
> Log:
> [mips] Disable tail merging when long branch pass is enabled.
>
> Modified:
> llvm/trunk/lib/Target/Mips/MipsTargetMachine.cpp
>
> Modified: llvm/trunk/lib/Target/Mips/MipsTargetMachine.cpp
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/Mips/MipsTargetMachine.cpp?rev=192124&r1=192123&r2=192124&view=diff
> ==============================================================================
> --- llvm/trunk/lib/Target/Mips/MipsTargetMachine.cpp (original)
> +++ llvm/trunk/lib/Target/Mips/MipsTargetMachine.cpp Mon Oct 7 14:13:53 2013
> @@ -135,7 +135,13 @@ namespace {
> class MipsPassConfig : public TargetPassConfig {
> public:
> MipsPassConfig(MipsTargetMachine *TM, PassManagerBase &PM)
> - : TargetPassConfig(TM, PM) {}
> + : TargetPassConfig(TM, PM) {
> + // The current implementation of long branch pass requires a scratch
> + // register ($at) to be available before branch instructions. Tail merging
> + // can break this requirement, so disable it when long branch pass is
> + // enabled.
> + EnableTailMerge = !getMipsSubtarget().enableLongBranchPass();
> + }
>
> MipsTargetMachine &getMipsTargetMachine() const {
> return getTM<MipsTargetMachine>();
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
More information about the llvm-commits
mailing list