-
Notifications
You must be signed in to change notification settings - Fork 11.8k
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
libc++ tests fail with "aligned allocation function of type 'void *(std::size_t, std::align_val_t)' is only available on macOS 10.14 or newer" #39701
Comments
From the text that you pasted in, it looks like you're running on Mac OS 10.13, but I'd like to be sure. (You're certainly using the 10.13 sdk) What's the version of the OS that you're running? |
I'm running 10.13.6 |
This seems related to r350649 (Committed by Louis) Louis is on vacation (if you're reading this, stay on vacation). So I'll attempt to clean this up tomorrow. |
@Hans, I committed a fix in r351625. Because the semantics around aligned allocation have changed a ton between different Clang versions, it's possible there are still configurations that fail, but I haven't managed to recreate one. |
As I suggested, I found more cases that fail. But I think I've found them all. I'll follow up tomorrow with a ultimate fix. |
Did this land or is it still work in progress? |
Hi Hans, Yes, this was fixed in r351670. Sorry I forgot to update the bug. |
Thanks! Merged to 8.0 in r351980. |
Extended Description
I assume this is due to https://reviews.llvm.org/D56445
This came up while testing the new 8.0 branch on mac. Please see the example failure below. The full build log is attached.
Testing: 0 .. 10.. 20.. 30.. 40.. 50.. 60.. 70.. 80..
FAIL: libc++ :: std/language.support/support.dynamic/new.delete/new.delete.array/new_align_val_t_nothrow.pass.cpp (51761 of 57410)
******************** TEST 'libc++ :: std/language.support/support.dynamic/new.delete/new.delete.array/new_align_val_t_nothrow.pass.cpp' FAILED ********************
Command: ['/work/llvm-release-test/branches_release_80/Phase2/Release/llvmCore-test-branches_release_80.install/usr/local/bin/clang++', '-o', '/work/llvm-release-test/branches_release_80/Phase3/Release/llvmCore-test-branches_release_80.obj/projects/libcxx/test/std/language.support/support.dynamic/new.delete/new.delete.array/Output/new_align_val_t_nothrow.pass.cpp.o', '-x', 'c++', '/work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_align_val_t_nothrow.pass.cpp', '-c', '-v', '-arch', 'x86_64', '-mmacosx-version-min=10.13', '-ftemplate-depth=270', '-Werror=thread-safety', '-std=c++2a', '-include', '/work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/test/support/nasty_macros.hpp', '-nostdinc++', '-I/work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/include', '-I/work/llvm-release-test/branches_release_80/Phase3/Release/llvmCore-test-branches_release_80.obj/projects/libcxx/include/c++build', '-isysroot', '/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk', '-I/work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/test/support', '-DLIBCXX_FILESYSTEM_STATIC_TEST_ROOT="/work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/test/std/input.output/filesystems/Inputs/static_test_env"', '-DLIBCXX_FILESYSTEM_DYNAMIC_TEST_ROOT="/work/llvm-release-test/branches_release_80/Phase3/Release/llvmCore-test-branches_release_80.obj/projects/libcxx/test/filesystem/Output/dynamic_env"', '-DLIBCXX_FILESYSTEM_DYNAMIC_TEST_HELPER="/System/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python /work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/test/support/filesystem_dynamic_test_helper.py"', '-D_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER', '-Wall', '-Wextra', '-Werror', '-Wuser-defined-warnings', '-Wshadow', '-Wno-unused-command-line-argument', '-Wno-attributes', '-Wno-pessimizing-move', '-Wno-c++11-extensions', '-Wno-user-defined-literals', '-Wno-noexcept-type', '-Wsign-compare', '-Wunused-variable', '-Wunused-parameter', '-Wunreachable-code', '-c']
Exit Code: 1
Standard Error:
clang version 8.0.0 (branches/release_80)
Target: x86_64-apple-darwin17.7.0
Thread model: posix
InstalledDir: /work/llvm-release-test/branches_release_80/Phase2/Release/llvmCore-test-branches_release_80.install/usr/local/bin
"/work/llvm-release-test/branches_release_80/Phase2/Release/llvmCore-test-branches_release_80.install/usr/local/bin/clang-8" -cc1 -triple x86_64-apple-macosx10.13.0 -Wdeprecated-objc-isa-usage -Werror=deprecated-objc-isa-usage -emit-obj -mrelax-all -disable-free -disable-llvm-verifier -discard-value-names -main-file-name new_align_val_t_nothrow.pass.cpp -mrelocation-model pic -pic-level 2 -mthread-model posix -mdisable-fp-elim -masm-verbose -munwind-tables -faligned-alloc-unavailable -target-cpu penryn -dwarf-column-info -debugger-tuning=lldb -ggnu-pubnames -target-linker-version 305 -v -coverage-notes-file /work/llvm-release-test/branches_release_80/Phase3/Release/llvmCore-test-branches_release_80.obj/projects/libcxx/test/std/language.support/support.dynamic/new.delete/new.delete.array/Output/new_align_val_t_nothrow.pass.cpp.gcno -nostdinc++ -resource-dir /work/llvm-release-test/branches_release_80/Phase2/Release/llvmCore-test-branches_release_80.install/usr/local/lib/clang/8.0.0 -include /work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/test/support/nasty_macros.hpp -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk -I /work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/include -I /work/llvm-release-test/branches_release_80/Phase3/Release/llvmCore-test-branches_release_80.obj/projects/libcxx/include/c++build -I /work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/test/support -D "LIBCXX_FILESYSTEM_STATIC_TEST_ROOT="/work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/test/std/input.output/filesystems/Inputs/static_test_env"" -D "LIBCXX_FILESYSTEM_DYNAMIC_TEST_ROOT="/work/llvm-release-test/branches_release_80/Phase3/Release/llvmCore-test-branches_release_80.obj/projects/libcxx/test/filesystem/Output/dynamic_env"" -D "LIBCXX_FILESYSTEM_DYNAMIC_TEST_HELPER="/System/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python /work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/test/support/filesystem_dynamic_test_helper.py"" -D _LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER -stdlib=libc++ -Werror=thread-safety -Wall -Wextra -Werror -Wuser-defined-warnings -Wshadow -Wno-unused-command-line-argument -Wno-attributes -Wno-pessimizing-move -Wno-c++11-extensions -Wno-user-defined-literals -Wno-noexcept-type -Wsign-compare -Wunused-variable -Wunused-parameter -Wunreachable-code -std=c++2a -fdeprecated-macro -fdebug-compilation-dir /work/llvm-release-test/branches_release_80/Phase3/Release/llvmCore-test-branches_release_80.obj/projects/libcxx/test/std/language.support/support.dynamic/new.delete/new.delete.array -ftemplate-depth 270 -ferror-limit 19 -fmessage-length 0 -stack-protector 1 -fblocks -fencode-extended-block-signature -fregister-global-dtors-with-atexit -fobjc-runtime=macosx-10.13.0 -fcxx-exceptions -fexceptions -fmax-type-align=16 -fdiagnostics-show-option -o /work/llvm-release-test/branches_release_80/Phase3/Release/llvmCore-test-branches_release_80.obj/projects/libcxx/test/std/language.support/support.dynamic/new.delete/new.delete.array/Output/new_align_val_t_nothrow.pass.cpp.o -x c++ /work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_align_val_t_nothrow.pass.cpp
clang -cc1 version 8.0.0 based upon LLVM 8.0.0 default target x86_64-apple-darwin17.7.0
ignoring nonexistent directory "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk/usr/local/include"
ignoring nonexistent directory "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk/Library/Frameworks"
#include "..." search starts here:
#include <...> search starts here:
/work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/include
/work/llvm-release-test/branches_release_80/Phase3/Release/llvmCore-test-branches_release_80.obj/projects/libcxx/include/c++build
/work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/test/support
/work/llvm-release-test/branches_release_80/Phase2/Release/llvmCore-test-branches_release_80.install/usr/local/lib/clang/8.0.0/include
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk/usr/include
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk/System/Library/Frameworks (framework directory)
End of search list.
/work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_align_val_t_nothrow.pass.cpp:74:20: error: aligned allocation function of type 'void (std::size_t, std::align_val_t, const std::nothrow_t &) noexcept' is only available on macOS 10.14 or newer
void vp = operator new [](std::numeric_limitsstd::size_t::max(),
^
/work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_align_val_t_nothrow.pass.cpp:74:20: note: if you supply your own aligned allocation functions, use -faligned-allocation to silence this diagnostic
/work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_align_val_t_nothrow.pass.cpp:97:17: error: aligned allocation function of type 'void (std::size_t, std::align_val_t, const std::nothrow_t &) noexcept' is only available on macOS 10.14 or newer
A ap = new(std::nothrow) A[3];
^
/work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_align_val_t_nothrow.pass.cpp:97:17: note: if you supply your own aligned allocation functions, use -faligned-allocation to silence this diagnostic
/work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_align_val_t_nothrow.pass.cpp:97:17: error: aligned deallocation function of type 'void (void , std::align_val_t, const std::nothrow_t &) noexcept' is only available on macOS 10.14 or newer
A ap = new(std::nothrow) A[3];
^
/work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_align_val_t_nothrow.pass.cpp:97:17: note: if you supply your own aligned allocation functions, use -faligned-allocation to silence this diagnostic
/work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_align_val_t_nothrow.pass.cpp:101:9: error: aligned deallocation function of type 'void (void *, std::align_val_t) noexcept' is only available on macOS 10.14 or newer
delete [] ap;
^
/work/llvm-release-test/branches_release_80/llvm.src/projects/libcxx/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_align_val_t_nothrow.pass.cpp:101:9: note: if you supply your own aligned allocation functions, use -faligned-allocation to silence this diagnostic
4 errors generated.
Compilation failed unexpectedly!
The text was updated successfully, but these errors were encountered: