annotate lib/Target/ARM/ARMBaseInstrInfo.h @ 131:f476a9ba4795

http://llvm.org/svn/llvm-project/compiler-rt/trunk compiler-rt
author mir3636
date Fri, 16 Feb 2018 21:02:11 +0900
parents 803732b1fca8
children 3a76565eade5
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
1 //===-- ARMBaseInstrInfo.h - ARM Base Instruction Information ---*- C++ -*-===//
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
2 //
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
3 // The LLVM Compiler Infrastructure
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
4 //
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
5 // This file is distributed under the University of Illinois Open Source
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
6 // License. See LICENSE.TXT for details.
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
7 //
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
8 //===----------------------------------------------------------------------===//
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
9 //
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
10 // This file contains the Base ARM implementation of the TargetInstrInfo class.
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
11 //
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
12 //===----------------------------------------------------------------------===//
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
13
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
14 #ifndef LLVM_LIB_TARGET_ARM_ARMBASEINSTRINFO_H
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
15 #define LLVM_LIB_TARGET_ARM_ARMBASEINSTRINFO_H
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
16
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
17 #include "MCTargetDesc/ARMBaseInfo.h"
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
18 #include "llvm/ADT/DenseMap.h"
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
19 #include "llvm/ADT/SmallSet.h"
121
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
20 #include "llvm/CodeGen/MachineBasicBlock.h"
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
21 #include "llvm/CodeGen/MachineInstr.h"
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
22 #include "llvm/CodeGen/MachineInstrBuilder.h"
121
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
23 #include "llvm/CodeGen/MachineOperand.h"
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
24 #include "llvm/Target/TargetInstrInfo.h"
121
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
25 #include <array>
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
26 #include <cstdint>
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
27
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
28 #define GET_INSTRINFO_HEADER
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
29 #include "ARMGenInstrInfo.inc"
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
30
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
31 namespace llvm {
121
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
32
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
33 class ARMBaseRegisterInfo;
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
34 class ARMSubtarget;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
35
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
36 class ARMBaseInstrInfo : public ARMGenInstrInfo {
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
37 const ARMSubtarget &Subtarget;
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
38
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
39 protected:
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
40 // Can be only subclassed.
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
41 explicit ARMBaseInstrInfo(const ARMSubtarget &STI);
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
42
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
43 void expandLoadStackGuardBase(MachineBasicBlock::iterator MI,
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
44 unsigned LoadImmOpc, unsigned LoadOpc) const;
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
45
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
46 /// Build the equivalent inputs of a REG_SEQUENCE for the given \p MI
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
47 /// and \p DefIdx.
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
48 /// \p [out] InputRegs of the equivalent REG_SEQUENCE. Each element of
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
49 /// the list is modeled as <Reg:SubReg, SubIdx>.
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
50 /// E.g., REG_SEQUENCE vreg1:sub1, sub0, vreg2, sub1 would produce
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
51 /// two elements:
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
52 /// - vreg1:sub1, sub0
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
53 /// - vreg2<:0>, sub1
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
54 ///
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
55 /// \returns true if it is possible to build such an input sequence
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
56 /// with the pair \p MI, \p DefIdx. False otherwise.
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
57 ///
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
58 /// \pre MI.isRegSequenceLike().
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
59 bool getRegSequenceLikeInputs(
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
60 const MachineInstr &MI, unsigned DefIdx,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
61 SmallVectorImpl<RegSubRegPairAndIdx> &InputRegs) const override;
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
62
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
63 /// Build the equivalent inputs of a EXTRACT_SUBREG for the given \p MI
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
64 /// and \p DefIdx.
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
65 /// \p [out] InputReg of the equivalent EXTRACT_SUBREG.
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
66 /// E.g., EXTRACT_SUBREG vreg1:sub1, sub0, sub1 would produce:
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
67 /// - vreg1:sub1, sub0
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
68 ///
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
69 /// \returns true if it is possible to build such an input sequence
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
70 /// with the pair \p MI, \p DefIdx. False otherwise.
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
71 ///
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
72 /// \pre MI.isExtractSubregLike().
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
73 bool getExtractSubregLikeInputs(const MachineInstr &MI, unsigned DefIdx,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
74 RegSubRegPairAndIdx &InputReg) const override;
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
75
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
76 /// Build the equivalent inputs of a INSERT_SUBREG for the given \p MI
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
77 /// and \p DefIdx.
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
78 /// \p [out] BaseReg and \p [out] InsertedReg contain
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
79 /// the equivalent inputs of INSERT_SUBREG.
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
80 /// E.g., INSERT_SUBREG vreg0:sub0, vreg1:sub1, sub3 would produce:
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
81 /// - BaseReg: vreg0:sub0
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
82 /// - InsertedReg: vreg1:sub1, sub3
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
83 ///
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
84 /// \returns true if it is possible to build such an input sequence
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
85 /// with the pair \p MI, \p DefIdx. False otherwise.
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
86 ///
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
87 /// \pre MI.isInsertSubregLike().
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
88 bool
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
89 getInsertSubregLikeInputs(const MachineInstr &MI, unsigned DefIdx,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
90 RegSubRegPair &BaseReg,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
91 RegSubRegPairAndIdx &InsertedReg) const override;
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
92
95
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
93 /// Commutes the operands in the given instruction.
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
94 /// The commutable operands are specified by their indices OpIdx1 and OpIdx2.
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
95 ///
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
96 /// Do not call this method for a non-commutable instruction or for
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
97 /// non-commutable pair of operand indices OpIdx1 and OpIdx2.
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
98 /// Even though the instruction is commutable, the method may still
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
99 /// fail to commute the operands, null pointer is returned in such cases.
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
100 MachineInstr *commuteInstructionImpl(MachineInstr &MI, bool NewMI,
95
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
101 unsigned OpIdx1,
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
102 unsigned OpIdx2) const override;
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
103
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
104 public:
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
105 // Return whether the target has an explicit NOP encoding.
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
106 bool hasNOP() const;
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
107
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
108 // Return the non-pre/post incrementing version of 'Opc'. Return 0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
109 // if there is not such an opcode.
121
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
110 virtual unsigned getUnindexedOpcode(unsigned Opc) const = 0;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
111
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
112 MachineInstr *convertToThreeAddress(MachineFunction::iterator &MFI,
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
113 MachineInstr &MI,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
114 LiveVariables *LV) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
115
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
116 virtual const ARMBaseRegisterInfo &getRegisterInfo() const = 0;
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
117 const ARMSubtarget &getSubtarget() const { return Subtarget; }
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
118
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
119 ScheduleHazardRecognizer *
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
120 CreateTargetHazardRecognizer(const TargetSubtargetInfo *STI,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
121 const ScheduleDAG *DAG) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
122
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
123 ScheduleHazardRecognizer *
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
124 CreateTargetPostRAHazardRecognizer(const InstrItineraryData *II,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
125 const ScheduleDAG *DAG) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
126
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
127 // Branch analysis.
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
128 bool analyzeBranch(MachineBasicBlock &MBB, MachineBasicBlock *&TBB,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
129 MachineBasicBlock *&FBB,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
130 SmallVectorImpl<MachineOperand> &Cond,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
131 bool AllowModify = false) const override;
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
132 unsigned removeBranch(MachineBasicBlock &MBB,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
133 int *BytesRemoved = nullptr) const override;
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
134 unsigned insertBranch(MachineBasicBlock &MBB, MachineBasicBlock *TBB,
95
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
135 MachineBasicBlock *FBB, ArrayRef<MachineOperand> Cond,
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
136 const DebugLoc &DL,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
137 int *BytesAdded = nullptr) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
138
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
139 bool
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
140 reverseBranchCondition(SmallVectorImpl<MachineOperand> &Cond) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
141
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
142 // Predication support.
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
143 bool isPredicated(const MachineInstr &MI) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
144
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
145 ARMCC::CondCodes getPredicate(const MachineInstr &MI) const {
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
146 int PIdx = MI.findFirstPredOperandIdx();
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
147 return PIdx != -1 ? (ARMCC::CondCodes)MI.getOperand(PIdx).getImm()
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
148 : ARMCC::AL;
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
149 }
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
150
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
151 bool PredicateInstruction(MachineInstr &MI,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
152 ArrayRef<MachineOperand> Pred) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
153
95
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
154 bool SubsumesPredicate(ArrayRef<MachineOperand> Pred1,
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
155 ArrayRef<MachineOperand> Pred2) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
156
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
157 bool DefinesPredicate(MachineInstr &MI,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
158 std::vector<MachineOperand> &Pred) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
159
121
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
160 bool isPredicable(const MachineInstr &MI) const override;
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
161
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
162 // CPSR defined in instruction
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
163 static bool isCPSRDefined(const MachineInstr &MI);
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
164 bool isAddrMode3OpImm(const MachineInstr &MI, unsigned Op) const;
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
165 bool isAddrMode3OpMinusReg(const MachineInstr &MI, unsigned Op) const;
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
166
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
167 // Load, scaled register offset
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
168 bool isLdstScaledReg(const MachineInstr &MI, unsigned Op) const;
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
169 // Load, scaled register offset, not plus LSL2
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
170 bool isLdstScaledRegNotPlusLsl2(const MachineInstr &MI, unsigned Op) const;
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
171 // Minus reg for ldstso addr mode
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
172 bool isLdstSoMinusReg(const MachineInstr &MI, unsigned Op) const;
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
173 // Scaled register offset in address mode 2
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
174 bool isAm2ScaledReg(const MachineInstr &MI, unsigned Op) const;
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
175 // Load multiple, base reg in list
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
176 bool isLDMBaseRegInList(const MachineInstr &MI) const;
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
177 // get LDM variable defs size
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
178 unsigned getLDMVariableDefsSize(const MachineInstr &MI) const;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
179
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
180 /// GetInstSize - Returns the size of the specified MachineInstr.
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
181 ///
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
182 unsigned getInstSizeInBytes(const MachineInstr &MI) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
183
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
184 unsigned isLoadFromStackSlot(const MachineInstr &MI,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
185 int &FrameIndex) const override;
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
186 unsigned isStoreToStackSlot(const MachineInstr &MI,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
187 int &FrameIndex) const override;
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
188 unsigned isLoadFromStackSlotPostFE(const MachineInstr &MI,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
189 int &FrameIndex) const override;
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
190 unsigned isStoreToStackSlotPostFE(const MachineInstr &MI,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
191 int &FrameIndex) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
192
83
60c9769439b8 LLVM 3.7
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 77
diff changeset
193 void copyToCPSR(MachineBasicBlock &MBB, MachineBasicBlock::iterator I,
60c9769439b8 LLVM 3.7
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 77
diff changeset
194 unsigned SrcReg, bool KillSrc,
60c9769439b8 LLVM 3.7
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 77
diff changeset
195 const ARMSubtarget &Subtarget) const;
60c9769439b8 LLVM 3.7
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 77
diff changeset
196 void copyFromCPSR(MachineBasicBlock &MBB, MachineBasicBlock::iterator I,
60c9769439b8 LLVM 3.7
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 77
diff changeset
197 unsigned DestReg, bool KillSrc,
60c9769439b8 LLVM 3.7
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 77
diff changeset
198 const ARMSubtarget &Subtarget) const;
60c9769439b8 LLVM 3.7
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 77
diff changeset
199
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
200 void copyPhysReg(MachineBasicBlock &MBB, MachineBasicBlock::iterator I,
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
201 const DebugLoc &DL, unsigned DestReg, unsigned SrcReg,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
202 bool KillSrc) const override;
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
203
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
204 void storeRegToStackSlot(MachineBasicBlock &MBB,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
205 MachineBasicBlock::iterator MBBI,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
206 unsigned SrcReg, bool isKill, int FrameIndex,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
207 const TargetRegisterClass *RC,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
208 const TargetRegisterInfo *TRI) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
209
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
210 void loadRegFromStackSlot(MachineBasicBlock &MBB,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
211 MachineBasicBlock::iterator MBBI,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
212 unsigned DestReg, int FrameIndex,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
213 const TargetRegisterClass *RC,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
214 const TargetRegisterInfo *TRI) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
215
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
216 bool expandPostRAPseudo(MachineInstr &MI) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
217
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
218 void reMaterialize(MachineBasicBlock &MBB, MachineBasicBlock::iterator MI,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
219 unsigned DestReg, unsigned SubIdx,
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
220 const MachineInstr &Orig,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
221 const TargetRegisterInfo &TRI) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
222
121
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
223 MachineInstr &
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
224 duplicate(MachineBasicBlock &MBB, MachineBasicBlock::iterator InsertBefore,
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
225 const MachineInstr &Orig) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
226
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
227 const MachineInstrBuilder &AddDReg(MachineInstrBuilder &MIB, unsigned Reg,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
228 unsigned SubIdx, unsigned State,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
229 const TargetRegisterInfo *TRI) const;
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
230
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
231 bool produceSameValue(const MachineInstr &MI0, const MachineInstr &MI1,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
232 const MachineRegisterInfo *MRI) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
233
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
234 /// areLoadsFromSameBasePtr - This is used by the pre-regalloc scheduler to
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
235 /// determine if two loads are loading from the same base address. It should
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
236 /// only return true if the base pointers are the same and the only
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
237 /// differences between the two addresses is the offset. It also returns the
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
238 /// offsets by reference.
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
239 bool areLoadsFromSameBasePtr(SDNode *Load1, SDNode *Load2, int64_t &Offset1,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
240 int64_t &Offset2) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
241
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
242 /// shouldScheduleLoadsNear - This is a used by the pre-regalloc scheduler to
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
243 /// determine (in conjunction with areLoadsFromSameBasePtr) if two loads
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
244 /// should be scheduled togther. On some targets if two loads are loading from
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
245 /// addresses in the same cache line, it's better if they are scheduled
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
246 /// together. This function takes two integers that represent the load offsets
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
247 /// from the common base address. It returns true if it decides it's desirable
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
248 /// to schedule the two loads together. "NumLoads" is the number of loads that
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
249 /// have already been scheduled after Load1.
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
250 bool shouldScheduleLoadsNear(SDNode *Load1, SDNode *Load2,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
251 int64_t Offset1, int64_t Offset2,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
252 unsigned NumLoads) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
253
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
254 bool isSchedulingBoundary(const MachineInstr &MI,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
255 const MachineBasicBlock *MBB,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
256 const MachineFunction &MF) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
257
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
258 bool isProfitableToIfCvt(MachineBasicBlock &MBB,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
259 unsigned NumCycles, unsigned ExtraPredCycles,
95
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
260 BranchProbability Probability) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
261
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
262 bool isProfitableToIfCvt(MachineBasicBlock &TMBB, unsigned NumT,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
263 unsigned ExtraT, MachineBasicBlock &FMBB,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
264 unsigned NumF, unsigned ExtraF,
95
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
265 BranchProbability Probability) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
266
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
267 bool isProfitableToDupForIfCvt(MachineBasicBlock &MBB, unsigned NumCycles,
95
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
268 BranchProbability Probability) const override {
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
269 return NumCycles == 1;
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
270 }
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
271
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
272 bool isProfitableToUnpredicate(MachineBasicBlock &TMBB,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
273 MachineBasicBlock &FMBB) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
274
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
275 /// analyzeCompare - For a comparison instruction, return the source registers
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
276 /// in SrcReg and SrcReg2 if having two register operands, and the value it
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
277 /// compares against in CmpValue. Return true if the comparison instruction
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
278 /// can be analyzed.
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
279 bool analyzeCompare(const MachineInstr &MI, unsigned &SrcReg,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
280 unsigned &SrcReg2, int &CmpMask,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
281 int &CmpValue) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
282
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
283 /// optimizeCompareInstr - Convert the instruction to set the zero flag so
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
284 /// that we can remove a "comparison with zero"; Remove a redundant CMP
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
285 /// instruction if the flags can be updated in the same way by an earlier
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
286 /// instruction such as SUB.
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
287 bool optimizeCompareInstr(MachineInstr &CmpInstr, unsigned SrcReg,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
288 unsigned SrcReg2, int CmpMask, int CmpValue,
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
289 const MachineRegisterInfo *MRI) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
290
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
291 bool analyzeSelect(const MachineInstr &MI,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
292 SmallVectorImpl<MachineOperand> &Cond, unsigned &TrueOp,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
293 unsigned &FalseOp, bool &Optimizable) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
294
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
295 MachineInstr *optimizeSelect(MachineInstr &MI,
83
60c9769439b8 LLVM 3.7
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 77
diff changeset
296 SmallPtrSetImpl<MachineInstr *> &SeenMIs,
60c9769439b8 LLVM 3.7
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 77
diff changeset
297 bool) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
298
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
299 /// FoldImmediate - 'Reg' is known to be defined by a move immediate
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
300 /// instruction, try to fold the immediate into the use instruction.
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
301 bool FoldImmediate(MachineInstr &UseMI, MachineInstr &DefMI, unsigned Reg,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
302 MachineRegisterInfo *MRI) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
303
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
304 unsigned getNumMicroOps(const InstrItineraryData *ItinData,
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
305 const MachineInstr &MI) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
306
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
307 int getOperandLatency(const InstrItineraryData *ItinData,
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
308 const MachineInstr &DefMI, unsigned DefIdx,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
309 const MachineInstr &UseMI,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
310 unsigned UseIdx) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
311 int getOperandLatency(const InstrItineraryData *ItinData,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
312 SDNode *DefNode, unsigned DefIdx,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
313 SDNode *UseNode, unsigned UseIdx) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
314
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
315 /// VFP/NEON execution domains.
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
316 std::pair<uint16_t, uint16_t>
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
317 getExecutionDomain(const MachineInstr &MI) const override;
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
318 void setExecutionDomain(MachineInstr &MI, unsigned Domain) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
319
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
320 unsigned
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
321 getPartialRegUpdateClearance(const MachineInstr &, unsigned,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
322 const TargetRegisterInfo *) const override;
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
323 void breakPartialRegDependency(MachineInstr &, unsigned,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
324 const TargetRegisterInfo *TRI) const override;
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
325
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
326 /// Get the number of addresses by LDM or VLDM or zero for unknown.
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
327 unsigned getNumLDMAddresses(const MachineInstr &MI) const;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
328
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
329 private:
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
330 unsigned getInstBundleLength(const MachineInstr &MI) const;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
331
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
332 int getVLDMDefCycle(const InstrItineraryData *ItinData,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
333 const MCInstrDesc &DefMCID,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
334 unsigned DefClass,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
335 unsigned DefIdx, unsigned DefAlign) const;
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
336 int getLDMDefCycle(const InstrItineraryData *ItinData,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
337 const MCInstrDesc &DefMCID,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
338 unsigned DefClass,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
339 unsigned DefIdx, unsigned DefAlign) const;
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
340 int getVSTMUseCycle(const InstrItineraryData *ItinData,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
341 const MCInstrDesc &UseMCID,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
342 unsigned UseClass,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
343 unsigned UseIdx, unsigned UseAlign) const;
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
344 int getSTMUseCycle(const InstrItineraryData *ItinData,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
345 const MCInstrDesc &UseMCID,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
346 unsigned UseClass,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
347 unsigned UseIdx, unsigned UseAlign) const;
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
348 int getOperandLatency(const InstrItineraryData *ItinData,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
349 const MCInstrDesc &DefMCID,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
350 unsigned DefIdx, unsigned DefAlign,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
351 const MCInstrDesc &UseMCID,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
352 unsigned UseIdx, unsigned UseAlign) const;
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
353
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
354 int getOperandLatencyImpl(const InstrItineraryData *ItinData,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
355 const MachineInstr &DefMI, unsigned DefIdx,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
356 const MCInstrDesc &DefMCID, unsigned DefAdj,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
357 const MachineOperand &DefMO, unsigned Reg,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
358 const MachineInstr &UseMI, unsigned UseIdx,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
359 const MCInstrDesc &UseMCID, unsigned UseAdj) const;
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
360
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
361 unsigned getPredicationCost(const MachineInstr &MI) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
362
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
363 unsigned getInstrLatency(const InstrItineraryData *ItinData,
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
364 const MachineInstr &MI,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
365 unsigned *PredCost = nullptr) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
366
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
367 int getInstrLatency(const InstrItineraryData *ItinData,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
368 SDNode *Node) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
369
95
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
370 bool hasHighOperandLatency(const TargetSchedModel &SchedModel,
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
371 const MachineRegisterInfo *MRI,
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
372 const MachineInstr &DefMI, unsigned DefIdx,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
373 const MachineInstr &UseMI,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
374 unsigned UseIdx) const override;
95
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
375 bool hasLowDefLatency(const TargetSchedModel &SchedModel,
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
376 const MachineInstr &DefMI,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
377 unsigned DefIdx) const override;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
378
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
379 /// verifyInstruction - Perform target specific instruction verification.
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
380 bool verifyInstruction(const MachineInstr &MI,
77
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
381 StringRef &ErrInfo) const override;
54457678186b LLVM 3.6
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 33
diff changeset
382
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
383 virtual void expandLoadStackGuard(MachineBasicBlock::iterator MI) const = 0;
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
384
95
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
385 void expandMEMCPY(MachineBasicBlock::iterator) const;
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
386
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
387 private:
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
388 /// Modeling special VFP / NEON fp MLA / MLS hazards.
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
389
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
390 /// MLxEntryMap - Map fp MLA / MLS to the corresponding entry in the internal
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
391 /// MLx table.
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
392 DenseMap<unsigned, unsigned> MLxEntryMap;
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
393
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
394 /// MLxHazardOpcodes - Set of add / sub and multiply opcodes that would cause
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
395 /// stalls when scheduled together with fp MLA / MLS opcodes.
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
396 SmallSet<unsigned, 16> MLxHazardOpcodes;
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
397
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
398 public:
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
399 /// isFpMLxInstruction - Return true if the specified opcode is a fp MLA / MLS
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
400 /// instruction.
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
401 bool isFpMLxInstruction(unsigned Opcode) const {
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
402 return MLxEntryMap.count(Opcode);
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
403 }
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
404
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
405 /// isFpMLxInstruction - This version also returns the multiply opcode and the
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
406 /// addition / subtraction opcode to expand to. Return true for 'HasLane' for
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
407 /// the MLX instructions with an extra lane operand.
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
408 bool isFpMLxInstruction(unsigned Opcode, unsigned &MulOpc,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
409 unsigned &AddSubOpc, bool &NegAcc,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
410 bool &HasLane) const;
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
411
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
412 /// canCauseFpMLxStall - Return true if an instruction of the specified opcode
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
413 /// will cause stalls when scheduled after (within 4-cycle window) a fp
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
414 /// MLA / MLS instruction.
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
415 bool canCauseFpMLxStall(unsigned Opcode) const {
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
416 return MLxHazardOpcodes.count(Opcode);
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
417 }
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
418
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
419 /// Returns true if the instruction has a shift by immediate that can be
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
420 /// executed in one cycle less.
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
421 bool isSwiftFastImmShift(const MachineInstr *MI) const;
121
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
422
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
423 /// Returns predicate register associated with the given frame instruction.
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
424 unsigned getFramePred(const MachineInstr &MI) const {
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
425 assert(isFrameInstr(MI));
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
426 // Operands of ADJCALLSTACKDOWN/ADJCALLSTACKUP:
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
427 // - argument declared in the pattern:
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
428 // 0 - frame size
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
429 // 1 - arg of CALLSEQ_START/CALLSEQ_END
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
430 // 2 - predicate code (like ARMCC::AL)
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
431 // - added by predOps:
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
432 // 3 - predicate reg
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
433 return MI.getOperand(3).getReg();
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
434 }
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
435 };
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
436
121
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
437 /// Get the operands corresponding to the given \p Pred value. By default, the
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
438 /// predicate register is assumed to be 0 (no register), but you can pass in a
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
439 /// \p PredReg if that is not the case.
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
440 static inline std::array<MachineOperand, 2> predOps(ARMCC::CondCodes Pred,
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
441 unsigned PredReg = 0) {
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
442 return {{MachineOperand::CreateImm(static_cast<int64_t>(Pred)),
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
443 MachineOperand::CreateReg(PredReg, false)}};
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
444 }
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
445
121
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
446 /// Get the operand corresponding to the conditional code result. By default,
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
447 /// this is 0 (no register).
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
448 static inline MachineOperand condCodeOp(unsigned CCReg = 0) {
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
449 return MachineOperand::CreateReg(CCReg, false);
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
450 }
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
451
121
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
452 /// Get the operand corresponding to the conditional code result for Thumb1.
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
453 /// This operand will always refer to CPSR and it will have the Define flag set.
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
454 /// You can optionally set the Dead flag by means of \p isDead.
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
455 static inline MachineOperand t1CondCodeOp(bool isDead = false) {
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
456 return MachineOperand::CreateReg(ARM::CPSR,
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
457 /*Define*/ true, /*Implicit*/ false,
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
458 /*Kill*/ false, isDead);
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
459 }
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
460
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
461 static inline
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
462 bool isUncondBranchOpcode(int Opc) {
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
463 return Opc == ARM::B || Opc == ARM::tB || Opc == ARM::t2B;
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
464 }
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
465
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
466 static inline
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
467 bool isCondBranchOpcode(int Opc) {
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
468 return Opc == ARM::Bcc || Opc == ARM::tBcc || Opc == ARM::t2Bcc;
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
469 }
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
470
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
471 static inline
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
472 bool isJumpTableBranchOpcode(int Opc) {
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
473 return Opc == ARM::BR_JTr || Opc == ARM::BR_JTm || Opc == ARM::BR_JTadd ||
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
474 Opc == ARM::tBR_JTr || Opc == ARM::t2BR_JT;
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
475 }
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
476
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
477 static inline
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
478 bool isIndirectBranchOpcode(int Opc) {
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
479 return Opc == ARM::BX || Opc == ARM::MOVPCRX || Opc == ARM::tBRIND;
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
480 }
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
481
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
482 static inline bool isPopOpcode(int Opc) {
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
483 return Opc == ARM::tPOP_RET || Opc == ARM::LDMIA_RET ||
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
484 Opc == ARM::t2LDMIA_RET || Opc == ARM::tPOP || Opc == ARM::LDMIA_UPD ||
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
485 Opc == ARM::t2LDMIA_UPD || Opc == ARM::VLDMDIA_UPD;
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
486 }
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
487
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
488 static inline bool isPushOpcode(int Opc) {
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
489 return Opc == ARM::tPUSH || Opc == ARM::t2STMDB_UPD ||
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
490 Opc == ARM::STMDB_UPD || Opc == ARM::VSTMDDB_UPD;
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
491 }
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
492
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
493 /// getInstrPredicate - If instruction is predicated, returns its predicate
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
494 /// condition, otherwise returns AL. It also returns the condition code
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
495 /// register by reference.
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
496 ARMCC::CondCodes getInstrPredicate(const MachineInstr &MI, unsigned &PredReg);
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
497
95
afa8332a0e37 LLVM 3.8
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 83
diff changeset
498 unsigned getMatchingCondBranchOpcode(unsigned Opc);
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
499
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
500 /// Determine if MI can be folded into an ARM MOVCC instruction, and return the
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
501 /// opcode of the SSA instruction representing the conditional MI.
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
502 unsigned canFoldARMInstrIntoMOVCC(unsigned Reg,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
503 MachineInstr *&MI,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
504 const MachineRegisterInfo &MRI);
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
505
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
506 /// Map pseudo instructions that imply an 'S' bit onto real opcodes. Whether
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
507 /// the instruction is encoded with an 'S' bit is determined by the optional
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
508 /// CPSR def operand.
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
509 unsigned convertAddSubFlagsOpcode(unsigned OldOpc);
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
510
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
511 /// emitARMRegPlusImmediate / emitT2RegPlusImmediate - Emits a series of
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
512 /// instructions to materializea destreg = basereg + immediate in ARM / Thumb2
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
513 /// code.
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
514 void emitARMRegPlusImmediate(MachineBasicBlock &MBB,
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
515 MachineBasicBlock::iterator &MBBI,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
516 const DebugLoc &dl, unsigned DestReg,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
517 unsigned BaseReg, int NumBytes,
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
518 ARMCC::CondCodes Pred, unsigned PredReg,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
519 const ARMBaseInstrInfo &TII, unsigned MIFlags = 0);
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
520
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
521 void emitT2RegPlusImmediate(MachineBasicBlock &MBB,
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
522 MachineBasicBlock::iterator &MBBI,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
523 const DebugLoc &dl, unsigned DestReg,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
524 unsigned BaseReg, int NumBytes,
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
525 ARMCC::CondCodes Pred, unsigned PredReg,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
526 const ARMBaseInstrInfo &TII, unsigned MIFlags = 0);
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
527 void emitThumbRegPlusImmediate(MachineBasicBlock &MBB,
120
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
528 MachineBasicBlock::iterator &MBBI,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
529 const DebugLoc &dl, unsigned DestReg,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
530 unsigned BaseReg, int NumBytes,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
531 const TargetInstrInfo &TII,
1172e4bd9c6f update 4.0.0
mir3636
parents: 95
diff changeset
532 const ARMBaseRegisterInfo &MRI,
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
533 unsigned MIFlags = 0);
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
534
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
535 /// Tries to add registers to the reglist of a given base-updating
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
536 /// push/pop instruction to adjust the stack by an additional
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
537 /// NumBytes. This can save a few bytes per function in code-size, but
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
538 /// obviously generates more memory traffic. As such, it only takes
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
539 /// effect in functions being optimised for size.
33
e4204d083e25 LLVM 3.5
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
540 bool tryFoldSPUpdateIntoPushPop(const ARMSubtarget &Subtarget,
e4204d083e25 LLVM 3.5
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
541 MachineFunction &MF, MachineInstr *MI,
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
542 unsigned NumBytes);
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
543
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
544 /// rewriteARMFrameIndex / rewriteT2FrameIndex -
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
545 /// Rewrite MI to access 'Offset' bytes from the FP. Return false if the
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
546 /// offset could not be handled directly in MI, and return the left-over
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
547 /// portion by reference.
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
548 bool rewriteARMFrameIndex(MachineInstr &MI, unsigned FrameRegIdx,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
549 unsigned FrameReg, int &Offset,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
550 const ARMBaseInstrInfo &TII);
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
551
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
552 bool rewriteT2FrameIndex(MachineInstr &MI, unsigned FrameRegIdx,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
553 unsigned FrameReg, int &Offset,
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
554 const ARMBaseInstrInfo &TII);
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
555
121
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
556 } // end namespace llvm
0
95c75e76d11b LLVM 3.4
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
557
121
803732b1fca8 LLVM 5.0
kono
parents: 120
diff changeset
558 #endif // LLVM_LIB_TARGET_ARM_ARMBASEINSTRINFO_H