https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/155138
- **[clang] Remove redundant control flow statements (NFC)** - **[FLowSensitive] Remove unused using decls (NFC)** >From dd372e97d9ec98eaa92e9aea5d853b1cb01a5eb4 Mon Sep 17 00:00:00 2001 From: Kazu Hirata <k...@google.com> Date: Fri, 22 Aug 2025 21:53:32 -0700 Subject: [PATCH 1/2] [clang] Remove redundant control flow statements (NFC) --- clang/lib/CodeGen/Targets/RISCV.cpp | 1 - clang/lib/Driver/Driver.cpp | 1 - clang/lib/Driver/ToolChains/HLSL.cpp | 1 - 3 files changed, 3 deletions(-) diff --git a/clang/lib/CodeGen/Targets/RISCV.cpp b/clang/lib/CodeGen/Targets/RISCV.cpp index cbb0255fdb03a..264595a6e4b76 100644 --- a/clang/lib/CodeGen/Targets/RISCV.cpp +++ b/clang/lib/CodeGen/Targets/RISCV.cpp @@ -955,7 +955,6 @@ void RISCVABIInfo::createCoercedStore(llvm::Value *Val, Address Dst, cast<llvm::FixedVectorType>(EltTy), Val, uint64_t(0)); auto *I = CGF.Builder.CreateStore(Coerced, Dst, DestIsVolatile); CGF.addInstToCurrentSourceAtom(I, Val); - return; } namespace { diff --git a/clang/lib/Driver/Driver.cpp b/clang/lib/Driver/Driver.cpp index d682ffc832c83..34eaad43d6f79 100644 --- a/clang/lib/Driver/Driver.cpp +++ b/clang/lib/Driver/Driver.cpp @@ -4672,7 +4672,6 @@ void Driver::BuildDriverManagedModuleBuildActions( Compilation &C, llvm::opt::DerivedArgList &Args, const InputList &Inputs, ActionList &Actions) const { Diags.Report(diag::remark_performing_driver_managed_module_build); - return; } /// Returns the canonical name for the offloading architecture when using a HIP diff --git a/clang/lib/Driver/ToolChains/HLSL.cpp b/clang/lib/Driver/ToolChains/HLSL.cpp index 4fedb5dd0ac40..eaa7d736719b5 100644 --- a/clang/lib/Driver/ToolChains/HLSL.cpp +++ b/clang/lib/Driver/ToolChains/HLSL.cpp @@ -215,7 +215,6 @@ void getSpirvExtOperand(StringRef SpvExtensionArg, raw_ostream &out) { return; } out << SpvExtensionArg; - return; } SmallString<1024> getSpirvExtArg(ArrayRef<std::string> SpvExtensionArgs) { >From 6e6444fd42c6795604a5aa54cbe3b73052240fa4 Mon Sep 17 00:00:00 2001 From: Kazu Hirata <k...@google.com> Date: Fri, 22 Aug 2025 21:55:38 -0700 Subject: [PATCH 2/2] [FLowSensitive] Remove unused using decls (NFC) --- clang/unittests/Analysis/FlowSensitive/FormulaTest.cpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/clang/unittests/Analysis/FlowSensitive/FormulaTest.cpp b/clang/unittests/Analysis/FlowSensitive/FormulaTest.cpp index cabcd59fffedc..db9c02854c7fa 100644 --- a/clang/unittests/Analysis/FlowSensitive/FormulaTest.cpp +++ b/clang/unittests/Analysis/FlowSensitive/FormulaTest.cpp @@ -22,8 +22,6 @@ using namespace dataflow; using ::llvm::Failed; using ::llvm::HasValue; using ::llvm::Succeeded; -using ::testing::ElementsAre; -using ::testing::IsEmpty; class SerializeFormulaTest : public ::testing::Test { protected: _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits