2012-05-04 20:18:50 +00:00
|
|
|
//===--- NVPTXFrameLowering.h - Define frame lowering for NVPTX -*- C++ -*-===//
|
|
|
|
//
|
|
|
|
// The LLVM Compiler Infrastructure
|
|
|
|
//
|
|
|
|
// This file is distributed under the University of Illinois Open Source
|
|
|
|
// License. See LICENSE.TXT for details.
|
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
//
|
|
|
|
//
|
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
|
|
|
|
#ifndef NVPTX_FRAMELOWERING_H
|
|
|
|
#define NVPTX_FRAMELOWERING_H
|
|
|
|
|
|
|
|
#include "llvm/Target/TargetFrameLowering.h"
|
|
|
|
|
|
|
|
namespace llvm {
|
|
|
|
class NVPTXTargetMachine;
|
|
|
|
|
|
|
|
class NVPTXFrameLowering : public TargetFrameLowering {
|
|
|
|
NVPTXTargetMachine &tm;
|
|
|
|
bool is64bit;
|
|
|
|
|
|
|
|
public:
|
|
|
|
explicit NVPTXFrameLowering(NVPTXTargetMachine &_tm, bool _is64bit)
|
2013-03-30 14:29:21 +00:00
|
|
|
: TargetFrameLowering(TargetFrameLowering::StackGrowsUp, 8, 0), tm(_tm),
|
|
|
|
is64bit(_is64bit) {}
|
2012-05-04 20:18:50 +00:00
|
|
|
|
|
|
|
virtual bool hasFP(const MachineFunction &MF) const;
|
|
|
|
virtual void emitPrologue(MachineFunction &MF) const;
|
2013-03-30 14:29:21 +00:00
|
|
|
virtual void emitEpilogue(MachineFunction &MF, MachineBasicBlock &MBB) const;
|
2013-02-21 20:05:00 +00:00
|
|
|
|
|
|
|
void eliminateCallFramePseudoInstr(MachineFunction &MF,
|
|
|
|
MachineBasicBlock &MBB,
|
|
|
|
MachineBasicBlock::iterator I) const;
|
2012-05-04 20:18:50 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
} // End llvm namespace
|
|
|
|
|
|
|
|
#endif
|