1 //===- AArch64InstructionSelector --------------------------------*- C++ -*-==//
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 /// This file declares the targeting of the InstructionSelector class for
12 //===----------------------------------------------------------------------===//
14 #ifndef LLVM_LIB_TARGET_AARCH64_AARCH64INSTRUCTIONSELECTOR_H
15 #define LLVM_LIB_TARGET_AARCH64_AARCH64INSTRUCTIONSELECTOR_H
17 #include "llvm/CodeGen/GlobalISel/InstructionSelector.h"
21 class AArch64InstrInfo;
22 class AArch64RegisterBankInfo;
23 class AArch64RegisterInfo;
24 class AArch64Subtarget;
25 class AArch64TargetMachine;
27 class AArch64InstructionSelector : public InstructionSelector {
29 AArch64InstructionSelector(const AArch64TargetMachine &TM,
30 const AArch64Subtarget &STI,
31 const AArch64RegisterBankInfo &RBI);
33 bool select(MachineInstr &I) const override;
36 /// tblgen-erated 'select' implementation, used as the initial selector for
37 /// the patterns that don't require complex C++.
38 bool selectImpl(MachineInstr &I) const;
40 const AArch64TargetMachine &TM;
41 const AArch64Subtarget &STI;
42 const AArch64InstrInfo &TII;
43 const AArch64RegisterInfo &TRI;
44 const AArch64RegisterBankInfo &RBI;
47 } // end namespace llvm
49 #endif // LLVM_LIB_TARGET_AARCH64_AARCH64INSTRUCTIONSELECTOR_H