Skip to content
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++] Clean up and update deployment target features #96312

Merged
merged 1 commit into from
Jun 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
278 changes: 150 additions & 128 deletions libcxx/include/__configuration/availability.h

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@
//
// Reported as https://llvm.org/PR53170.

// reserve(n) used to shrink the string until https://llvm.org/D117332 was shipped.
// XFAIL: stdlib=system && target={{.+}}-apple-macosx{{10.9|10.10|10.11|10.12|10.13|10.14|10.15|11.0|12.0}}
// reserve(n) used to shrink the string until https://llvm.org/D117332 was shipped in LLVM 14.
// XFAIL: using-built-library-before-llvm-14

#include <string>
#include <stdexcept>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,13 @@
//
//===----------------------------------------------------------------------===//

// XFAIL: stdlib=system && target={{.+}}-apple-macosx{{10.13|10.14|10.15|11.0}}

// <string>

// This test demonstrates the smaller allocation sizes when the alignment
// requirements of std::string are dropped from 16 to 8.
//
// XFAIL: using-built-library-before-llvm-19

#include <algorithm>
#include <cassert>
#include <cstddef>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,6 @@
// unique_lock.
// UNSUPPORTED: c++03

// PR30202 was fixed starting in macosx10.13.
// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12}}

// <condition_variable>

// void notify_all_at_thread_exit(condition_variable& cond, unique_lock<mutex> lk);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,6 @@

// UNSUPPORTED: no-threads

// Until 58a0a70fb2f1, this_thread::sleep_for could sometimes get interrupted
// by signals and this test would fail spuriously. Disable the test on the
// corresponding system libraries.
// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11}}

// ALLOW_RETRIES: 3

// <thread>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,6 @@
// This test uses the POSIX header <sys/time.h> which Windows doesn't provide
// UNSUPPORTED: windows

// Until 58a0a70fb2f1, this_thread::sleep_for misbehaves when interrupted by
// a signal, as tested here. Disable the test on the corresponding system
// libraries.
// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11}}

// ALLOW_RETRIES: 3

// <thread>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

// ::aligned_alloc is provided by the C library, but it's marked as unavailable
// until macOS 10.15
// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12|13|14}}
// XFAIL: target={{.+}}-apple-macosx10.{{(13|14)(.0)?}}

// ::aligned_alloc is not implemented on Windows
// XFAIL: target={{.+}}-windows-{{.+}}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@
//
//===----------------------------------------------------------------------===//

// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12}}

// <system_error>

// class error_category
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@

// const error_category& system_category();

// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12}}

#include <system_error>
#include <cassert>
#include <string>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
// UNSUPPORTED: c++03, c++11, c++14

// The string reported on errors changed, which makes those tests fail when run
// against already-released libc++'s.
// XFAIL: stdlib=system && target={{.+}}-apple-macosx{{10.15|11.0}}
// against a built library that doesn't contain 0aa637b2037d.
// XFAIL: using-built-library-before-llvm-13

// <filesystem>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
// UNSUPPORTED: c++03, c++11, c++14

// The string reported on errors changed, which makes those tests fail when run
// against already-released libc++'s.
// XFAIL: stdlib=system && target={{.+}}-apple-macosx{{10.15|11.0}}
// against a built library that doesn't contain 0aa637b2037d.
// XFAIL: using-built-library-before-llvm-13

// Starting in Android N (API 24), SELinux policy prevents the shell user from
// creating a FIFO file.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
// UNSUPPORTED: c++03, c++11, c++14

// The string reported on errors changed, which makes those tests fail when run
// against already-released libc++'s.
// XFAIL: stdlib=system && target={{.+}}-apple-macosx{{10.15|11.0}}
// against a built library that doesn't contain 0aa637b2037d.
// XFAIL: using-built-library-before-llvm-13

// Starting in Android N (API 24), SELinux policy prevents the shell user from
// creating a hard link.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
// UNSUPPORTED: c++03, c++11, c++14

// The string reported on errors changed, which makes those tests fail when run
// against already-released libc++'s.
// XFAIL: stdlib=system && target={{.+}}-apple-macosx{{10.15|11.0}}
// against a built library that doesn't contain 0aa637b2037d.
// XFAIL: using-built-library-before-llvm-13

// <filesystem>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
// UNSUPPORTED: availability-filesystem-missing

// The string reported on errors changed, which makes those tests fail when run
// against already-released libc++'s.
// XFAIL: stdlib=system && target={{.+}}-apple-macosx{{10.15|11.0}}
// against a built library that doesn't contain 0aa637b2037d.
// XFAIL: using-built-library-before-llvm-13

// Starting in Android N (API 24), SELinux policy prevents the shell user from
// creating a FIFO file.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
// UNSUPPORTED: no-filesystem
// UNSUPPORTED: availability-filesystem-missing

// This test requires the dylib support introduced in D92769.
// XFAIL: stdlib=system && target={{.+}}-apple-macosx{{10.15|11.0}}
// This test requires the dylib support introduced in e4ed349c7658.
// XFAIL: using-built-library-before-llvm-12

// <filesystem>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
// UNSUPPORTED: no-filesystem
// UNSUPPORTED: availability-filesystem-missing

// This test requires the dylib support introduced in http://llvm.org/D92769.
// XFAIL: stdlib=system && target={{.+}}-apple-macosx{{10.15|11.0}}
// This test requires the dylib support introduced in e4ed349c7658.
// XFAIL: using-built-library-before-llvm-12

// <filesystem>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
// UNSUPPORTED: no-filesystem
// UNSUPPORTED: availability-filesystem-missing

