[clang] [clang-tools-extra] Fix OOM in FormatDiagnostic (PR #108187)
LLVM Continuous Integration via cfe-commits
cfe-commits at lists.llvm.org
Mon Sep 16 07:43:45 PDT 2024
llvm-ci wrote:
LLVM Buildbot has detected a new failure on builder `openmp-offload-sles-build-only` running on `rocm-worker-hw-04-sles` while building `clang-tools-extra,clang` at step 5 "compile-openmp".
Full details are available at: https://lab.llvm.org/buildbot/#/builders/140/builds/6654
<details>
<summary>Here is the relevant piece of the build log for the reference</summary>
```
Step 5 (compile-openmp) failure: build (failure)
...
^
270.853 [665/32/6236] Building CXX object tools/flang/lib/Optimizer/Builder/CMakeFiles/FIRBuilder.dir/Runtime/ArrayConstructor.cpp.o
270.887 [664/32/6237] Building CXX object tools/flang/lib/Optimizer/Builder/CMakeFiles/FIRBuilder.dir/Runtime/Allocatable.cpp.o
270.888 [663/32/6238] Building CXX object tools/flang/lib/Optimizer/Builder/CMakeFiles/FIRBuilder.dir/Runtime/Intrinsics.cpp.o
270.914 [662/32/6239] Linking CXX static library lib/libclangStaticAnalyzerFrontend.a
270.925 [661/32/6240] Building CXX object tools/flang/lib/Optimizer/Builder/CMakeFiles/FIRBuilder.dir/Runtime/Main.cpp.o
270.926 [660/32/6241] Building CXX object tools/flang/lib/Optimizer/Builder/CMakeFiles/FIRBuilder.dir/Runtime/Numeric.cpp.o
271.099 [659/32/6242] Linking CXX executable bin/clang-import-test
271.115 [658/32/6243] Linking CXX static library lib/libclangFrontendTool.a
271.134 [657/32/6244] Building CXX object tools/flang/lib/Frontend/CMakeFiles/flangFrontend.dir/TextDiagnosticPrinter.cpp.o
FAILED: tools/flang/lib/Frontend/CMakeFiles/flangFrontend.dir/TextDiagnosticPrinter.cpp.o
ccache /usr/bin/c++ -DFLANG_INCLUDE_TESTS=1 -DFLANG_LITTLE_ENDIAN=1 -DGTEST_HAS_RTTI=0 -D_DEBUG -D_GLIBCXX_ASSERTIONS -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -Itools/flang/lib/Frontend -I/home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/flang/lib/Frontend -I/home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/flang/include -Itools/flang/include -Iinclude -I/home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/llvm/include -isystem /home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/llvm/../mlir/include -isystem tools/mlir/include -isystem tools/clang/include -isystem /home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/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-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 -fno-exceptions -funwind-tables -fno-rtti -UNDEBUG -std=c++1z -MD -MT tools/flang/lib/Frontend/CMakeFiles/flangFrontend.dir/TextDiagnosticPrinter.cpp.o -MF tools/flang/lib/Frontend/CMakeFiles/flangFrontend.dir/TextDiagnosticPrinter.cpp.o.d -o tools/flang/lib/Frontend/CMakeFiles/flangFrontend.dir/TextDiagnosticPrinter.cpp.o -c /home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/flang/lib/Frontend/TextDiagnosticPrinter.cpp
/home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/flang/lib/Frontend/TextDiagnosticPrinter.cpp: In function ‘void printRemarkOption(llvm::raw_ostream&, clang::DiagnosticsEngine::Level, const clang::Diagnostic&)’:
/home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/flang/lib/Frontend/TextDiagnosticPrinter.cpp:48:49: error: ‘const class clang::DiagnosticsEngine’ has no member named ‘getFlagValue’
llvm::StringRef optValue = info.getDiags()->getFlagValue();
^~~~~~~~~~~~
At global scope:
cc1plus: warning: unrecognized command line option ‘-Wno-ctad-maybe-unsupported’
cc1plus: warning: unrecognized command line option ‘-Wno-deprecated-copy’
271.315 [657/31/6245] Building CXX object tools/clang/tools/c-index-test/CMakeFiles/c-index-test.dir/core_main.cpp.o
In file included from /home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/clang/include/clang/AST/Type.h:31:0,
from /home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/clang/include/clang/AST/DeclarationName.h:16,
from /home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/clang/include/clang/AST/DeclBase.h:19,
from /home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/clang/include/clang/AST/Decl.h:20,
from /home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/clang/include/clang/AST/Mangle.h:16,
from /home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/clang/tools/c-index-test/core_main.cpp:9:
/home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/clang/include/clang/Basic/PointerAuthOptions.h:70:18: warning: ‘clang::PointerAuthSchema::TheKind’ is too small to hold all values of ‘enum class clang::PointerAuthSchema::Kind’
Kind TheKind : 2;
^
/home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/clang/include/clang/Basic/PointerAuthOptions.h:74:58: warning: ‘clang::PointerAuthSchema::SelectedAuthenticationMode’ is too small to hold all values of ‘enum class clang::PointerAuthenticationMode’
PointerAuthenticationMode SelectedAuthenticationMode : 2;
^
/home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/clang/include/clang/Basic/PointerAuthOptions.h:75:39: warning: ‘clang::PointerAuthSchema::DiscriminationKind’ is too small to hold all values of ‘enum class clang::PointerAuthSchema::Discrimination’
Discrimination DiscriminationKind : 2;
^
271.320 [657/30/6246] Building CXX object tools/flang/lib/Frontend/CMakeFiles/flangFrontend.dir/TextDiagnostic.cpp.o
271.364 [657/29/6247] Linking CXX executable bin/clang-extdef-mapping
271.371 [657/28/6248] Linking CXX executable bin/arcmt-test
271.434 [657/27/6249] Building CXX object tools/clang/tools/libclang/CMakeFiles/libclang.dir/CXString.cpp.o
In file included from /home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/clang/include/clang/AST/Type.h:31:0,
from /home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/clang/include/clang/AST/CanonicalType.h:17,
from /home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/clang/include/clang/AST/ASTContext.h:18,
from /home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/clang/include/clang/Frontend/ASTUnit.h:17,
from /home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/clang/tools/libclang/CXString.cpp:18:
/home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/clang/include/clang/Basic/PointerAuthOptions.h:70:18: warning: ‘clang::PointerAuthSchema::TheKind’ is too small to hold all values of ‘enum class clang::PointerAuthSchema::Kind’
Kind TheKind : 2;
^
/home/botworker/bbot/builds/openmp-offload-sles-build/llvm.src/clang/include/clang/Basic/PointerAuthOptions.h:74:58: warning: ‘clang::PointerAuthSchema::SelectedAuthenticationMode’ is too small to hold all values of ‘enum class clang::PointerAuthenticationMode’
PointerAuthenticationMode SelectedAuthenticationMode : 2;
```
</details>
https://github.com/llvm/llvm-project/pull/108187
More information about the cfe-commits
mailing list