14#ifndef LLVM_LIB_TARGET_HEXAGON_MCTARGETDESC_HEXAGONMCCHECKER_H
15#define LLVM_LIB_TARGET_HEXAGON_MCTARGETDESC_HEXAGONMCCHECKER_H
43 using PredSense = std::pair<unsigned, bool>;
44 static const PredSense Unconditional;
45 using PredSet = std::multiset<PredSense>;
46 using PredSetIterator = std::multiset<PredSense>::iterator;
52 using SoftDefsIterator = std::set<unsigned>::iterator;
53 std::set<unsigned> SoftDefs;
56 using TmpDefsIterator = std::set<unsigned>::iterator;
57 std::set<unsigned> TmpDefs;
60 using NewPredsIterator = std::set<unsigned>::iterator;
61 std::set<unsigned> NewPreds;
64 using LatePredsIterator = std::multiset<unsigned>::iterator;
65 std::multiset<unsigned> LatePreds;
68 using UsesIterator = std::set<unsigned>::iterator;
69 std::set<unsigned> Uses;
72 using ReadOnlyIterator = std::set<unsigned>::iterator;
73 std::set<unsigned> ReadOnly;
77 std::set<unsigned> ReversePairs;
81 void initReg(
MCInst const &,
unsigned,
unsigned &PredReg,
bool &isTrue);
83 bool registerUsed(
unsigned Register);
88 std::tuple<MCInst const *, unsigned, HexagonMCInstrInfo::PredicateInfo>
94 bool checkPredicates();
95 bool checkNewValues();
96 bool checkRegisters();
97 bool checkRegistersReadOnly();
98 void checkRegisterCurDefs();
105 bool checkLegalVecRegPair();
106 bool checkValidTmpDst();
107 bool checkHVXAccum();
109 static void compoundRegisterMap(
unsigned &);
111 bool isLoopRegister(
unsigned R)
const {
112 return (Hexagon::SA0 == R || Hexagon::LC0 == R || Hexagon::SA1 == R ||
123 bool check(
bool FullCheck =
true);
This file defines the DenseMap class.
This file defines the SmallVector class.
Check for a valid bundle.
void reportWarning(Twine const &Msg)
void reportNote(SMLoc Loc, Twine const &Msg)
void reportBranchErrors()
void reportErrorRegisters(unsigned Register)
void reportErrorNewValue(unsigned Register)
void reportError(SMLoc Loc, Twine const &Msg)
Context object for machine code objects.
Instances of this class represent a single low-level machine instruction.
Interface to description of machine instruction set.
MCRegisterInfo base class - We assume that the target defines a static array of MCRegisterDesc object...
Generic base class for all target subtargets.
Wrapper class representing virtual and physical registers.
Represents a location in source code.
Twine - A lightweight data structure for efficiently representing the concatenation of temporary valu...
This is an optimization pass for GlobalISel generic memory operations.