1 //===---- MipsABIInfo.cpp - Information about MIPS ABI's ------------------===//
3 // The LLVM Compiler Infrastructure
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 #include "MipsABIInfo.h"
11 #include "MipsRegisterInfo.h"
16 static const MCPhysReg O32IntRegs[4] = {Mips::A0, Mips::A1, Mips::A2, Mips::A3};
18 static const MCPhysReg Mips64IntRegs[8] = {
19 Mips::A0_64, Mips::A1_64, Mips::A2_64, Mips::A3_64,
20 Mips::T0_64, Mips::T1_64, Mips::T2_64, Mips::T3_64};
23 const ArrayRef<MCPhysReg> MipsABIInfo::GetByValArgRegs() const {
25 return makeArrayRef(O32IntRegs);
26 if (IsN32() || IsN64())
27 return makeArrayRef(Mips64IntRegs);
28 llvm_unreachable("Unhandled ABI");