LLVM 17.0.0git
M68k.h
Go to the documentation of this file.
1//===-- M68k.h - Top-level interface for M68k representation ----*- 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/// \file
10/// This file contains the entry points for global functions defined in the
11/// M68k target library, as used by the LLVM JIT.
12///
13//===----------------------------------------------------------------------===//
14
15#ifndef LLVM_LIB_TARGET_M68K_M68K_H
16#define LLVM_LIB_TARGET_M68K_M68K_H
17
18namespace llvm {
19
20class FunctionPass;
21class InstructionSelector;
22class M68kRegisterBankInfo;
23class M68kSubtarget;
24class M68kTargetMachine;
25class PassRegistry;
26
27/// This pass converts a legalized DAG into a M68k-specific DAG, ready for
28/// instruction scheduling.
29FunctionPass *createM68kISelDag(M68kTargetMachine &TM);
30
31/// Return a Machine IR pass that expands M68k-specific pseudo
32/// instructions into a sequence of actual instructions. This pass
33/// must run after prologue/epilogue insertion and before lowering
34/// the MachineInstr to MC.
35FunctionPass *createM68kExpandPseudoPass();
36
37/// This pass initializes a global base register for PIC on M68k.
38FunctionPass *createM68kGlobalBaseRegPass();
39
40/// Finds sequential MOVEM instruction and collapse them into a single one. This
41/// pass has to be run after all pseudo expansions and prologue/epilogue
42/// emission so that all possible MOVEM are already in place.
43FunctionPass *createM68kCollapseMOVEMPass();
44
45/// Finds MOVE instructions before any conditioanl branch instruction and
46/// replaces them with MOVEM instruction. Motorola's MOVEs do trash(V,C) flags
47/// register which prevents branch from taking the correct route. This pass
48/// has to be run after all pseudo expansions and prologue/epilogue emission
49/// so that all possible MOVEs are present.
51
54 const M68kRegisterBankInfo &);
55
57
58} // namespace llvm
59
60#endif // LLVM_LIB_TARGET_M68K_M68K_H
const char LLVMTargetMachineRef TM
FunctionPass class - This class is used to implement most global optimizations.
Definition: Pass.h:308
Provides the logic to select generic machine instructions.
This class provides the information for the target register banks.
PassRegistry - This class manages the registration and intitialization of the pass subsystem as appli...
Definition: PassRegistry.h:38
This is an optimization pass for GlobalISel generic memory operations.
Definition: AddressRanges.h:18
FunctionPass * createM68kGlobalBaseRegPass()
This pass initializes a global base register for PIC on M68k.
FunctionPass * createM68kCollapseMOVEMPass()
Finds sequential MOVEM instruction and collapse them into a single one.
FunctionPass * createM68kISelDag(M68kTargetMachine &TM)
This pass converts a legalized DAG into a M68k-specific DAG, ready for instruction scheduling.
void initializeM68kDAGToDAGISelPass(PassRegistry &)
FunctionPass * createM68kExpandPseudoPass()
Return a Machine IR pass that expands M68k-specific pseudo instructions into a sequence of actual ins...
InstructionSelector * createM68kInstructionSelector(const M68kTargetMachine &TM, const M68kSubtarget &Subtarget, const M68kRegisterBankInfo &RBI)
FunctionPass * createM68kConvertMOVToMOVMPass()
Finds MOVE instructions before any conditioanl branch instruction and replaces them with MOVEM instru...