aboutsummaryrefslogtreecommitdiff
path: root/llvm/unittests/CodeGen
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/unittests/CodeGen')
-rw-r--r--llvm/unittests/CodeGen/DroppedVariableStatsMIRTest.cpp3
-rw-r--r--llvm/unittests/CodeGen/LexicalScopesTest.cpp2
2 files changed, 2 insertions, 3 deletions
diff --git a/llvm/unittests/CodeGen/DroppedVariableStatsMIRTest.cpp b/llvm/unittests/CodeGen/DroppedVariableStatsMIRTest.cpp
index 36504f5..e72b4e4 100644
--- a/llvm/unittests/CodeGen/DroppedVariableStatsMIRTest.cpp
+++ b/llvm/unittests/CodeGen/DroppedVariableStatsMIRTest.cpp
@@ -39,8 +39,7 @@ createTargetMachine(std::string TargetStr, StringRef CPU, StringRef FS) {
return nullptr;
TargetOptions Options;
return std::unique_ptr<TargetMachine>(
- static_cast<TargetMachine *>(T->createTargetMachine(
- TT, CPU, FS, Options, std::nullopt, std::nullopt)));
+ T->createTargetMachine(TT, CPU, FS, Options, std::nullopt, std::nullopt));
}
std::unique_ptr<Module> parseMIR(const TargetMachine &TM, StringRef MIRCode,
diff --git a/llvm/unittests/CodeGen/LexicalScopesTest.cpp b/llvm/unittests/CodeGen/LexicalScopesTest.cpp
index 3d707462..563d496 100644
--- a/llvm/unittests/CodeGen/LexicalScopesTest.cpp
+++ b/llvm/unittests/CodeGen/LexicalScopesTest.cpp
@@ -67,7 +67,7 @@ public:
BeanInst.Opcode = 1;
BeanInst.Size = 1;
- memset(&DbgValueInst, 0, sizeof(DbgValueInst));
+ memset(&DbgValueInst, 0, sizeof(MCInstrDesc));
DbgValueInst.Opcode = TargetOpcode::DBG_VALUE;
DbgValueInst.Size = 1;
DbgValueInst.Flags = 1U << MCID::Meta;