2012-04-14 09:54:10 -04:00
|
|
|
//===-- PPCMachineFunctionInfo.cpp - Private data used for PowerPC --------===//
|
|
|
|
|
//
|
|
|
|
|
// The LLVM Compiler Infrastructure
|
|
|
|
|
//
|
|
|
|
|
// This file is distributed under the University of Illinois Open Source
|
|
|
|
|
// License. See LICENSE.TXT for details.
|
|
|
|
|
//
|
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
|
|
|
|
|
|
#include "PPCMachineFunctionInfo.h"
|
2014-08-18 14:05:55 -04:00
|
|
|
#include "llvm/MC/MCAsmInfo.h"
|
|
|
|
|
#include "llvm/MC/MCContext.h"
|
|
|
|
|
#include "llvm/Target/TargetMachine.h"
|
2012-04-14 09:54:10 -04:00
|
|
|
|
|
|
|
|
using namespace llvm;
|
|
|
|
|
|
|
|
|
|
void PPCFunctionInfo::anchor() { }
|
|
|
|
|
|
2014-08-18 14:05:55 -04:00
|
|
|
MCSymbol *PPCFunctionInfo::getPICOffsetSymbol() const {
|
|
|
|
|
const MCAsmInfo *MAI = MF.getTarget().getMCAsmInfo();
|
|
|
|
|
return MF.getContext().GetOrCreateSymbol(Twine(MAI->getPrivateGlobalPrefix())+
|
|
|
|
|
Twine(MF.getFunctionNumber())+"$poff");
|
|
|
|
|
}
|