mirror of
				https://github.com/c64scene-ar/llvm-6502.git
				synced 2025-10-30 16:17:05 +00:00 
			
		
		
		
	Do not add the pass that restores $gp if target is Mips64.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@140607 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
		| @@ -96,6 +96,9 @@ addPreEmitPass(PassManagerBase &PM, CodeGenOpt::Level OptLevel) | |||||||
|  |  | ||||||
| bool MipsTargetMachine:: | bool MipsTargetMachine:: | ||||||
| addPreRegAlloc(PassManagerBase &PM, CodeGenOpt::Level OptLevel) { | addPreRegAlloc(PassManagerBase &PM, CodeGenOpt::Level OptLevel) { | ||||||
|  |   // Do not restore $gp if target is Mips64. | ||||||
|  |   // In N32/64, $gp is a callee-saved register. | ||||||
|  |   if (!Subtarget.hasMips64()) | ||||||
|     PM.add(createMipsEmitGPRestorePass(*this)); |     PM.add(createMipsEmitGPRestorePass(*this)); | ||||||
|   return true; |   return true; | ||||||
| } | } | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user