Skip to content

[compiler-rt][MSVC] Conditionally remove emupac.cpp for msvc #149823

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
merged 1 commit into from
Jul 22, 2025

Conversation

zacklj89
Copy link
Contributor

#148094 introduces logic for emulated PAC, which utilizes language extensions not available on MSVC.

@zacklj89
Copy link
Contributor Author

I'll go ahead and merge here since this is a low-risk change that should only affect MSVC.

@zacklj89 zacklj89 merged commit 7cfd32a into llvm:main Jul 22, 2025
12 checks passed
@nico
Copy link
Contributor

nico commented Jul 22, 2025

"MSVC" is true both for msvc and clang-cl. Do you want to exclude this for clang-cl too? (I.e. is this about a cl.exe limitation, or a PE/COFF limitation?)

@zacklj89
Copy link
Contributor Author

@nico thanks, I didn't know they shared that evaluation here!

clang-cl uses the MSVC-style inline assembly syntax, I think (?), so this should also apply for it as well.

@llvm-ci
Copy link
Collaborator

llvm-ci commented Jul 22, 2025

LLVM Buildbot has detected a new failure on builder premerge-monolithic-linux running on premerge-linux-1 while building compiler-rt at step 7 "test-build-unified-tree-check-all".

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

Here is the relevant piece of the build log for the reference
Step 7 (test-build-unified-tree-check-all) failure: test (failure)
...
PASS: lld :: COFF/entry-weak-external.s (98800 of 101788)
PASS: lld :: COFF/empty-subsection.s (98801 of 101788)
PASS: lld :: COFF/dllimport-gc.test (98802 of 101788)
PASS: lld :: COFF/export-armnt.yaml (98803 of 101788)
PASS: lld :: COFF/exclude-symbols.s (98804 of 101788)
PASS: lld :: COFF/eh_frame_suffix_sorting.s (98805 of 101788)
PASS: lld :: COFF/exclude-symbols-embedded.s (98806 of 101788)
PASS: lld :: COFF/empty-section-decl.yaml (98807 of 101788)
PASS: lld :: COFF/driver.test (98808 of 101788)
TIMEOUT: MLIR :: Examples/standalone/test.toy (98809 of 101788)
******************** TEST 'MLIR :: Examples/standalone/test.toy' FAILED ********************
Exit Code: 1
Timeout: Reached timeout of 60 seconds

Command Output (stdout):
--
# RUN: at line 1
"/etc/cmake/bin/cmake" "/build/buildbot/premerge-monolithic-linux/llvm-project/mlir/examples/standalone" -G "Ninja"  -DCMAKE_CXX_COMPILER=/usr/bin/clang++ -DCMAKE_C_COMPILER=/usr/bin/clang  -DLLVM_ENABLE_LIBCXX=OFF -DMLIR_DIR=/build/buildbot/premerge-monolithic-linux/build/lib/cmake/mlir  -DLLVM_USE_LINKER=lld  -DPython3_EXECUTABLE="/usr/bin/python3.10"
# executed command: /etc/cmake/bin/cmake /build/buildbot/premerge-monolithic-linux/llvm-project/mlir/examples/standalone -G Ninja -DCMAKE_CXX_COMPILER=/usr/bin/clang++ -DCMAKE_C_COMPILER=/usr/bin/clang -DLLVM_ENABLE_LIBCXX=OFF -DMLIR_DIR=/build/buildbot/premerge-monolithic-linux/build/lib/cmake/mlir -DLLVM_USE_LINKER=lld -DPython3_EXECUTABLE=/usr/bin/python3.10
# .---command stdout------------
# | -- The CXX compiler identification is Clang 16.0.6
# | -- The C compiler identification is Clang 16.0.6
# | -- Detecting CXX compiler ABI info
# | -- Detecting CXX compiler ABI info - done
# | -- Check for working CXX compiler: /usr/bin/clang++ - skipped
# | -- Detecting CXX compile features
# | -- Detecting CXX compile features - done
# | -- Detecting C compiler ABI info
# | -- Detecting C compiler ABI info - done
# | -- Check for working C compiler: /usr/bin/clang - skipped
# | -- Detecting C compile features
# | -- Detecting C compile features - done
# | -- Looking for histedit.h
# | -- Looking for histedit.h - found
# | -- Found LibEdit: /usr/include (found version "2.11") 
# | -- Found ZLIB: /usr/lib/x86_64-linux-gnu/libz.so (found version "1.2.11") 
# | -- Found LibXml2: /usr/lib/x86_64-linux-gnu/libxml2.so (found version "2.9.13") 
# | -- Using MLIRConfig.cmake in: /build/buildbot/premerge-monolithic-linux/build/lib/cmake/mlir
# | -- Using LLVMConfig.cmake in: /build/buildbot/premerge-monolithic-linux/build/lib/cmake/llvm
# | -- Linker detection: unknown
# | -- Performing Test LLVM_LIBSTDCXX_MIN
# | -- Performing Test LLVM_LIBSTDCXX_MIN - Success
# | -- Performing Test LLVM_LIBSTDCXX_SOFT_ERROR
# | -- Performing Test LLVM_LIBSTDCXX_SOFT_ERROR - Success
# | -- Performing Test CXX_SUPPORTS_CUSTOM_LINKER
# | -- Performing Test CXX_SUPPORTS_CUSTOM_LINKER - Success
# | -- Performing Test C_SUPPORTS_FPIC
# | -- Performing Test C_SUPPORTS_FPIC - Success
# | -- Performing Test CXX_SUPPORTS_FPIC

@pcc
Copy link
Contributor

pcc commented Jul 22, 2025

clang-cl /c compiler-rt/lib/builtins/aarch64/emupac.cpp /I third-party/siphash/include --target=aarch64-pc-win32 /O2 compiles here, so I'd expect this exclusion to be for cl.exe only.

@zacklj89
Copy link
Contributor Author

My mistake @pcc, I thought the __asm__ and register language extensions didn't work on clang-cl as well. I'll open a follow up.

@zacklj89
Copy link
Contributor Author

Follow up here: #150108

zacklj89 added a commit that referenced this pull request Jul 23, 2025
Follow up to #149823 to include `clang-cl` for AArch64 builtins sources.
mahesh-attarde pushed a commit to mahesh-attarde/llvm-project that referenced this pull request Jul 28, 2025
…9823)

llvm#148094 introduces logic for emulated PAC, which utilizes language
extensions not available on MSVC.
mahesh-attarde pushed a commit to mahesh-attarde/llvm-project that referenced this pull request Jul 28, 2025
Follow up to llvm#149823 to include `clang-cl` for AArch64 builtins sources.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants