2012-12-12 05:25:42 +08:00
|
|
|
//===- AMDGPUMCInstLower.h MachineInstr Lowering Interface ------*- C++ -*-===//
|
|
|
|
//
|
|
|
|
// The LLVM Compiler Infrastructure
|
|
|
|
//
|
|
|
|
// This file is distributed under the University of Illinois Open Source
|
|
|
|
// License. See LICENSE.TXT for details.
|
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
|
2016-03-11 16:00:27 +08:00
|
|
|
#ifndef LLVM_LIB_TARGET_AMDGPU_AMDGPUMCINSTLOWER_H
|
|
|
|
#define LLVM_LIB_TARGET_AMDGPU_AMDGPUMCINSTLOWER_H
|
2012-12-12 05:25:42 +08:00
|
|
|
|
|
|
|
namespace llvm {
|
|
|
|
|
2014-05-17 04:56:47 +08:00
|
|
|
class AMDGPUSubtarget;
|
2016-09-27 01:29:25 +08:00
|
|
|
class AsmPrinter;
|
2016-10-07 00:20:41 +08:00
|
|
|
class MachineBasicBlock;
|
2012-12-12 05:25:42 +08:00
|
|
|
class MachineInstr;
|
2016-10-07 00:20:41 +08:00
|
|
|
class MachineOperand;
|
2014-06-24 02:00:20 +08:00
|
|
|
class MCContext;
|
2016-10-07 00:20:41 +08:00
|
|
|
class MCExpr;
|
2014-06-24 02:00:20 +08:00
|
|
|
class MCInst;
|
2016-10-07 01:19:11 +08:00
|
|
|
class MCOperand;
|
2012-12-12 05:25:42 +08:00
|
|
|
|
|
|
|
class AMDGPUMCInstLower {
|
2012-12-17 23:14:54 +08:00
|
|
|
MCContext &Ctx;
|
2014-05-17 04:56:47 +08:00
|
|
|
const AMDGPUSubtarget &ST;
|
2016-09-27 01:29:25 +08:00
|
|
|
const AsmPrinter ≈
|
2014-05-17 04:56:47 +08:00
|
|
|
|
2016-10-07 00:20:41 +08:00
|
|
|
const MCExpr *getLongBranchBlockExpr(const MachineBasicBlock &SrcBB,
|
|
|
|
const MachineOperand &MO) const;
|
|
|
|
|
2012-12-12 05:25:42 +08:00
|
|
|
public:
|
2016-09-27 01:29:25 +08:00
|
|
|
AMDGPUMCInstLower(MCContext &ctx, const AMDGPUSubtarget &ST,
|
|
|
|
const AsmPrinter &AP);
|
2012-12-12 05:25:42 +08:00
|
|
|
|
2016-10-07 01:19:11 +08:00
|
|
|
bool lowerOperand(const MachineOperand &MO, MCOperand &MCOp) const;
|
|
|
|
|
2012-12-12 05:25:42 +08:00
|
|
|
/// \brief Lower a MachineInstr to an MCInst
|
|
|
|
void lower(const MachineInstr *MI, MCInst &OutMI) const;
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
} // End namespace llvm
|
|
|
|
|
2014-08-14 00:26:38 +08:00
|
|
|
#endif
|