[flang-commits] [flang] [flang] Lower REDUCE intrinsic with no DIM argument and rank 1 (PR #94652)
Valentin Clement バレンタイン クレメン via flang-commits
flang-commits at lists.llvm.org
Mon Jun 10 11:02:00 PDT 2024
clementval wrote:
> I'm seeing compilation errors when I try to build with these changes. I'm building with GCC 9.3.0. Here's an excerpt from the log file:
>
> ```
> [5652/6572] Building CXX object tools/flang/lib/Optimizer/Builder/CMakeFiles/obj.FIRBuilder.dir/Runtime/Exceptions.cpp.o
> FAILED: tools/flang/lib/Optimizer/Builder/CMakeFiles/obj.FIRBuilder.dir/Runtime/Exceptions.cpp.o
> /usr/bin/c++ -DFLANG_INCLUDE_TESTS=1 -DFLANG_LITTLE_ENDIAN=1 -DFLANG_RUNTIME_F128_MATH_LIB=\"libquadmath\" -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/local/home/psteinfeld/main/valentin/build/tools/flang/lib/Optimizer/Builder -I/local/home/psteinfeld/main/valentin/llvm-project/flang/lib/Optimizer/Builder -I/local/home/psteinfeld/main/valentin/llvm-project/flang/include -I/local/home/psteinfeld/main/valentin/build/tools/flang/include -I/local/home/psteinfeld/main/valentin/build/include -I/local/home/psteinfeld/main/valentin/llvm-project/llvm/include -isystem /local/home/psteinfeld/main/valentin/llvm-project/llvm/../mlir/include -isystem /local/home/psteinfeld/main/valentin/build/tools/mlir/include -isystem /local/home/psteinfeld/main/valentin/build/tools/clang/include -isystem /local/home/psteinfeld/main/valentin/llvm-project/llvm/../clang/include -fPIC -fno-semantic-interposition -fvisibility-inlines-hidden -Werror=date-time -fno-lifetime-dse -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -pedantic -Wno-long-long -Wimplicit-fallthrough -Wno-uninitialized -Wno-nonnull -Wno-class-memaccess -Wno-noexcept-type -Wdelete-non-virtual-dtor -Wno-comment -Wno-misleading-indentation -fdiagnostics-color -ffunction-sections -fdata-sections -Wno-deprecated-copy -Wno-ctad-maybe-unsupported -fno-strict-aliasing -fno-semantic-interposition -O3 -DNDEBUG -std=c++17 -fno-exceptions -funwind-tables -fno-rtti -UNDEBUG -MD -MT tools/flang/lib/Optimizer/Builder/CMakeFiles/obj.FIRBuilder.dir/Runtime/Exceptions.cpp.o -MF tools/flang/lib/Optimizer/Builder/CMakeFiles/obj.FIRBuilder.dir/Runtime/Exceptions.cpp.o.d -o tools/flang/lib/Optimizer/Builder/CMakeFiles/obj.FIRBuilder.dir/Runtime/Exceptions.cpp.o -c /local/home/psteinfeld/main/valentin/llvm-project/flang/lib/Optimizer/Builder/Runtime/Exceptions.cpp
> In file included from /local/home/psteinfeld/main/valentin/llvm-project/flang/lib/Optimizer/Builder/Runtime/Exceptions.cpp:11:
> /local/home/psteinfeld/main/valentin/llvm-project/flang/include/flang/Optimizer/Builder/Runtime/RTBuilder.h:306:27: error: redefinition of ‘constexpr mlir::Type (* fir::runtime::getModel())(mlir::MLIRContext*) [with T = long int; fir::runtime::TypeBuilderFunc = mlir::Type (*)(mlir::MLIRContext*)]’
> constexpr TypeBuilderFunc getModel<std::int64_t>() {
> ^~~~~~~~~~~~~~~~~~~~~~
> /local/home/psteinfeld/main/valentin/llvm-project/flang/include/flang/Optimizer/Builder/Runtime/RTBuilder.h:248:27: note: ‘constexpr mlir::Type (* fir::runtime::getModel())(mlir::MLIRContext*) [with T = long int; fir::runtime::TypeBuilderFunc = mlir::Type (*)(mlir::MLIRContext*)]’ previously declared here
> constexpr TypeBuilderFunc getModel<long>() {
> ^~~~~~~~~~~~~~
> /local/home/psteinfeld/main/valentin/llvm-project/flang/include/flang/Optimizer/Builder/Runtime/RTBuilder.h:312:27: error: redefinition of ‘constexpr mlir::Type (* fir::runtime::getModel())(mlir::MLIRContext*) [with T = const long int*; fir::runtime::TypeBuilderFunc = mlir::Type (*)(mlir::MLIRContext*)]’
> constexpr TypeBuilderFunc getModel<const std::int64_t *>() {
> ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> /local/home/psteinfeld/main/valentin/llvm-project/flang/include/flang/Optimizer/Builder/Runtime/RTBuilder.h:265:27: note: ‘constexpr mlir::Type (* fir::runtime::getModel())(mlir::MLIRContext*) [with T = const long int*; fir::runtime::TypeBuilderFunc = mlir::Type (*)(mlir::MLIRContext*)]’ previously declared here
> constexpr TypeBuilderFunc getModel<const long *>() {
> ^~~~~~~~~~~~~~~~~~~~~~
> ```
Just removed it.
https://github.com/llvm/llvm-project/pull/94652
More information about the flang-commits
mailing list