mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-04 02:24:29 +00:00
[mips] Disable tail merging when long branch pass is enabled.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192124 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -135,7 +135,13 @@ namespace {
|
|||||||
class MipsPassConfig : public TargetPassConfig {
|
class MipsPassConfig : public TargetPassConfig {
|
||||||
public:
|
public:
|
||||||
MipsPassConfig(MipsTargetMachine *TM, PassManagerBase &PM)
|
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 {
|
MipsTargetMachine &getMipsTargetMachine() const {
|
||||||
return getTM<MipsTargetMachine>();
|
return getTM<MipsTargetMachine>();
|
||||||
|
Reference in New Issue
Block a user