// This test requires the dylib support introduced in http://llvm.org/D92769.
// XFAIL: stdlib=system && target={{.+}}-apple-macosx{{10.15|11.0}}
// This test requires the dylib support introduced in e4ed349c7658.
// XFAIL: using-built-library-before-llvm-12

// <filesystem>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
// UNSUPPORTED: availability-filesystem-missing

// The string reported on errors changed, which makes those tests fail when run
// against already-released libc++'s.
// XFAIL: stdlib=system && target={{.+}}-apple-macosx{{10.15|11.0}}
// against a built library that doesn't contain 0aa637b2037d.
// XFAIL: using-built-library-before-llvm-13

// <filesystem>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
// UNSUPPORTED: availability-filesystem-missing

// The string reported on errors changed, which makes those tests fail when run
// against already-released libc++'s.
// XFAIL: stdlib=system && target={{.+}}-apple-macosx{{10.15|11.0}}
// against a built library that doesn't contain 0aa637b2037d.
// XFAIL: using-built-library-before-llvm-13

// <filesystem>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,9 @@
//
// This is taken from https://github.com/rust-lang/wg-security-response/blob/master/patches/CVE-2022-21658/0002-Fix-CVE-2022-21658-for-UNIX-like.patch

// This test requires a dylib containing the fix shipped in https://reviews.llvm.org/D118134.
// This test requires a dylib containing the fix shipped in https://reviews.llvm.org/D118134 (4f67a909902d).
// We use UNSUPPORTED instead of XFAIL because the test might not fail reliably.
// UNSUPPORTED: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12|13|14|15}}
// UNSUPPORTED: stdlib=system && target={{.+}}-apple-macosx11.0
// UNSUPPORTED: stdlib=system && target={{.+}}-apple-macosx12.{{0|1|2}}
// UNSUPPORTED: using-built-library-before-llvm-14

// Windows doesn't support the necessary APIs to mitigate this issue.
// XFAIL: target={{.+}}-windows-{{.+}}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
//
//===----------------------------------------------------------------------===//

// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12|13|14}}
// Requires 396145d in the built library.
// XFAIL: using-built-library-before-llvm-9

// <istream>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
//
//===----------------------------------------------------------------------===//

// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12|13|14}}
// Requires 396145d in the built library.
// XFAIL: using-built-library-before-llvm-9

// <istream>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
//
//===----------------------------------------------------------------------===//

// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12|13|14}}
// Requires 396145d in the built library.
// XFAIL: using-built-library-before-llvm-9

// <istream>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
//
//===----------------------------------------------------------------------===//

// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12|13|14}}
// Requires 396145d in the built library.
// XFAIL: using-built-library-before-llvm-9

// <istream>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
//
//===----------------------------------------------------------------------===//

// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12|13|14}}
// Requires 396145d in the built library.
// XFAIL: using-built-library-before-llvm-9

// <istream>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
//
//===----------------------------------------------------------------------===//

// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12|13|14}}
// Requires 396145d in the built library.
// XFAIL: using-built-library-before-llvm-9

// <istream>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
//
//===----------------------------------------------------------------------===//

// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12|13|14}}
// Requires 396145d in the built library.
// XFAIL: using-built-library-before-llvm-9

// <istream>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
//
//===----------------------------------------------------------------------===//

// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12|13|14}}
// Requires 396145d in the built library.
// XFAIL: using-built-library-before-llvm-9

// <istream>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
//
//===----------------------------------------------------------------------===//

// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12|13|14}}
// Requires 396145d in the built library.
// XFAIL: using-built-library-before-llvm-9

// <istream>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
//
//===----------------------------------------------------------------------===//

// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12|13|14}}
// Requires 396145d in the built library.
// XFAIL: using-built-library-before-llvm-9

// <istream>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
//
//===----------------------------------------------------------------------===//

// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12|13|14}}
// Requires 396145d in the built library.
// XFAIL: using-built-library-before-llvm-9

// <istream>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
//
//===----------------------------------------------------------------------===//

// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12|13|14}}
// Requires 396145d in the built library.
// XFAIL: using-built-library-before-llvm-9

// <istream>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
//
//===----------------------------------------------------------------------===//

// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12|13|14}}
// Requires 396145d in the built library.
// XFAIL: using-built-library-before-llvm-9

// <istream>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
//
//===----------------------------------------------------------------------===//

// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12|13|14}}
// Requires 396145d in the built library.
// XFAIL: using-built-library-before-llvm-9

// <istream>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
//
//===----------------------------------------------------------------------===//

// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12|13|14}}
// Requires 396145d in the built library.
// XFAIL: using-built-library-before-llvm-9

// <istream>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
//
//===----------------------------------------------------------------------===//

// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12|13|14}}
// Requires 396145d in the built library.
// XFAIL: using-built-library-before-llvm-9

// <istream>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@

// In macosx10.9 to macosx10.14, streams are provided in the dylib AND they
// have a bug in how they handle null-termination in case of errors (see D40677).
// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12|13|14}}
// Requires 396145d in the built library.
// XFAIL: using-built-library-before-llvm-9

// <istream>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@

// In macosx10.9 to macosx10.14, streams are provided in the dylib AND they
// have a bug in how they handle null-termination in case of errors (see D40677).
// XFAIL: stdlib=system && target={{.+}}-apple-macosx10.{{9|10|11|12|13|14}}
// Requires 396145d in the built library.
// XFAIL: using-built-library-before-llvm-9

// <istream>

Expand Down
Loading
Loading