Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package cvise for openSUSE:Factory checked in at 2023-04-17 17:41:31 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/cvise (Old) and /work/SRC/openSUSE:Factory/.cvise.new.2023 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "cvise" Mon Apr 17 17:41:31 2023 rev:72 rq:1079869 version:2.7.0+git.20230417.6b558fe Changes: -------- --- /work/SRC/openSUSE:Factory/cvise/cvise.changes 2023-03-31 21:16:44.746731722 +0200 +++ /work/SRC/openSUSE:Factory/.cvise.new.2023/cvise.changes 2023-04-17 17:41:38.898343924 +0200 @@ -1,0 +2,12 @@ +Mon Apr 17 09:06:07 UTC 2023 - mli...@suse.cz + +- Update to version 2.7.0+git.20230417.6b558fe: + * Handle cyclic namespace include that leads to inf. recursion. + * Shorten pass names that use max_transforms property. + * Fix clang warning: + * build: factory out common flags and use -pedantic + * Simplify dump output for BinaryState. + * Revert "drop unneeded -Wno-error=mismatched-new-delete" + * drop unneeded -Wno-error=mismatched-new-delete + +------------------------------------------------------------------- Old: ---- cvise-2.7.0+git.20230331.62a7391.tar.xz New: ---- cvise-2.7.0+git.20230417.6b558fe.tar.xz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ cvise.spec ++++++ --- /var/tmp/diff_new_pack.6HPUuK/_old 2023-04-17 17:41:39.414346940 +0200 +++ /var/tmp/diff_new_pack.6HPUuK/_new 2023-04-17 17:41:39.418346963 +0200 @@ -17,7 +17,7 @@ Name: cvise -Version: 2.7.0+git.20230331.62a7391 +Version: 2.7.0+git.20230417.6b558fe Release: 0 Summary: Super-parallel Python port of the C-Reduce License: BSD-3-Clause ++++++ _servicedata ++++++ --- /var/tmp/diff_new_pack.6HPUuK/_old 2023-04-17 17:41:39.470347267 +0200 +++ /var/tmp/diff_new_pack.6HPUuK/_new 2023-04-17 17:41:39.478347313 +0200 @@ -1,6 +1,6 @@ <servicedata> <service name="tar_scm"> <param name="url">https://github.com/marxin/cvise</param> - <param name="changesrevision">62a7391cdb990ce443ecbb408f8c2e9942dfba25</param></service></servicedata> + <param name="changesrevision">6b558fe0585388f5e52ccd1b571bc1ac08ee0ffd</param></service></servicedata> (No newline at EOF) ++++++ cvise-2.7.0+git.20230331.62a7391.tar.xz -> cvise-2.7.0+git.20230417.6b558fe.tar.xz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.7.0+git.20230331.62a7391/CMakeLists.txt new/cvise-2.7.0+git.20230417.6b558fe/CMakeLists.txt --- old/cvise-2.7.0+git.20230331.62a7391/CMakeLists.txt 2023-03-31 16:04:45.000000000 +0200 +++ new/cvise-2.7.0+git.20230417.6b558fe/CMakeLists.txt 2023-04-17 10:51:36.000000000 +0200 @@ -156,8 +156,9 @@ OR CMAKE_CXX_COMPILER_ID STREQUAL "Clang") # XXX figure out how to get "-std=c++17 -fno-rtti" from LLVM. That's how we # get those options in the Automake path... - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra -Werror") - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++17 -fno-rtti -fno-strict-aliasing -Wall -Wextra -Wno-unused-parameter -Werror") + set(COMMON_FLAGS "-Wall -Wextra -Werror -pedantic -Wno-unused-parameter") + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${COMMON_FLAGS}") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${COMMON_FLAGS} -std=c++17 -fno-rtti -fno-strict-aliasing") if(SUPPORTS_FVISIBILITY_INLINES_HIDDEN_FLAG) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fvisibility-inlines-hidden") endif() diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.7.0+git.20230331.62a7391/clang_delta/CMakeLists.txt new/cvise-2.7.0+git.20230417.6b558fe/clang_delta/CMakeLists.txt --- old/cvise-2.7.0+git.20230331.62a7391/clang_delta/CMakeLists.txt 2023-03-31 16:04:45.000000000 +0200 +++ new/cvise-2.7.0+git.20230417.6b558fe/clang_delta/CMakeLists.txt 2023-04-17 10:51:36.000000000 +0200 @@ -259,6 +259,7 @@ "/tests/remove-unused-function/template2.output" "/tests/remove-unused-function/unused-funcs.cc" "/tests/remove-unused-function/unused-funcs.output" + "/tests/remove-unused-function/cyclic-namespace-using.cc" "/tests/remove-unused-var/struct1.c" "/tests/remove-unused-var/struct1.output" "/tests/remove-unused-var/struct2.c" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.7.0+git.20230331.62a7391/clang_delta/RemoveUnusedFunction.cpp new/cvise-2.7.0+git.20230417.6b558fe/clang_delta/RemoveUnusedFunction.cpp --- old/cvise-2.7.0+git.20230331.62a7391/clang_delta/RemoveUnusedFunction.cpp 2023-03-31 16:04:45.000000000 +0200 +++ new/cvise-2.7.0+git.20230417.6b558fe/clang_delta/RemoveUnusedFunction.cpp 2023-04-17 10:51:36.000000000 +0200 @@ -699,10 +699,18 @@ const FunctionDecl * RemoveUnusedFunction::lookupFunctionDeclShallow(const DeclarationName &DName, - const DeclContext *Ctx) + const DeclContext *Ctx, + std::unordered_set<const DeclContext *> &SeenDecls) { if (dyn_cast<LinkageSpecDecl>(Ctx)) return NULL; + + if (SeenDecls.find(Ctx) != SeenDecls.end()) + return NULL; + else + SeenDecls.insert(Ctx); + + DeclContext::lookup_result Result = Ctx->lookup(DName); for (auto I = Result.begin(), E = Result.end(); I != E; ++I) { @@ -726,7 +734,7 @@ ND->getLookupParent() == Ctx) { return NULL; } - if (const FunctionDecl *FD = lookupFunctionDeclShallow(DName, ND)) + if (const FunctionDecl *FD = lookupFunctionDeclShallow(DName, ND, SeenDecls)) return FD; } return NULL; @@ -735,19 +743,23 @@ const FunctionDecl *RemoveUnusedFunction::getFunctionDeclFromSpecifier( const DeclarationName &Name, const NestedNameSpecifier *NNS) { + std::unordered_set<const DeclContext *> seenDeclarations; const FunctionDecl *FD = NULL; switch (NNS->getKind()) { case NestedNameSpecifier::Namespace: FD = lookupFunctionDeclShallow(Name, - NNS->getAsNamespace()); + NNS->getAsNamespace(), + seenDeclarations); break; case NestedNameSpecifier::NamespaceAlias: FD = lookupFunctionDeclShallow(Name, - NNS->getAsNamespaceAlias()->getNamespace()); + NNS->getAsNamespaceAlias()->getNamespace(), + seenDeclarations); break; case NestedNameSpecifier::Global: FD = lookupFunctionDeclShallow(Name, - Context->getTranslationUnitDecl()); + Context->getTranslationUnitDecl(), + seenDeclarations); break; default: return NULL; @@ -841,7 +853,8 @@ } else { const DeclContext *Ctx = CurrentFD->getLookupParent(); - FD = lookupFunctionDeclShallow(DName, Ctx); + std::unordered_set<const DeclContext *> seenDeclarations; + FD = lookupFunctionDeclShallow(DName, Ctx, seenDeclarations); } if (!FD || FD->isReferenced()) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.7.0+git.20230331.62a7391/clang_delta/RemoveUnusedFunction.h new/cvise-2.7.0+git.20230417.6b558fe/clang_delta/RemoveUnusedFunction.h --- old/cvise-2.7.0+git.20230331.62a7391/clang_delta/RemoveUnusedFunction.h 2023-03-31 16:04:45.000000000 +0200 +++ new/cvise-2.7.0+git.20230417.6b558fe/clang_delta/RemoveUnusedFunction.h 2023-04-17 10:51:36.000000000 +0200 @@ -14,6 +14,7 @@ #include <string> #include <map> #include <set> +#include <unordered_set> #include "llvm/ADT/DenseMap.h" #include "llvm/ADT/SmallPtrSet.h" #include "llvm/ADT/SmallSet.h" @@ -141,7 +142,8 @@ const clang::FunctionDecl *lookupFunctionDeclShallow( const clang::DeclarationName &DName, - const clang::DeclContext *Ctx); + const clang::DeclContext *Ctx, + std::unordered_set<const clang::DeclContext *> &SeenDecls); const clang::FunctionDecl *getFunctionDeclFromSpecifier( const clang::DeclarationName &Name, diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.7.0+git.20230331.62a7391/clang_delta/tests/remove-unused-function/cyclic-namespace-using.cc new/cvise-2.7.0+git.20230417.6b558fe/clang_delta/tests/remove-unused-function/cyclic-namespace-using.cc --- old/cvise-2.7.0+git.20230331.62a7391/clang_delta/tests/remove-unused-function/cyclic-namespace-using.cc 1970-01-01 01:00:00.000000000 +0100 +++ new/cvise-2.7.0+git.20230417.6b558fe/clang_delta/tests/remove-unused-function/cyclic-namespace-using.cc 2023-04-17 10:51:36.000000000 +0200 @@ -0,0 +1,13 @@ +namespace Kernel { + class TermList; +} + +using Kernel::TermList; + +namespace Shell { + using namespace Kernel; +} + +namespace Kernel { + using namespace Shell; +} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.7.0+git.20230331.62a7391/clang_delta/tests/test_clang_delta.py new/cvise-2.7.0+git.20230417.6b558fe/clang_delta/tests/test_clang_delta.py --- old/cvise-2.7.0+git.20230331.62a7391/clang_delta/tests/test_clang_delta.py 2023-03-31 16:04:45.000000000 +0200 +++ new/cvise-2.7.0+git.20230417.6b558fe/clang_delta/tests/test_clang_delta.py 2023-04-17 10:51:36.000000000 +0200 @@ -359,6 +359,10 @@ def test_remove_unused_function_unused_funcs(self): self.check_clang_delta('remove-unused-function/unused-funcs.cc', '--transformation=remove-unused-function --counter=1') + def test_remove_unused_function_cyclic_ns_include(self): + self.check_query_instances('remove-unused-function/cyclic-namespace-using.cc', '--query-instances=remove-unused-function', + 'Available transformation instances: 0') + def test_remove_unused_var_struct1(self): self.check_clang_delta('remove-unused-var/struct1.c', '--transformation=remove-unused-var --counter=1') diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.7.0+git.20230331.62a7391/cvise/passes/abstract.py new/cvise-2.7.0+git.20230417.6b558fe/cvise/passes/abstract.py --- old/cvise-2.7.0+git.20230331.62a7391/cvise/passes/abstract.py 2023-03-31 16:04:45.000000000 +0200 +++ new/cvise-2.7.0+git.20230417.6b558fe/cvise/passes/abstract.py 2023-04-17 10:51:36.000000000 +0200 @@ -18,7 +18,7 @@ pass def __repr__(self): - return 'BinaryState: %d-%d of %d instances' % (self.index, self.end(), self.instances) + return f'BinaryState({self.index}-{self.end()}, {self.instances} instances, step: {self.chunk})' @staticmethod def create(instances): @@ -41,7 +41,6 @@ def advance(self): self = self.copy() - original_index = self.index self.index += self.chunk if self.index >= self.instances: self.chunk = int(self.chunk / 2) @@ -50,7 +49,7 @@ logging.debug(f'granularity reduced to {self.chunk}') self.index = 0 else: - logging.debug(f'***ADVANCE*** from {original_index} to {self.index} with chunk {self.chunk}') + logging.debug(f'***ADVANCE*** to {self}') return self def advance_on_success(self, instances): @@ -80,7 +79,7 @@ name = f'{type(self).__name__}' if self.max_transforms is not None: - name += f' ({self.max_transforms} transforms)' + name += f' ({self.max_transforms} T)' return name def check_external_program(self, name): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.7.0+git.20230331.62a7391/cvise/passes/clangbinarysearch.py new/cvise-2.7.0+git.20230417.6b558fe/cvise/passes/clangbinarysearch.py --- old/cvise-2.7.0+git.20230331.62a7391/cvise/passes/clangbinarysearch.py 2023-03-31 16:04:45.000000000 +0200 +++ new/cvise-2.7.0+git.20230417.6b558fe/cvise/passes/clangbinarysearch.py 2023-04-17 10:51:36.000000000 +0200 @@ -88,7 +88,7 @@ pass def transform(self, test_case, state, process_event_notifier): - logging.debug(f'TRANSFORM: index = {state.index}, chunk = {state.chunk}, instances = {state.instances}') + logging.debug(f'TRANSFORM: {state}') tmp = os.path.dirname(test_case) with tempfile.NamedTemporaryFile(mode='w', delete=False, dir=tmp) as tmp_file: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.7.0+git.20230331.62a7391/cvise.py new/cvise-2.7.0+git.20230417.6b558fe/cvise.py --- old/cvise-2.7.0+git.20230331.62a7391/cvise.py 2023-03-31 16:04:45.000000000 +0200 +++ new/cvise-2.7.0+git.20230417.6b558fe/cvise.py 2023-04-17 10:51:36.000000000 +0200 @@ -316,11 +316,11 @@ else: time_stop = time.monotonic() print('===< PASS statistics >===') - print(' %-54s %8s %8s %8s %8s %15s' % ('pass name', 'time (s)', 'time (%)', 'worked', + print(' %-60s %8s %8s %8s %8s %15s' % ('pass name', 'time (s)', 'time (%)', 'worked', 'failed', 'total executed')) for pass_name, pass_data in pass_statistic.sorted_results: - print(' %-54s %8.2f %8.2f %8d %8d %15d' % (pass_name, pass_data.total_seconds, + print(' %-60s %8.2f %8.2f %8d %8d %15d' % (pass_name, pass_data.total_seconds, 100.0 * pass_data.total_seconds / (time_stop - time_start), pass_data.worked, pass_data.failed, pass_data.totally_executed)) print() diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.7.0+git.20230331.62a7391/delta/topformflat.l new/cvise-2.7.0+git.20230417.6b558fe/delta/topformflat.l --- old/cvise-2.7.0+git.20230331.62a7391/delta/topformflat.l 2023-03-31 16:04:45.000000000 +0200 +++ new/cvise-2.7.0+git.20230417.6b558fe/delta/topformflat.l 2023-04-17 10:51:36.000000000 +0200 @@ -9,13 +9,13 @@ #include <stdlib.h> // atoi // emit yytext as-is -void emit(); +void emit(void); // debugging diagnostic, emitted when enabled void diag(char const *str); // add a newline if nesting <= threshold -void possibleNewline(); +void possibleNewline(void); // keep track of brace nesting (0 means not inside any pair) int nesting = 0; @@ -90,7 +90,7 @@ %% -void emit() +void emit(void) { printf("%.*s", (int) yyleng, yytext); } @@ -100,7 +100,7 @@ //printf("%s", str); } -void possibleNewline() +void possibleNewline(void) { if (nesting <= threshold) { printf("\n");