2018-02-23 19:06:40 +08:00
|
|
|
//===- MipsLegalizerInfo.cpp ------------------------------------*- C++ -*-===//
|
|
|
|
//
|
|
|
|
// The LLVM Compiler Infrastructure
|
|
|
|
//
|
|
|
|
// This file is distributed under the University of Illinois Open Source
|
|
|
|
// License. See LICENSE.TXT for details.
|
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
/// \file
|
|
|
|
/// This file implements the targeting of the Machinelegalizer class for Mips.
|
|
|
|
/// \todo This should be generated by TableGen.
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
|
|
|
|
#include "MipsLegalizerInfo.h"
|
2018-06-01 00:16:49 +08:00
|
|
|
#include "MipsTargetMachine.h"
|
2018-02-23 19:06:40 +08:00
|
|
|
|
|
|
|
using namespace llvm;
|
|
|
|
|
|
|
|
MipsLegalizerInfo::MipsLegalizerInfo(const MipsSubtarget &ST) {
|
2018-04-11 23:12:32 +08:00
|
|
|
using namespace TargetOpcode;
|
|
|
|
|
|
|
|
const LLT s32 = LLT::scalar(32);
|
|
|
|
|
|
|
|
getActionDefinitionsBuilder(G_ADD).legalFor({s32});
|
|
|
|
|
2018-02-23 19:06:40 +08:00
|
|
|
computeTables();
|
2018-06-01 00:16:49 +08:00
|
|
|
verify(*ST.getInstrInfo());
|
2018-02-23 19:06:40 +08:00
|
|
|
}
|