14#ifndef LLVM_LIB_TARGET_HEXAGON_MCTARGETDESC_HEXAGONMCCHECKER_H
15#define LLVM_LIB_TARGET_HEXAGON_MCTARGETDESC_HEXAGONMCCHECKER_H
42 using PredSense = std::pair<MCRegister, bool>;
43 static const PredSense Unconditional;
44 using PredSet = std::multiset<PredSense>;
45 using PredSetIterator = std::multiset<PredSense>::iterator;
51 using SoftDefsIterator = std::set<MCRegister>::iterator;
52 std::set<MCRegister> SoftDefs;
55 using TmpDefsIterator = std::set<MCRegister>::iterator;
56 std::set<MCRegister> TmpDefs;
59 using NewPredsIterator = std::set<MCRegister>::iterator;
60 std::set<MCRegister> NewPreds;
63 using LatePredsIterator = std::multiset<MCRegister>::iterator;
64 std::multiset<MCRegister> LatePreds;
67 using UsesIterator = std::set<MCRegister>::iterator;
68 std::set<MCRegister> Uses;
71 using ReadOnlyIterator = std::set<MCRegister>::iterator;
72 std::set<MCRegister> ReadOnly;
76 std::set<MCRegister> ReversePairs;
87 std::tuple<MCInst const *, unsigned, HexagonMCInstrInfo::PredicateInfo>
93 bool checkPredicates();
94 bool checkNewValues();
95 bool checkRegisters();
96 bool checkRegistersReadOnly();
97 void checkRegisterCurDefs();
104 bool checkLegalVecRegPair();
105 bool checkValidTmpDst();
106 bool checkHVXAccum();
108 static void compoundRegisterMap(
unsigned &);
111 return (Hexagon::SA0 == R || Hexagon::LC0 == R || Hexagon::SA1 == R ||
122 bool check(
bool FullCheck =
true);
This file defines the DenseMap class.
DenseMapIterator< KeyT, ValueT, KeyInfoT, BucketT > iterator
void reportErrorNewValue(MCRegister Register)
HexagonMCChecker(MCContext &Context, MCInstrInfo const &MCII, MCSubtargetInfo const &STI, MCInst &mcb, const MCRegisterInfo &ri, bool ReportErrors=true)
bool check(bool FullCheck=true)
void reportWarning(Twine const &Msg)
void reportNote(SMLoc Loc, Twine const &Msg)
void reportErrorRegisters(MCRegister Register)
void reportBranchErrors()
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...
Wrapper class representing physical registers. Should be passed by value.
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.