Skip to content

[Fuchsia][cmake] Allow using FatLTO when building runtimes #112277

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

ilovepi
Copy link
Contributor

@ilovepi ilovepi commented Oct 14, 2024

We'd like to build runtimes using FatLTO (see
https://llvm.org/docs/FatLTO.html for details). This gives us more
control over how libc++ can be consumed by users of our toolchain, like
the Fuchsia SDK.

Created using spr 1.3.4
@ilovepi
Copy link
Contributor Author

ilovepi commented Oct 14, 2024

@petrhosek originally I had used a helper function to do add these flags in the libcxx top level cmake, but that didn't work (similar to this

# RTTI flags ==================================================================
). I'm pretty confused why that approach failed, even when use add_flags directly, or appending to the list, vs. doing something here.

Created using spr 1.3.4
Created using spr 1.3.4
Created using spr 1.3.4
@petrhosek
Copy link
Member

Why cannot we just set LLVM_ENABLE_FATLTO in our cache files?

@ilovepi
Copy link
Contributor Author

ilovepi commented Oct 15, 2024

Why cannot we just set LLVM_ENABLE_FATLTO in our cache files?

I don't think we want to couple building libc++ with FATLTO to whether you want to build the compiler that way, do we? Isn't how libc++ built orthogonal to the other build options? Once we have a way to spell that in the build, then yes, we should update the cache file, and we'll probably key that off of LLVM_ENABLE_FATLTO.

But even if we do change the spelling to reuse LLVM_ENABLE_FATLTO, I don't understand is why I couldn't meaningfully change the build flags for libc++ by following the example linked above and adding a call to the new function in cxx_add_common_build_flags(). The fact that I could only get it to work this way seems wrong, and kind of hacky.

@ilovepi
Copy link
Contributor Author

ilovepi commented Oct 15, 2024

I think I understand what you’re asking, now. I had the values default to ON for testing, but I’ll update them to default to OFF, and update the cache file so that they can be on in our build.

@petrhosek
Copy link
Member

We use HandleLLVMOptions in the runtimes build and support existing LLVM options. That's why there's no LIBCXX_USE_SANITIZER (and LIBCXXABI_USE_SANITIZER or LIBUNWIND_USE_SANITIZER), instead we simply reuse LLVM_USE_SANITIZER. That's why LLVM_ENABLE_FATLTO should already work and we shouldn't be introducing new options like LIBCXX_ENABLE_FATLTO.

It should be sufficient to simply set LLVM_ENABLE_FATLTO in the cache file like https://github.com/llvm/llvm-project/blob/e55869ae8a4ef1ae2e898ff5cd66fb8ae6e099b8/clang/cmake/caches/Fuchsia-stage2.cmake and most importantly test that everything is working as expected (and address any issues as needed).

@ilovepi ilovepi requested a review from petrhosek October 16, 2024 18:21
@ilovepi
Copy link
Contributor Author

ilovepi commented Oct 16, 2024

Oh, I finally see what you mean. In the per target runtimes, none of the top level flags get propagated unless you specify them w/ the correct target prefix. I was so confused about why things worked this way.

@ilovepi ilovepi marked this pull request as ready for review October 16, 2024 18:24
@llvmbot llvmbot added the clang Clang issues not falling into any other category label Oct 16, 2024
@llvmbot
Copy link
Member

llvmbot commented Oct 16, 2024

@llvm/pr-subscribers-libcxxabi

@llvm/pr-subscribers-clang

Author: Paul Kirth (ilovepi)

Changes

We'd like to build libc++ using FatLTO (see https://llvm.org/docs/FatLTO.html
for details). This gives us more control over how libc++ can be consumed
by users of our toolchain, like the Fuchsia SDK.


Full diff: https://github.com/llvm/llvm-project/pull/112277.diff

1 Files Affected:

  • (modified) clang/cmake/caches/Fuchsia-stage2.cmake (+8)
diff --git a/clang/cmake/caches/Fuchsia-stage2.cmake b/clang/cmake/caches/Fuchsia-stage2.cmake
index 5af98c7b3b3fba..e62f29ecbe6f45 100644
--- a/clang/cmake/caches/Fuchsia-stage2.cmake
+++ b/clang/cmake/caches/Fuchsia-stage2.cmake
@@ -192,6 +192,10 @@ foreach(target aarch64-unknown-linux-gnu;armv7-unknown-linux-gnueabihf;i386-unkn
     set(RUNTIMES_${target}_LLVM_TOOLS_DIR "${CMAKE_BINARY_DIR}/bin" CACHE BOOL "")
     set(RUNTIMES_${target}_LLVM_ENABLE_RUNTIMES "compiler-rt;libcxx;libcxxabi;libunwind" CACHE STRING "")
 
+    # Enable FatLTO for Linux and baremetal runtimes
+    set(RUNTIMES_${target}_LLVM_ENABLE_LTO ON CACHE BOOL "")
+    set(RUNTIMES_${target}_LLVM_ENABLE_FATLTO ON CACHE BOOL "")
+
     # Use .build-id link.
     list(APPEND RUNTIME_BUILD_ID_LINK "${target}")
   endif()
@@ -274,6 +278,10 @@ if(FUCHSIA_SDK)
     set(RUNTIMES_${target}+asan+noexcept_LIBCXXABI_ENABLE_EXCEPTIONS OFF CACHE BOOL "")
     set(RUNTIMES_${target}+asan+noexcept_LIBCXX_ENABLE_EXCEPTIONS OFF CACHE BOOL "")
 
+    # Enable FatLTO for Fuchsia runtimes
+    set(RUNTIMES_${target}_LLVM_ENABLE_LTO ON CACHE BOOL "")
+    set(RUNTIMES_${target}_LLVM_ENABLE_FATLTO ON CACHE BOOL "")
+
     # Use .build-id link.
     list(APPEND RUNTIME_BUILD_ID_LINK "${target}")
   endforeach()

@ilovepi ilovepi changed the title [libcxx][cmake] Allow using FatLTO in libc++ builds [Fuchsia][cmake] Allow using FatLTO when building runtimes Oct 16, 2024
@ilovepi
Copy link
Contributor Author

ilovepi commented Oct 30, 2024

ping.

@ilovepi
Copy link
Contributor Author

ilovepi commented Oct 31, 2024

I'm now getting an error w/ ToT. Not sure why I'm running into it now, but it happens with any clean build, so its deterministic.

The Relevant bits:

ld.lld: error: input file '/usr/local/google/home/paulkirth/fuchsia-idk/arch/arm64/sysroot/lib/libzircon.so' added after LTO
ld.lld: error: input file '/usr/local/google/home/paulkirth/fuchsia-idk/arch/arm64/sysroot/lib/libzircon.so' added after LTO

Full Error Log:

[1761/1802] Linking CXX shared library /usr/local/google/home/paulkirth/llvm-fork/build/lib/aarch64-unknown-fuchsia/libc++abi.so.1.0
FAILED: /usr/local/google/home/paulkirth/llvm-fork/build/lib/aarch64-unknown-fuchsia/libc++abi.so.1.0
: && /usr/local/google/home/paulkirth/llvm-fork/build/./bin/clang++ --target=aarch64-unknown-fuchsia --sysroot=/usr/local/google/home/paulkirth/fuchsia-idk/arch/arm64/sysroot -fPIC --target=aarch64-unknown-fuchsia -I/usr/local/google/home/paulkirth/fuchsia-idk/pkg/sync/include -I/usr/local/google/home/paulkirth/fuchsia-idk/pkg/fdio/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 -Wimplicit-fallthrough -Wcovered-switch-default -Wno-noexcept-type -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -Wsuggest-override -Wstring-conversion -Wmisleading-indentation -Wctad-maybe-unsupported -ffunction-sections -fdata-sections -flto -ffat-lto-objects  -O2 -g -DNDEBUG  -L/usr/local/google/home/paulkirth/fuchsia-idk/arch/arm64/lib -Wl,-z,defs -fuse-ld=lld -flto -ffat-lto-objects  -nostdlib++ --unwindlib=none -shared -Wl,-soname,libc++abi.so.1 -o /usr/local/google/home/paulkirth/llvm-fork/build/lib/aarch64-unknown-fuchsia/libc++abi.so.1.0 libcxxabi/src/CMakeFiles/cxxabi_shared_objects.dir/cxa_aux_runtime.cpp.obj libcxxabi/src/CMakeFiles/cxxabi_shared_objects.dir/cxa_default_handlers.cpp.obj libcxxabi/src/CMakeFiles/cxxabi_shared_objects.dir/cxa_demangle.cpp.obj libcxxabi/src/CMakeFiles/cxxabi_shared_objects.dir/cxa_exception_storage.cpp.obj libcxxabi/src/CMakeFiles/cxxabi_shared_objects.dir/cxa_guard.cpp.obj libcxxabi/src/CMakeFiles/cxxabi_shared_objects.dir/cxa_handlers.cpp.obj libcxxabi/src/CMakeFiles/cxxabi_shared_objects.dir/cxa_vector.cpp.obj libcxxabi/src/CMakeFiles/cxxabi_shared_objects.dir/cxa_virtual.cpp.obj libcxxabi/src/CMakeFiles/cxxabi_shared_objects.dir/stdlib_exception.cpp.obj libcxxabi/src/CMakeFiles/cxxabi_shared_objects.dir/stdlib_stdexcept.cpp.obj libcxxabi/src/CMakeFiles/cxxabi_shared_objects.dir/stdlib_typeinfo.cpp.obj libcxxabi/src/CMakeFiles/cxxabi_shared_objects.dir/abort_message.cpp.obj libcxxabi/src/CMakeFiles/cxxabi_shared_objects.dir/fallback_malloc.cpp.obj libcxxabi/src/CMakeFiles/cxxabi_shared_objects.dir/private_typeinfo.cpp.obj libcxxabi/src/CMakeFiles/cxxabi_shared_objects.dir/stdlib_new_delete.cpp.obj libcxxabi/src/CMakeFiles/cxxabi_shared_objects.dir/cxa_exception.cpp.obj libcxxabi/src/CMakeFiles/cxxabi_shared_objects.dir/cxa_personality.cpp.obj libcxxabi/src/CMakeFiles/cxxabi_shared_objects.dir/cxa_thread_atexit.cpp.obj  -lc  /usr/local/google/home/paulkirth/llvm-fork/build/lib/aarch64-unknown-fuchsia/libunwind.so.1.0 && :
ld.lld: error: input file '/usr/local/google/home/paulkirth/fuchsia-idk/arch/arm64/sysroot/lib/libzircon.so' added after LTO
ld.lld: error: input file '/usr/local/google/home/paulkirth/fuchsia-idk/arch/arm64/sysroot/lib/libzircon.so' added after LTO
ld.lld: error: undefined symbol: _zx_system_get_features
>>> referenced by fuchsia.inc:9 (/usr/local/google/home/paulkirth/llvm-fork/compiler-rt/lib/builtins/cpu_model/aarch64/lse_atomics/fuchsia.inc:9)
>>>               aarch64.c.obj:(init_have_lse_atomics) in archive /usr/local/google/home/paulkirth/llvm-fork/build/lib/clang/20/lib/aarch64-unknown-fuchsia/libclang_rt.builtins.a
>>> referenced by fuchsia.inc:12 (/usr/local/google/home/paulkirth/llvm-fork/compiler-rt/lib/builtins/cpu_model/aarch64/fmv/fuchsia.inc:12)
>>>               aarch64.c.obj:(__init_cpu_features_resolver) in archive /usr/local/google/home/paulkirth/llvm-fork/build/lib/clang/20/lib/aarch64-unknown-fuchsia/libclang_rt.builtins.a
clang++: error: ld.lld command failed with exit code 1 (use -v to see invocation)
[1763/1802] Building CXX object libcxx/src/CMakeFiles/cxx_static.dir/locale.cpp.obj
ninja: build stopped: subcommand failed.

@petrhosek
Copy link
Member

I think this is due to

which I believe is yet another instance of #56070.

@ilovepi
Copy link
Contributor Author

ilovepi commented Nov 1, 2024

I'm pretty sure you're correct on the root cause. In this case its the pragmas in libcxx (random and chrono), but I'd expect this to happen for similar situations, like the atomics.

This happens for LTO alone, and isn't something I think we can work around through FatLTO, unless we disable using LTO to link libcxxabi (eg. --no-fat-lto-objects). Since I don't think this is a libcxxabi specific problem, I'm not sure that's necessarily a good idea, and won't just break somewhere else (either in the toolchain build or when building Fuchsia code).

Unsurprisingly, adding -lzircon allows the link to complete w/ LTO, so I wonder if there is a way to specify the zircon dep other than through the pragma? This is definitely unsatisfying. I'm tempted to say that clang's Fuchsia driver should just add zircon as a dep, except that feels all kinds of wrong, and is clearly just addressing a symptom instead of the underlying problem.

#56070 has enough to say about why this is hard to fix in LLD/generally, but IDK how to solve this for our usecase ATM. @mysterymath I recall you mentioned a new libcall mechanism that was being used that may help w/ some of deplibs mess. Do you have any thoughts on if that can be adapted in some way to help resolve these?

@mysterymath
Copy link
Contributor

mysterymath commented Nov 1, 2024

The rule established in LLD is that all input files to the link must be known before LTO begins. This is because a set of properties computed from the input files is used as input to LTO codegen, and the results of codegen are not necessarily valid if those properties were to change by the addition of new input files.

In the short term, I'd recommend CMake plumbing to ensure that -lzircon is passed to any .so or executables that are LTO compiled within the LLVM build.

In the longer term, as @ilovepi mentioned, we now have a relatively accurate list of libcalls available in LLD. This is already used to summarily pull in bitcode that defines potential-used libcalls. We could also scan the files that define potentially-used libcalls for deplibs, and summarily include those in the link. I have an old Phabricator patch for this. The main issue with it was IIRC the libcall listing mechanism it added to LLD, but that has been addressed by the libcall list work.

@ilovepi ilovepi requested a review from a team as a code owner November 12, 2024 17:41
@llvmbot llvmbot added cmake Build system in general and CMake in particular libc++abi libc++abi C++ Runtime Library. Not libc++. labels Nov 12, 2024
Created using spr 1.3.4

[skip ci]
Created using spr 1.3.4
Created using spr 1.3.4

[skip ci]
Created using spr 1.3.6-beta.1

[skip ci]
Created using spr 1.3.6-beta.1
@ilovepi ilovepi changed the base branch from main to users/ilovepi/spr/main.fuchsiacmake-allow-using-fatlto-when-building-runtimes-3 November 18, 2024 21:36
@@ -1285,7 +1285,7 @@ elseif(LLVM_ENABLE_LTO)
endif()
endif()

if(LLVM_ENABLE_FATLTO AND UNIX AND NOT APPLE)
if(LLVM_ENABLE_FATLTO AND ((UNIX AND NOT APPLE) OR FUCHSIA))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't understand why that diff is required since you're setting it properly in your cache files.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because Fuchsia Targets aren't UNIX. Without this change -ffat-lto-objects won't be passed to clang through CMake. The additional logic is basically to restrict the flag to ELF targets, and it missed Fuchsia when we added it, since we weren't building our runtimes with FatLTO initially, just the toolchain + tests.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, I think I initially read if (LLVM_ENABLE_FATLTO OR ((UNIX AND NOT APPLE) OR FUCHSIA)).

@@ -1285,7 +1285,7 @@ elseif(LLVM_ENABLE_LTO)
endif()
endif()

if(LLVM_ENABLE_FATLTO AND UNIX AND NOT APPLE)
if(LLVM_ENABLE_FATLTO AND ((UNIX AND NOT APPLE) OR FUCHSIA))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, I think I initially read if (LLVM_ENABLE_FATLTO OR ((UNIX AND NOT APPLE) OR FUCHSIA)).

Created using spr 1.3.6-beta.1

[skip ci]
Created using spr 1.3.6-beta.1
@ilovepi ilovepi changed the base branch from users/ilovepi/spr/main.fuchsiacmake-allow-using-fatlto-when-building-runtimes-3 to main December 9, 2024 17:20
Created using spr 1.3.6-beta.1
@ilovepi ilovepi merged commit 57545db into main Dec 9, 2024
5 of 6 checks passed
@ilovepi ilovepi deleted the users/ilovepi/spr/libcxxcmake-allow-using-fatlto-in-libc-builds branch December 9, 2024 17:26
ilovepi added a commit that referenced this pull request Dec 9, 2024
ilovepi added a commit that referenced this pull request Dec 9, 2024
…119252)

Reverts #112277

This broke something on Fuchsia's Mac builders, 
so there's still something in the CMake that needs to be updated before
we reland.

Failed build: 

https://ci.chromium.org/ui/p/fuchsia/builders/toolchain.ci/clang-mac-xarm64/b8729005878443108801/overview
@llvm-ci
Copy link
Collaborator

llvm-ci commented Dec 9, 2024

LLVM Buildbot has detected a new failure on builder lldb-aarch64-windows running on linaro-armv8-windows-msvc-05 while building clang,llvm at step 6 "test".

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

Here is the relevant piece of the build log for the reference
Step 6 (test) failure: build (failure)
...
PASS: lldb-api :: tools/lldb-server/TestGdbRemoteLaunch.py (1175 of 2054)
UNSUPPORTED: lldb-api :: tools/lldb-server/TestGdbRemotePlatformFile.py (1176 of 2054)
PASS: lldb-api :: tools/lldb-server/TestGdbRemoteModuleInfo.py (1177 of 2054)
PASS: lldb-api :: tools/lldb-server/TestGdbRemoteRegisterState.py (1178 of 2054)
UNSUPPORTED: lldb-api :: tools/lldb-server/TestGdbRemoteSaveCore.py (1179 of 2054)
UNSUPPORTED: lldb-api :: tools/lldb-server/TestGdbRemoteSingleStep.py (1180 of 2054)
PASS: lldb-api :: tools/lldb-server/TestGdbRemoteProcessInfo.py (1181 of 2054)
PASS: lldb-api :: tools/lldb-server/TestGdbRemoteThreadsInStopReply.py (1182 of 2054)
PASS: lldb-api :: tools/lldb-server/TestGdbRemote_vCont.py (1183 of 2054)
PASS: lldb-api :: tools/lldb-server/TestGdbRemote_qThreadStopInfo.py (1184 of 2054)
FAIL: lldb-api :: tools/lldb-server/TestNonStop.py (1185 of 2054)
******************** TEST 'lldb-api :: tools/lldb-server/TestNonStop.py' FAILED ********************
Script:
--
C:/Users/tcwg/scoop/apps/python/current/python.exe C:/Users/tcwg/llvm-worker/lldb-aarch64-windows/llvm-project/lldb\test\API\dotest.py -u CXXFLAGS -u CFLAGS --env LLVM_LIBS_DIR=C:/Users/tcwg/llvm-worker/lldb-aarch64-windows/build/./lib --env LLVM_INCLUDE_DIR=C:/Users/tcwg/llvm-worker/lldb-aarch64-windows/build/include --env LLVM_TOOLS_DIR=C:/Users/tcwg/llvm-worker/lldb-aarch64-windows/build/./bin --arch aarch64 --build-dir C:/Users/tcwg/llvm-worker/lldb-aarch64-windows/build/lldb-test-build.noindex --lldb-module-cache-dir C:/Users/tcwg/llvm-worker/lldb-aarch64-windows/build/lldb-test-build.noindex/module-cache-lldb\lldb-api --clang-module-cache-dir C:/Users/tcwg/llvm-worker/lldb-aarch64-windows/build/lldb-test-build.noindex/module-cache-clang\lldb-api --executable C:/Users/tcwg/llvm-worker/lldb-aarch64-windows/build/./bin/lldb.exe --compiler C:/Users/tcwg/llvm-worker/lldb-aarch64-windows/build/./bin/clang.exe --dsymutil C:/Users/tcwg/llvm-worker/lldb-aarch64-windows/build/./bin/dsymutil.exe --make C:/Users/tcwg/scoop/shims/make.exe --llvm-tools-dir C:/Users/tcwg/llvm-worker/lldb-aarch64-windows/build/./bin --lldb-obj-root C:/Users/tcwg/llvm-worker/lldb-aarch64-windows/build/tools/lldb --lldb-libs-dir C:/Users/tcwg/llvm-worker/lldb-aarch64-windows/build/./lib --skip-category=watchpoint C:\Users\tcwg\llvm-worker\lldb-aarch64-windows\llvm-project\lldb\test\API\tools\lldb-server -p TestNonStop.py
--
Exit Code: 1

