OSDN Git Service

1fd2bec16a9a5231f2213cdc97948cddadb7506e
[android-x86/external-llvm.git] / lib / Target / BPF / MCTargetDesc / BPFMCTargetDesc.h
1 //===-- BPFMCTargetDesc.h - BPF Target Descriptions -------------*- C++ -*-===//
2 //
3 //                     The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 //
10 // This file provides BPF specific target descriptions.
11 //
12 //===----------------------------------------------------------------------===//
13
14 #ifndef LLVM_LIB_TARGET_BPF_MCTARGETDESC_BPFMCTARGETDESC_H
15 #define LLVM_LIB_TARGET_BPF_MCTARGETDESC_BPFMCTARGETDESC_H
16
17 #include "llvm/Support/DataTypes.h"
18 #include "llvm/Config/config.h"
19
20 namespace llvm {
21 class MCAsmBackend;
22 class MCCodeEmitter;
23 class MCContext;
24 class MCInstrInfo;
25 class MCObjectWriter;
26 class MCRegisterInfo;
27 class MCSubtargetInfo;
28 class Target;
29 class StringRef;
30 class raw_ostream;
31
32 extern Target TheBPFTarget;
33
34 MCCodeEmitter *createBPFMCCodeEmitter(const MCInstrInfo &MCII,
35                                       const MCRegisterInfo &MRI,
36                                       MCContext &Ctx);
37
38 MCAsmBackend *createBPFAsmBackend(const Target &T, const MCRegisterInfo &MRI,
39                                   StringRef TT, StringRef CPU);
40
41 MCObjectWriter *createBPFELFObjectWriter(raw_ostream &OS, uint8_t OSABI);
42 }
43
44 // Defines symbolic names for BPF registers.  This defines a mapping from
45 // register name to register number.
46 //
47 #define GET_REGINFO_ENUM
48 #include "BPFGenRegisterInfo.inc"
49
50 // Defines symbolic names for the BPF instructions.
51 //
52 #define GET_INSTRINFO_ENUM
53 #include "BPFGenInstrInfo.inc"
54
55 #define GET_SUBTARGETINFO_ENUM
56 #include "BPFGenSubtargetInfo.inc"
57
58 #endif