#include "LoongArchSubtarget.h"
#include "LoongArchTargetMachine.h"
#include "llvm/CodeGen/MIRParser/MIRParser.h"
#include "llvm/CodeGen/MachineModuleInfo.h"
#include "llvm/IR/Module.h"
#include "llvm/MC/TargetRegistry.h"
#include "llvm/Support/MemoryBuffer.h"
#include "llvm/Support/TargetSelect.h"
#include <optional>
#include "gtest/gtest.h"
usingnamespacellvm;
namespace {
std::unique_ptr<LLVMTargetMachine> createTargetMachine() { … }
std::unique_ptr<LoongArchInstrInfo> createInstrInfo(TargetMachine *TM) { … }
void runChecks(
LLVMTargetMachine *TM, LoongArchInstrInfo *II,
const StringRef InputIRSnippet, const StringRef InputMIRSnippet,
std::function<void(LoongArchInstrInfo &, MachineFunction &)> Checks) { … }
}
TEST(InstSizes, INLINEASM_BR) { … }
TEST(InstSizes, SPACE) { … }
TEST(InstSizes, AtomicPseudo) { … }
TEST(InstSizes, StatePoint) { … }