[llvm] Add a pass to collect dropped var stats for MIR. (PR #115566)

LLVM Continuous Integration via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 18 16:01:54 PST 2024


llvm-ci wrote:

LLVM Buildbot has detected a new failure on builder `llvm-clang-x86_64-sie-ubuntu-fast` running on `sie-linux-worker` while building `llvm` at step 6 "test-build-unified-tree-check-all".

Full details are available at: https://lab.llvm.org/buildbot/#/builders/144/builds/11922

<details>
<summary>Here is the relevant piece of the build log for the reference</summary>

```
Step 6 (test-build-unified-tree-check-all) failure: test (failure)
...
22.077 [9/22/1003] Building CXX object unittests/CodeGen/CMakeFiles/CodeGenTests.dir/MachineInstrTest.cpp.o
22.372 [9/21/1004] Linking CXX executable unittests/tools/llvm-mca/LLVMMCATests
22.391 [9/20/1005] Linking CXX executable unittests/Transforms/Scalar/ScalarTests
22.598 [9/19/1006] Building CXX object unittests/CodeGen/GlobalISel/CMakeFiles/GlobalISelTests.dir/PatternMatchTest.cpp.o
22.845 [9/18/1007] Building CXX object unittests/CodeGen/GlobalISel/CMakeFiles/GlobalISelTests.dir/GISelUtilsTest.cpp.o
22.868 [9/17/1008] Linking CXX executable unittests/Analysis/AnalysisTests
22.997 [9/16/1009] Building CXX object unittests/CodeGen/GlobalISel/CMakeFiles/GlobalISelTests.dir/KnownBitsVectorTest.cpp.o
23.498 [9/15/1010] Building CXX object unittests/CodeGen/GlobalISel/CMakeFiles/GlobalISelTests.dir/KnownBitsTest.cpp.o
24.032 [9/14/1011] Building CXX object unittests/IR/CMakeFiles/IRTests.dir/DroppedVariableStatsIRTest.cpp.o
24.918 [9/13/1012] Building CXX object unittests/MIR/CMakeFiles/MIRTests.dir/DroppedVariableStatsMIRTest.cpp.o
FAILED: unittests/MIR/CMakeFiles/MIRTests.dir/DroppedVariableStatsMIRTest.cpp.o 
CCACHE_CPP2=yes CCACHE_HASHDIR=yes /usr/bin/ccache /usr/bin/g++ -DGTEST_HAS_RTTI=0 -DLLVM_BUILD_STATIC -D_DEBUG -D_GLIBCXX_ASSERTIONS -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/build/unittests/MIR -I/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/llvm-project/llvm/unittests/MIR -I/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/build/include -I/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/llvm-project/llvm/include -I/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/llvm-project/third-party/unittest/googletest/include -I/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/llvm-project/third-party/unittest/googlemock/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-redundant-move -Wno-pessimizing-move -Wno-noexcept-type -Wdelete-non-virtual-dtor -Wsuggest-override -Wno-comment -Wno-misleading-indentation -Wctad-maybe-unsupported -fdiagnostics-color -ffunction-sections -fdata-sections -O3 -DNDEBUG  -Wno-dangling-else -Wno-variadic-macros -fno-exceptions -funwind-tables -fno-rtti -UNDEBUG -Wno-suggest-override -std=c++17 -MD -MT unittests/MIR/CMakeFiles/MIRTests.dir/DroppedVariableStatsMIRTest.cpp.o -MF unittests/MIR/CMakeFiles/MIRTests.dir/DroppedVariableStatsMIRTest.cpp.o.d -o unittests/MIR/CMakeFiles/MIRTests.dir/DroppedVariableStatsMIRTest.cpp.o -c /home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/llvm-project/llvm/unittests/MIR/DroppedVariableStatsMIRTest.cpp
/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/llvm-project/llvm/unittests/MIR/DroppedVariableStatsMIRTest.cpp:35:17: error: ‘LLVMTargetMachine’ was not declared in this scope
   35 | std::unique_ptr<LLVMTargetMachine>
      |                 ^~~~~~~~~~~~~~~~~
/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/llvm-project/llvm/unittests/MIR/DroppedVariableStatsMIRTest.cpp:35:34: error: template argument 1 is invalid
   35 | std::unique_ptr<LLVMTargetMachine>
      |                                  ^
/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/llvm-project/llvm/unittests/MIR/DroppedVariableStatsMIRTest.cpp:35:34: error: template argument 2 is invalid
/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/llvm-project/llvm/unittests/MIR/DroppedVariableStatsMIRTest.cpp: In function ‘int {anonymous}::createTargetMachine(std::string, llvm::StringRef, llvm::StringRef)’:
/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/llvm-project/llvm/unittests/MIR/DroppedVariableStatsMIRTest.cpp:40:12: error: cannot convert ‘std::nullptr_t’ to ‘int’ in return
   40 |     return nullptr;
      |            ^~~~~~~
/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/llvm-project/llvm/unittests/MIR/DroppedVariableStatsMIRTest.cpp:42:26: error: ‘LLVMTargetMachine’ was not declared in this scope; did you mean ‘createTargetMachine’?
   42 |   return std::unique_ptr<LLVMTargetMachine>(
      |                          ^~~~~~~~~~~~~~~~~
      |                          createTargetMachine
/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/llvm-project/llvm/unittests/MIR/DroppedVariableStatsMIRTest.cpp:42:43: error: template argument 1 is invalid
   42 |   return std::unique_ptr<LLVMTargetMachine>(
      |                                           ^
/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/llvm-project/llvm/unittests/MIR/DroppedVariableStatsMIRTest.cpp:42:43: error: template argument 2 is invalid
/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/llvm-project/llvm/unittests/MIR/DroppedVariableStatsMIRTest.cpp:43:19: error: ‘LLVMTargetMachine’ does not name a type
   43 |       static_cast<LLVMTargetMachine *>(T->createTargetMachine(
      |                   ^~~~~~~~~~~~~~~~~
/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/llvm-project/llvm/unittests/MIR/DroppedVariableStatsMIRTest.cpp:43:37: error: expected ‘>’ before ‘*’ token
   43 |       static_cast<LLVMTargetMachine *>(T->createTargetMachine(
      |                                     ^
/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/llvm-project/llvm/unittests/MIR/DroppedVariableStatsMIRTest.cpp:43:37: error: expected ‘(’ before ‘*’ token
   43 |       static_cast<LLVMTargetMachine *>(T->createTargetMachine(
      |                                     ^
      |                                     (
/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/llvm-project/llvm/unittests/MIR/DroppedVariableStatsMIRTest.cpp:43:38: error: expected primary-expression before ‘>’ token
   43 |       static_cast<LLVMTargetMachine *>(T->createTargetMachine(
      |                                      ^
/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/llvm-project/llvm/unittests/MIR/DroppedVariableStatsMIRTest.cpp: In member function ‘virtual void {anonymous}::DroppedVariableStatsMIR_BothDeleted_Test::TestBody()’:
/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/llvm-project/llvm/unittests/MIR/DroppedVariableStatsMIRTest.cpp:185:28: error: request for member ‘get’ in ‘TM’, which is of non-class type ‘int’
  185 |   MachineModuleInfo MMI(TM.get());
      |                            ^~~
/home/buildbot/buildbot-root/llvm-clang-x86_64-sie-ubuntu-fast/llvm-project/llvm/unittests/MIR/DroppedVariableStatsMIRTest.cpp:186:40: error: invalid type argument of unary ‘*’ (have ‘int’)

```

</details>

https://github.com/llvm/llvm-project/pull/115566


More information about the llvm-commits mailing list