From 45623bd06dfc763241b82be152d0d01d7bb5cf32 Mon Sep 17 00:00:00 2001 From: Justin Bogner Date: Tue, 17 Oct 2017 02:39:40 +0000 Subject: [PATCH] FuzzMutate: Fix arch parsing in FuzzerCLI The right way to parse arch names is by creating a triple. This was using getArchTypeForLLVMName before, which doesn't really do the right thing here. llvm-svn: 315965 --- llvm/lib/FuzzMutate/FuzzerCLI.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/llvm/lib/FuzzMutate/FuzzerCLI.cpp b/llvm/lib/FuzzMutate/FuzzerCLI.cpp index a92b6c0930d8..ef6958efa0b7 100644 --- a/llvm/lib/FuzzMutate/FuzzerCLI.cpp +++ b/llvm/lib/FuzzMutate/FuzzerCLI.cpp @@ -47,7 +47,7 @@ void llvm::handleExecNameEncodedBEOpts(StringRef ExecName) { Args.push_back("-O0"); } else if (Opt.startswith("O")) { Args.push_back("-" + Opt.str()); - } else if (Triple::getArchTypeForLLVMName(Opt)) { + } else if (Triple(Opt).getArch()) { Args.push_back("-mtriple=" + Opt.str()); } else { errs() << ExecName << ": Unknown option: " << Opt << ".\n";