Command Output (stdout):
--
lldb version 20.0.0git (https://github.com/llvm/llvm-project.git revision 57545dbbdbafc51d63873800a45cfd48a283d981)
  clang revision 57545dbbdbafc51d63873800a45cfd48a283d981
  llvm revision 57545dbbdbafc51d63873800a45cfd48a283d981
Skipping the following test categories: ['watchpoint', 'libc++', 'libstdcxx', 'dwo', 'dsym', 'gmodules', 'debugserver', 'objc', 'fork', 'pexpect']


--
Command Output (stderr):
--
FAIL: LLDB (C:\Users\tcwg\llvm-worker\lldb-aarch64-windows\build\bin\clang.exe-aarch64) :: test_exit_llgs (TestNonStop.LldbGdbServerTestCase.test_exit_llgs)

UNSUPPORTED: LLDB (C:\Users\tcwg\llvm-worker\lldb-aarch64-windows\build\bin\clang.exe-aarch64) :: test_exit_query_llgs (TestNonStop.LldbGdbServerTestCase.test_exit_query_llgs) (skip on windows) 

UNSUPPORTED: LLDB (C:\Users\tcwg\llvm-worker\lldb-aarch64-windows\build\bin\clang.exe-aarch64) :: test_leave_nonstop_llgs (TestNonStop.LldbGdbServerTestCase.test_leave_nonstop_llgs) (skip on windows) 

PASS: LLDB (C:\Users\tcwg\llvm-worker\lldb-aarch64-windows\build\bin\clang.exe-aarch64) :: test_multiple_C_continue_with_signal_llgs (TestNonStop.LldbGdbServerTestCase.test_multiple_C_continue_with_signal_llgs)

PASS: LLDB (C:\Users\tcwg\llvm-worker\lldb-aarch64-windows\build\bin\clang.exe-aarch64) :: test_multiple_c_continue_with_addr_llgs (TestNonStop.LldbGdbServerTestCase.test_multiple_c_continue_with_addr_llgs)

PASS: LLDB (C:\Users\tcwg\llvm-worker\lldb-aarch64-windows\build\bin\clang.exe-aarch64) :: test_multiple_s_single_step_with_addr_llgs (TestNonStop.LldbGdbServerTestCase.test_multiple_s_single_step_with_addr_llgs)

UNSUPPORTED: LLDB (C:\Users\tcwg\llvm-worker\lldb-aarch64-windows\build\bin\clang.exe-aarch64) :: test_multiple_vCont_llgs (TestNonStop.LldbGdbServerTestCase.test_multiple_vCont_llgs) (skip on windows) 

UNSUPPORTED: LLDB (C:\Users\tcwg\llvm-worker\lldb-aarch64-windows\build\bin\clang.exe-aarch64) :: test_run_llgs (TestNonStop.LldbGdbServerTestCase.test_run_llgs) (skip on windows) 

UNSUPPORTED: LLDB (C:\Users\tcwg\llvm-worker\lldb-aarch64-windows\build\bin\clang.exe-aarch64) :: test_stdio_llgs (TestNonStop.LldbGdbServerTestCase.test_stdio_llgs) (skip on windows) 

UNSUPPORTED: LLDB (C:\Users\tcwg\llvm-worker\lldb-aarch64-windows\build\bin\clang.exe-aarch64) :: test_stop_reason_while_running_llgs (TestNonStop.LldbGdbServerTestCase.test_stop_reason_while_running_llgs) (skip on windows) 


@llvm-ci
Copy link
Collaborator

llvm-ci commented Dec 10, 2024

LLVM Buildbot has detected a new failure on builder lld-x86_64-win running on as-worker-93 while building clang,llvm at step 7 "test-build-unified-tree-check-all".

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

Here is the relevant piece of the build log for the reference
Step 7 (test-build-unified-tree-check-all) failure: test (failure)
******************** TEST 'LLVM-Unit :: Support/./SupportTests.exe/38/87' FAILED ********************
Script(shard):
--
GTEST_OUTPUT=json:C:\a\lld-x86_64-win\build\unittests\Support\.\SupportTests.exe-LLVM-Unit-17884-38-87.json GTEST_SHUFFLE=0 GTEST_TOTAL_SHARDS=87 GTEST_SHARD_INDEX=38 C:\a\lld-x86_64-win\build\unittests\Support\.\SupportTests.exe
--

Script:
--
C:\a\lld-x86_64-win\build\unittests\Support\.\SupportTests.exe --gtest_filter=ProgramEnvTest.CreateProcessLongPath
--
C:\a\lld-x86_64-win\llvm-project\llvm\unittests\Support\ProgramTest.cpp(160): error: Expected equality of these values:
  0
  RC
    Which is: -2

C:\a\lld-x86_64-win\llvm-project\llvm\unittests\Support\ProgramTest.cpp(163): error: fs::remove(Twine(LongPath)): did not return errc::success.
error number: 13
error message: permission denied



C:\a\lld-x86_64-win\llvm-project\llvm\unittests\Support\ProgramTest.cpp:160
Expected equality of these values:
  0
  RC
    Which is: -2

C:\a\lld-x86_64-win\llvm-project\llvm\unittests\Support\ProgramTest.cpp:163
fs::remove(Twine(LongPath)): did not return errc::success.
error number: 13
error message: permission denied




********************


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
clang Clang issues not falling into any other category cmake Build system in general and CMake in particular libc++abi libc++abi C++ Runtime Library. Not libc++.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants