LLVM  9.0.0svn
BPFMCTargetDesc.h
Go to the documentation of this file.
1 //===-- BPFMCTargetDesc.h - BPF Target Descriptions -------------*- C++ -*-===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 //
9 // This file provides BPF specific target descriptions.
10 //
11 //===----------------------------------------------------------------------===//
12 
13 #ifndef LLVM_LIB_TARGET_BPF_MCTARGETDESC_BPFMCTARGETDESC_H
14 #define LLVM_LIB_TARGET_BPF_MCTARGETDESC_BPFMCTARGETDESC_H
15 
16 #include "llvm/Config/config.h"
17 #include "llvm/Support/DataTypes.h"
18 
19 #include <memory>
20 
21 namespace llvm {
22 class MCAsmBackend;
23 class MCCodeEmitter;
24 class MCContext;
25 class MCInstrInfo;
26 class MCObjectTargetWriter;
27 class MCRegisterInfo;
28 class MCSubtargetInfo;
29 class MCTargetOptions;
30 class StringRef;
31 class Target;
32 class Triple;
33 class raw_ostream;
34 class raw_pwrite_stream;
35 
36 Target &getTheBPFleTarget();
37 Target &getTheBPFbeTarget();
38 Target &getTheBPFTarget();
39 
40 MCCodeEmitter *createBPFMCCodeEmitter(const MCInstrInfo &MCII,
41  const MCRegisterInfo &MRI,
42  MCContext &Ctx);
43 MCCodeEmitter *createBPFbeMCCodeEmitter(const MCInstrInfo &MCII,
44  const MCRegisterInfo &MRI,
45  MCContext &Ctx);
46 
47 MCAsmBackend *createBPFAsmBackend(const Target &T, const MCSubtargetInfo &STI,
48  const MCRegisterInfo &MRI,
49  const MCTargetOptions &Options);
50 MCAsmBackend *createBPFbeAsmBackend(const Target &T, const MCSubtargetInfo &STI,
51  const MCRegisterInfo &MRI,
52  const MCTargetOptions &Options);
53 
54 std::unique_ptr<MCObjectTargetWriter> createBPFELFObjectWriter(uint8_t OSABI);
55 }
56 
57 // Defines symbolic names for BPF registers. This defines a mapping from
58 // register name to register number.
59 //
60 #define GET_REGINFO_ENUM
61 #include "BPFGenRegisterInfo.inc"
62 
63 // Defines symbolic names for the BPF instructions.
64 //
65 #define GET_INSTRINFO_ENUM
66 #include "BPFGenInstrInfo.inc"
67 
68 #define GET_SUBTARGETINFO_ENUM
69 #include "BPFGenSubtargetInfo.inc"
70 
71 #endif
This class represents lattice values for constants.
Definition: AllocatorList.h:23
std::unique_ptr< MCObjectTargetWriter > createBPFELFObjectWriter(uint8_t OSABI)
MCCodeEmitter * createBPFbeMCCodeEmitter(const MCInstrInfo &MCII, const MCRegisterInfo &MRI, MCContext &Ctx)
MCAsmBackend * createBPFAsmBackend(const Target &T, const MCSubtargetInfo &STI, const MCRegisterInfo &MRI, const MCTargetOptions &Options)
unsigned const MachineRegisterInfo * MRI
MCAsmBackend * createBPFbeAsmBackend(const Target &T, const MCSubtargetInfo &STI, const MCRegisterInfo &MRI, const MCTargetOptions &Options)
Target & getTheBPFleTarget()
MCCodeEmitter * createBPFMCCodeEmitter(const MCInstrInfo &MCII, const MCRegisterInfo &MRI, MCContext &Ctx)
Target & getTheBPFbeTarget()
Target & getTheBPFTarget()