[llvm] [ADT] Make set_subtract more efficient when subtrahend is larger (NFC) (PR #98702)
LLVM Continuous Integration via llvm-commits
llvm-commits at lists.llvm.org
Wed Jul 17 13:58:40 PDT 2024
llvm-ci wrote:
LLVM Buildbot has detected a new failure on builder `ppc64le-mlir-rhel-clang` running on `ppc64le-mlir-rhel-test` while building `llvm` at step 5 "build-check-mlir-build-only".
Full details are available at: https://lab.llvm.org/buildbot/#/builders/129/builds/2094
Here is the relevant piece of the build log for the reference:
```
Step 5 (build-check-mlir-build-only) failure: build (failure)
...
77.730 [334/98/3553] Building CXX object lib/Analysis/CMakeFiles/LLVMAnalysis.dir/MustExecute.cpp.o
77.845 [334/97/3554] Building CXX object lib/Transforms/Vectorize/CMakeFiles/LLVMVectorize.dir/VPlanHCFGBuilder.cpp.o
77.878 [334/96/3555] Building CXX object lib/CodeGen/CMakeFiles/LLVMCodeGen.dir/SafeStack.cpp.o
78.297 [334/95/3556] Building CXX object lib/CodeGen/CMakeFiles/LLVMCodeGen.dir/SelectOptimize.cpp.o
78.389 [334/94/3557] Building CXX object lib/Transforms/Utils/CMakeFiles/LLVMTransformUtils.dir/LoopUnrollAndJam.cpp.o
78.527 [334/93/3558] Building CXX object lib/Analysis/CMakeFiles/LLVMAnalysis.dir/RegionInfo.cpp.o
78.655 [334/92/3559] Building CXX object lib/Transforms/Scalar/CMakeFiles/LLVMScalarOpts.dir/IndVarSimplify.cpp.o
78.868 [334/91/3560] Building CXX object lib/Analysis/CMakeFiles/LLVMAnalysis.dir/DependenceAnalysis.cpp.o
79.046 [334/90/3561] Building CXX object lib/Transforms/Utils/CMakeFiles/LLVMTransformUtils.dir/SimplifyIndVar.cpp.o
79.229 [334/89/3562] Building CXX object tools/mlir/lib/Dialect/Bufferization/Transforms/CMakeFiles/obj.MLIRBufferizationTransforms.dir/BufferViewFlowAnalysis.cpp.o
FAILED: tools/mlir/lib/Dialect/Bufferization/Transforms/CMakeFiles/obj.MLIRBufferizationTransforms.dir/BufferViewFlowAnalysis.cpp.o
ccache /home/buildbots/llvm-external-buildbots/clang.16.0.1/bin/clang++ -DGTEST_HAS_RTTI=0 -D_DEBUG -D_GLIBCXX_ASSERTIONS -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/build/tools/mlir/lib/Dialect/Bufferization/Transforms -I/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/mlir/lib/Dialect/Bufferization/Transforms -I/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/build/include -I/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/llvm/include -I/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/mlir/include -I/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/build/tools/mlir/include -fPIC -fno-semantic-interposition -fvisibility-inlines-hidden -Werror=date-time -Werror=unguarded-availability-new -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers -pedantic -Wno-long-long -Wc++98-compat-extra-semi -Wimplicit-fallthrough -Wcovered-switch-default -Wno-noexcept-type -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -Wsuggest-override -Wstring-conversion -Wmisleading-indentation -Wctad-maybe-unsupported -fdiagnostics-color -ffunction-sections -fdata-sections -Wundef -Werror=mismatched-tags -Werror=global-constructors -O3 -DNDEBUG -std=c++17 -fno-exceptions -funwind-tables -fno-rtti -UNDEBUG -MD -MT tools/mlir/lib/Dialect/Bufferization/Transforms/CMakeFiles/obj.MLIRBufferizationTransforms.dir/BufferViewFlowAnalysis.cpp.o -MF tools/mlir/lib/Dialect/Bufferization/Transforms/CMakeFiles/obj.MLIRBufferizationTransforms.dir/BufferViewFlowAnalysis.cpp.o.d -o tools/mlir/lib/Dialect/Bufferization/Transforms/CMakeFiles/obj.MLIRBufferizationTransforms.dir/BufferViewFlowAnalysis.cpp.o -c /home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/mlir/lib/Dialect/Bufferization/Transforms/BufferViewFlowAnalysis.cpp
In file included from /home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/mlir/lib/Dialect/Bufferization/Transforms/BufferViewFlowAnalysis.cpp:16:
/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/llvm/include/llvm/ADT/SetOperations.h:109:20: error: no viable conversion from 'typename SmallPtrSet<Value, 16>::iterator' (aka 'SmallPtrSetIterator<mlir::Value>') to 'mlir::Value'
S1.erase(SI);
^~
/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/mlir/lib/Dialect/Bufferization/Transforms/BufferViewFlowAnalysis.cpp:63:11: note: in instantiation of function template specialization 'llvm::set_subtract<llvm::SmallPtrSet<mlir::Value, 16>, llvm::SetVector<mlir::Value, llvm::SmallVector<mlir::Value, 0>, llvm::DenseSet<mlir::Value, llvm::DenseMapInfo<mlir::Value>>, 0>>' requested here
llvm::set_subtract(entry.second, aliasValues);
^
/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/mlir/include/mlir/IR/Value.h:96:7: note: candidate constructor (the implicit copy constructor) not viable: no known conversion from 'typename SmallPtrSet<Value, 16>::iterator' (aka 'SmallPtrSetIterator<mlir::Value>') to 'const Value &' for 1st argument
class Value {
^
/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/mlir/include/mlir/IR/Value.h:96:7: note: candidate constructor (the implicit move constructor) not viable: no known conversion from 'typename SmallPtrSet<Value, 16>::iterator' (aka 'SmallPtrSetIterator<mlir::Value>') to 'Value &&' for 1st argument
/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/mlir/include/mlir/IR/Value.h:98:13: note: candidate constructor not viable: no known conversion from 'typename SmallPtrSet<Value, 16>::iterator' (aka 'SmallPtrSetIterator<mlir::Value>') to 'detail::ValueImpl *' for 1st argument
constexpr Value(detail::ValueImpl *impl = nullptr) : impl(impl) {}
^
/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/llvm/include/llvm/ADT/SmallPtrSet.h:361:22: note: passing argument to parameter 'Ptr' here
bool erase(PtrType Ptr) {
^
1 error generated.
79.249 [334/88/3563] Building CXX object tools/mlir/lib/Analysis/CMakeFiles/obj.MLIRAnalysis.dir/Liveness.cpp.o
FAILED: tools/mlir/lib/Analysis/CMakeFiles/obj.MLIRAnalysis.dir/Liveness.cpp.o
ccache /home/buildbots/llvm-external-buildbots/clang.16.0.1/bin/clang++ -DGTEST_HAS_RTTI=0 -D_DEBUG -D_GLIBCXX_ASSERTIONS -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/build/tools/mlir/lib/Analysis -I/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/mlir/lib/Analysis -I/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/build/include -I/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/llvm/include -I/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/mlir/include -I/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/build/tools/mlir/include -fPIC -fno-semantic-interposition -fvisibility-inlines-hidden -Werror=date-time -Werror=unguarded-availability-new -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers -pedantic -Wno-long-long -Wc++98-compat-extra-semi -Wimplicit-fallthrough -Wcovered-switch-default -Wno-noexcept-type -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -Wsuggest-override -Wstring-conversion -Wmisleading-indentation -Wctad-maybe-unsupported -fdiagnostics-color -ffunction-sections -fdata-sections -Wundef -Werror=mismatched-tags -Werror=global-constructors -O3 -DNDEBUG -std=c++17 -fno-exceptions -funwind-tables -fno-rtti -UNDEBUG -MD -MT tools/mlir/lib/Analysis/CMakeFiles/obj.MLIRAnalysis.dir/Liveness.cpp.o -MF tools/mlir/lib/Analysis/CMakeFiles/obj.MLIRAnalysis.dir/Liveness.cpp.o.d -o tools/mlir/lib/Analysis/CMakeFiles/obj.MLIRAnalysis.dir/Liveness.cpp.o -c /home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/mlir/lib/Analysis/Liveness.cpp
In file included from /home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/mlir/lib/Analysis/Liveness.cpp:19:
/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/llvm/include/llvm/ADT/SetOperations.h:109:20: error: no viable conversion from 'typename SmallPtrSet<Value, 16>::iterator' (aka 'SmallPtrSetIterator<mlir::Value>') to 'mlir::Value'
S1.erase(SI);
^~
/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/mlir/lib/Analysis/Liveness.cpp:80:11: note: in instantiation of function template specialization 'llvm::set_subtract<llvm::SmallPtrSet<mlir::Value, 16>, llvm::SmallPtrSet<mlir::Value, 16>>' requested here
llvm::set_subtract(useValues, defValues);
^
/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/mlir/include/mlir/IR/Value.h:96:7: note: candidate constructor (the implicit copy constructor) not viable: no known conversion from 'typename SmallPtrSet<Value, 16>::iterator' (aka 'SmallPtrSetIterator<mlir::Value>') to 'const Value &' for 1st argument
class Value {
^
/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/mlir/include/mlir/IR/Value.h:96:7: note: candidate constructor (the implicit move constructor) not viable: no known conversion from 'typename SmallPtrSet<Value, 16>::iterator' (aka 'SmallPtrSetIterator<mlir::Value>') to 'Value &&' for 1st argument
/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/mlir/include/mlir/IR/Value.h:98:13: note: candidate constructor not viable: no known conversion from 'typename SmallPtrSet<Value, 16>::iterator' (aka 'SmallPtrSetIterator<mlir::Value>') to 'detail::ValueImpl *' for 1st argument
constexpr Value(detail::ValueImpl *impl = nullptr) : impl(impl) {}
^
/home/buildbots/llvm-external-buildbots/workers/ppc64le-mlir-rhel-test/ppc64le-mlir-rhel-clang-build/llvm-project/llvm/include/llvm/ADT/SmallPtrSet.h:361:22: note: passing argument to parameter 'Ptr' here
bool erase(PtrType Ptr) {
```
https://github.com/llvm/llvm-project/pull/98702
More information about the llvm-commits
mailing list