1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-24 03:33:20 +01:00
llvm-mirror/lib/Target/Lanai/LanaiMachineFunctionInfo.cpp
Jacques Pienaar 9af311f3de [lanai] Add Lanai backend.
Add the Lanai backend to lib/Target.

General Lanai backend discussion on llvm-dev thread "[RFC] Lanai backend" (http://lists.llvm.org/pipermail/llvm-dev/2016-February/095118.html).

Differential Revision: http://reviews.llvm.org/D17011

llvm-svn: 264578
2016-03-28 13:09:54 +00:00

24 lines
694 B
C++

//===-- LanaiMachineFuctionInfo.cpp - Lanai machine function info ---===//
//
// The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
#include "LanaiMachineFunctionInfo.h"
using namespace llvm;
void LanaiMachineFunctionInfo::anchor() {}
unsigned LanaiMachineFunctionInfo::getGlobalBaseReg() {
// Return if it has already been initialized.
if (GlobalBaseReg)
return GlobalBaseReg;
return GlobalBaseReg =
MF.getRegInfo().createVirtualRegister(&Lanai::GPRRegClass);
}