[llvm] [mlir] Introduce LDBG_OS() macro as a variant of LDBG() (#157194) (PR #158260)

LLVM Continuous Integration via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 12 03:33:37 PDT 2025


llvm-ci wrote:

LLVM Buildbot has detected a new failure on builder `llvm-clang-aarch64-darwin` running on `doug-worker-4` while building `llvm,mlir` at step 5 "build-unified-tree".

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

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

```
Step 5 (build-unified-tree) failure: build (failure)
...
1175.549 [461/8/5776] Building CXX object unittests/Support/CMakeFiles/SupportTests.dir/DJBTest.cpp.o
1175.565 [460/8/5777] Building CXX object unittests/Support/CMakeFiles/SupportTests.dir/EndianStreamTest.cpp.o
1175.577 [459/8/5778] Building CXX object unittests/Support/CMakeFiles/SupportTests.dir/EndianTest.cpp.o
1175.778 [458/8/5779] Building CXX object unittests/Support/CMakeFiles/SupportTests.dir/CSKYAttributeParserTest.cpp.o
1175.791 [457/8/5780] Building CXX object unittests/Support/CMakeFiles/SupportTests.dir/ErrnoTest.cpp.o
1175.803 [456/8/5781] Building CXX object unittests/Support/CMakeFiles/SupportTests.dir/ErrorOrTest.cpp.o
1176.021 [455/8/5782] Building CXX object unittests/Support/CMakeFiles/SupportTests.dir/DebugCounterTest.cpp.o
1176.122 [454/8/5783] Building CXX object unittests/Support/CMakeFiles/SupportTests.dir/DebugTest.cpp.o
1176.135 [453/8/5784] Building CXX object unittests/Support/CMakeFiles/SupportTests.dir/ExtensibleRTTITest.cpp.o
1176.157 [452/8/5785] Building CXX object unittests/Support/CMakeFiles/SupportTests.dir/DebugLogTest.cpp.o
FAILED: [code=1] unittests/Support/CMakeFiles/SupportTests.dir/DebugLogTest.cpp.o 
CCACHE_CPP2=yes CCACHE_HASHDIR=yes CCACHE_SLOPPINESS=pch_defines,time_macros /opt/homebrew/bin/ccache /usr/bin/clang++ -DGTEST_HAS_RTTI=0 -DLLVM_BUILD_STATIC -D_DEBUG -D_GLIBCXX_ASSERTIONS -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -I/Users/buildbot/buildbot-root/aarch64-darwin/build/unittests/Support -I/Users/buildbot/buildbot-root/aarch64-darwin/llvm-project/llvm/unittests/Support -I/Users/buildbot/buildbot-root/aarch64-darwin/build/include -I/Users/buildbot/buildbot-root/aarch64-darwin/llvm-project/llvm/include -I/Users/buildbot/buildbot-root/aarch64-darwin/llvm-project/third-party/unittest/googletest/include -I/Users/buildbot/buildbot-root/aarch64-darwin/llvm-project/third-party/unittest/googlemock/include -isystem /opt/homebrew/include -fPIC -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 -O3 -DNDEBUG -std=c++17 -arch arm64 -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX14.4.sdk  -Wno-variadic-macros -Wno-gnu-zero-variadic-macro-arguments -fno-exceptions -funwind-tables -fno-rtti -UNDEBUG -Wno-suggest-override -MD -MT unittests/Support/CMakeFiles/SupportTests.dir/DebugLogTest.cpp.o -MF unittests/Support/CMakeFiles/SupportTests.dir/DebugLogTest.cpp.o.d -o unittests/Support/CMakeFiles/SupportTests.dir/DebugLogTest.cpp.o -c /Users/buildbot/buildbot-root/aarch64-darwin/llvm-project/llvm/unittests/Support/DebugLogTest.cpp
/Users/buildbot/buildbot-root/aarch64-darwin/llvm-project/llvm/unittests/Support/DebugLogTest.cpp:143:3: error: static assertion failed: DEBUG_TYPE is not defined
  LDBG() << "Hello, world!";
  ^~~~~~
/Users/buildbot/buildbot-root/aarch64-darwin/llvm-project/llvm/include/llvm/Support/DebugLog.h:50:19: note: expanded from macro 'LDBG'
#define LDBG(...) _GET_LDBG_MACRO(__VA_ARGS__)(__VA_ARGS__)
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/buildbot/buildbot-root/aarch64-darwin/llvm-project/llvm/include/llvm/Support/DebugLog.h:102:30: note: expanded from macro '_GET_LDBG_MACRO'
  LDBG_CHOOSE_FROM_ARG_COUNT(LDBG_NO_ARG_EXPANDER __VA_ARGS__())
                             ^
/Users/buildbot/buildbot-root/aarch64-darwin/llvm-project/llvm/include/llvm/Support/DebugLog.h:100:36: note: expanded from macro 'LDBG_NO_ARG_EXPANDER'
#define LDBG_NO_ARG_EXPANDER() , , LDBG_NO_ARG
                                   ^
note: (skipping 7 expansions in backtrace; use -fmacro-backtrace-limit=0 to see all)
/Users/buildbot/buildbot-root/aarch64-darwin/llvm-project/llvm/include/llvm/Support/DebugLog.h:124:58: note: expanded from macro 'LDGB_STREAM_LEVEL_AND_TYPE'
  LDBG_STREAM_LEVEL_TYPE_AND_FILE(STREAM, LEVEL_OR_TYPE, TYPE_OR_LEVEL,        \
                                                         ^~~~~~~~~~~~~
/Users/buildbot/buildbot-root/aarch64-darwin/llvm-project/llvm/include/llvm/Support/DebugLog.h:121:63: note: expanded from macro 'LDBG_STREAM_LEVEL_TYPE_AND_FILE'
  LDBG_STREAM_LEVEL_TYPE_FILE_AND_LINE(STREAM, LEVEL_OR_TYPE, TYPE_OR_LEVEL,   \
                                                              ^~~~~~~~~~~~~
/Users/buildbot/buildbot-root/aarch64-darwin/llvm-project/llvm/include/llvm/Support/DebugLog.h:109:43: note: expanded from macro 'LDBG_STREAM_LEVEL_TYPE_FILE_AND_LINE'
                                          TYPE_OR_LEVEL, LEVEL_OR_TYPE);       \
                                          ^~~~~~~~~~~~~
/Users/buildbot/buildbot-root/aarch64-darwin/llvm-project/llvm/unittests/Support/DebugLogTest.cpp:143:3: error: static assertion failed: DEBUG_TYPE is not defined
  LDBG() << "Hello, world!";
  ^~~~~~
/Users/buildbot/buildbot-root/aarch64-darwin/llvm-project/llvm/include/llvm/Support/DebugLog.h:50:19: note: expanded from macro 'LDBG'
#define LDBG(...) _GET_LDBG_MACRO(__VA_ARGS__)(__VA_ARGS__)
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/buildbot/buildbot-root/aarch64-darwin/llvm-project/llvm/include/llvm/Support/DebugLog.h:102:30: note: expanded from macro '_GET_LDBG_MACRO'
  LDBG_CHOOSE_FROM_ARG_COUNT(LDBG_NO_ARG_EXPANDER __VA_ARGS__())
                             ^
/Users/buildbot/buildbot-root/aarch64-darwin/llvm-project/llvm/include/llvm/Support/DebugLog.h:100:36: note: expanded from macro 'LDBG_NO_ARG_EXPANDER'
#define LDBG_NO_ARG_EXPANDER() , , LDBG_NO_ARG
                                   ^
note: (skipping 7 expansions in backtrace; use -fmacro-backtrace-limit=0 to see all)
/Users/buildbot/buildbot-root/aarch64-darwin/llvm-project/llvm/include/llvm/Support/DebugLog.h:124:58: note: expanded from macro 'LDGB_STREAM_LEVEL_AND_TYPE'
  LDBG_STREAM_LEVEL_TYPE_AND_FILE(STREAM, LEVEL_OR_TYPE, TYPE_OR_LEVEL,        \

```

</details>

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


More information about the llvm-commits mailing list