forked from OSchip/llvm-project
[Hexagon] Removing static variable holding MCInstrInfo.
llvm-svn: 229872
This commit is contained in:
parent
1c2beed7fd
commit
f08a3ccf50
|
@ -17,10 +17,9 @@
|
|||
|
||||
using namespace llvm;
|
||||
|
||||
std::unique_ptr <MCInstrInfo const> HexagonMCInst::MCII;
|
||||
|
||||
HexagonMCInst::HexagonMCInst() : MCInst() {}
|
||||
HexagonMCInst::HexagonMCInst(MCInstrDesc const &mcid) : MCInst() {}
|
||||
HexagonMCInst::HexagonMCInst() : MCII (createHexagonMCInstrInfo ()) {}
|
||||
HexagonMCInst::HexagonMCInst(MCInstrDesc const &mcid) :
|
||||
MCII (createHexagonMCInstrInfo ()){}
|
||||
|
||||
void HexagonMCInst::AppendImplicitOperands(MCInst &MCI) {
|
||||
MCI.addOperand(MCOperand::CreateImm(0));
|
||||
|
|
|
@ -23,9 +23,8 @@ namespace llvm {
|
|||
class MCOperand;
|
||||
|
||||
class HexagonMCInst : public MCInst {
|
||||
friend void ::LLVMInitializeHexagonTargetMC();
|
||||
// Used to access TSFlags
|
||||
static std::unique_ptr <MCInstrInfo const> MCII;
|
||||
std::unique_ptr <MCInstrInfo const> MCII;
|
||||
|
||||
public:
|
||||
explicit HexagonMCInst();
|
||||
|
|
|
@ -36,7 +36,7 @@ using namespace llvm;
|
|||
#define GET_REGINFO_MC_DESC
|
||||
#include "HexagonGenRegisterInfo.inc"
|
||||
|
||||
static MCInstrInfo *createHexagonMCInstrInfo() {
|
||||
MCInstrInfo *llvm::createHexagonMCInstrInfo() {
|
||||
MCInstrInfo *X = new MCInstrInfo();
|
||||
InitHexagonMCInstrInfo(X);
|
||||
return X;
|
||||
|
@ -116,7 +116,6 @@ extern "C" void LLVMInitializeHexagonTargetMC() {
|
|||
// Register the MC instruction info.
|
||||
TargetRegistry::RegisterMCInstrInfo(TheHexagonTarget,
|
||||
createHexagonMCInstrInfo);
|
||||
HexagonMCInst::MCII.reset (createHexagonMCInstrInfo());
|
||||
|
||||
// Register the MC register info.
|
||||
TargetRegistry::RegisterMCRegInfo(TheHexagonTarget,
|
||||
|
|
|
@ -30,6 +30,8 @@ class raw_ostream;
|
|||
|
||||
extern Target TheHexagonTarget;
|
||||
|
||||
MCInstrInfo *createHexagonMCInstrInfo();
|
||||
|
||||
MCCodeEmitter *createHexagonMCCodeEmitter(MCInstrInfo const &MCII,
|
||||
MCRegisterInfo const &MRI,
|
||||
MCSubtargetInfo const &MST,
|
||||
|
|
Loading…
Reference in New Issue