Commit Graph

17573 Commits

Author SHA1 Message Date
Alastair Houghton
a0a77fa401 Merge pull request #76870 from al45tair/eng/PR-137286187
[Concurrency] Remove C++ runtime references from embedded Concurrency.
2024-10-09 12:33:26 +01:00
swift-ci
e75d787e75 Merge remote-tracking branch 'origin/main' into rebranch 2024-10-08 22:54:27 -07:00
Karoy Lorentey
ee4d4a33bd Merge pull request #75433 from lorentey/string-index-printing2 2024-10-08 22:34:03 -07:00
swift-ci
40aee60b24 Merge remote-tracking branch 'origin/main' into rebranch 2024-10-08 19:09:12 -07:00
Allan Shortlidge
0c09c6d778 Concurrency: Fix warnings in the runtime.
Addresses an unused variable warning and an unreachable code warning.
2024-10-08 14:49:17 -07:00
swift-ci
493022109b Merge remote-tracking branch 'origin/main' into rebranch 2024-10-07 21:33:06 -07:00
Konrad `ktoso` Malawski
8ae66ec1a5 Merge pull request #76888 from ktoso/wip-improve-execute-buffer-init-tracking 2024-10-08 13:21:42 +09:00
Karoy Lorentey
29cf262ef7 [stdlib] String.Index: conform to CustomDebugStringConvertible instead
Apply the LSG’s modifications as detailed in their review notes.
2024-10-07 17:00:13 -07:00
Karoy Lorentey
28ed16b469 [stdlib] String.Index.description: Explicitly note that the returned format is not stable
This tends to be generally through for most `description` properties, but explicitly calling it out should help preventing people from trying to parse the result in this case.
2024-10-07 16:02:18 -07:00
Karoy Lorentey
e39613b851 [stdlib] String.Index.description: Use @_aeic for now 2024-10-07 16:02:18 -07:00
Karoy Lorentey
01792372a9 [stdlib] String.Index: conform to CustomStringConvertible
This better exposes the internals of string indices, demystifying their operation and radically simplifying working with them.
2024-10-07 16:02:16 -07:00
swift-ci
05112fb266 Merge remote-tracking branch 'origin/main' into rebranch 2024-10-07 08:14:45 -07:00
Alex Lorenz
e6461882c8 Merge pull request #76841 from hyp/eng/stdlib-pragma-clang-diag
[stdlib][android] ignore the -Wgnu-offsetof-extensions in ExecutorChe…
2024-10-07 08:04:43 -07:00
Konrad `ktoso` Malawski
d41c9c2e8b [Distributed] improve control flow of result buffer init detection 2024-10-07 23:26:47 +09:00
swift-ci
48648e95a7 Merge remote-tracking branch 'origin/main' into rebranch 2024-10-07 04:14:40 -07:00
Egor Zhdan
168413ef61 Merge pull request #76823 from swiftlang/egorzhdan/msvc-bit-module
[cxx-interop] Modularize __msvc_bit_utils on Windows
2024-10-07 12:10:55 +01:00
Alastair Houghton
54a495527e [Concurrency] Remove C++ runtime references from embedded Concurrency.
In embedded mode, we mustn't have references to the C++ library, because
some embedded platforms don't include the C++ library.

Additionally, it's good to avoid use of global operator new and operator
delete, because they can be globally overridden and this has bitten us
in the past.

rdar://137286187
2024-10-07 10:30:27 +01:00
Mykola Pokhylets
cb4c880af1 Move TaskLocal.h out of ABI folder, because it describes implementation details 2024-10-06 14:37:11 +02:00
swift-ci
61d99dd045 Merge remote-tracking branch 'origin/main' into rebranch 2024-10-05 03:06:15 -07:00
Konrad `ktoso` Malawski
e8c25a456d [Distributed] fix deinitialization of result buffer 2024-10-05 14:40:11 +09:00
Egor Zhdan
16e7cbeafa [cxx-interop] Modularize __msvc_bit_utils on Windows
`__msvc_bit_utils.hpp` was added in a recent version of MSVC, and it is causing build errors for SwiftCompilerSources:
```
C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.39.33519\include\numeric:598:12: error: function '_Select_countr_zero_impl<unsigned long long, (lambda at C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.39.33519\include\numeric:598:55)>' with deduced return type cannot be used before it is defined
    return _Select_countr_zero_impl<_Common_unsigned>([=](auto _Countr_zero_impl) {
```

This change references the `__msvc_bit_utils.hpp` header from the modulemap. Since we still need to support older versions of Visual Studio that do not provide `__msvc_bit_utils.hpp`, this also teaches ClangImporter to inject an empty header file named `__msvc_bit_utils.hpp` into the system include directory, unless it already exists.

rdar://137066642
2024-10-04 13:15:20 +01:00
swift-ci
a658eaa0e8 Merge remote-tracking branch 'origin/main' into rebranch 2024-10-04 03:35:39 -07:00
Egor Zhdan
1f39eee77f Merge pull request #76861 from swiftlang/egorzhdan/glibc-remove-wasi
[Glibc] Remove WASI gyb logic from the modulemap
2024-10-04 11:21:45 +01:00
swift-ci
433a6d8469 Merge remote-tracking branch 'origin/main' into rebranch 2024-10-03 19:47:13 -07:00
Kuba (Brecka) Mracek
341d6305ff Merge pull request #76767 from kubamracek/embedded-concurrency-task-groups
[Concurrency] Enable TaskGroup/DiscardingTaskGroup in Embedded Swift
2024-10-03 19:29:54 -07:00
swift-ci
6db692928d Merge remote-tracking branch 'origin/main' into rebranch 2024-10-03 18:33:24 -07:00
Konrad `ktoso` Malawski
6dea968c7e Merge pull request #76858 from swiftlang/revert-76627-revert-76623-revert-76595-wip-release-dist-execute-return 2024-10-04 10:26:49 +09:00
Egor Zhdan
5b9186e445 [Glibc] Remove WASI gyb logic from the modulemap
This is a minor cleanup of the generated Glibc modulemap.

WASI no longer uses the Glibc modulemap since 902d75e6.
2024-10-04 01:00:24 +01:00
swift-ci
53aec1363d Merge remote-tracking branch 'origin/main' into rebranch 2024-10-03 15:14:28 -07:00
Konrad `ktoso` Malawski
41d8962783 Revert "Revert "Revert "[Distributed] remote calls over-retain returned values""" 2024-10-04 06:53:43 +09:00
Egor Zhdan
0c106006db [Glibc] Remove Android gyb logic from the modulemap
This is a minor cleanup of the generated Glibc modulemap.

Android no longer uses the Glibc modulemap since 57b89d53.
2024-10-03 19:37:11 +01:00
swift-ci
4505e5a30d Merge remote-tracking branch 'origin/main' into rebranch 2024-10-03 09:35:14 -07:00
Egor Zhdan
535a9412df [cxx-interop] Conform std::map to ExpressibleByDictionaryLiteral
This adds an automatic conformance for `std::map` and `std::unordered_map` to Swift's `ExpressibleByDictionaryLiteral` protocol.

This makes it possible to pass a dictionary literal as an argument to a function that takes a `std::map` as parameter.

rdar://137126474
2024-10-03 13:33:40 +01:00
swift-ci
cd956f3b28 Merge remote-tracking branch 'origin/main' into rebranch 2024-10-03 04:53:49 -07:00
Egor Zhdan
9169d81bd5 Merge pull request #76830 from swiftlang/egorzhdan/cxx-set-array-literal
[cxx-interop] Conform `std::set` to `ExpressibleByArrayLiteral`
2024-10-03 12:44:07 +01:00
swift-ci
d9badbc2dd Merge remote-tracking branch 'origin/main' into rebranch 2024-10-03 03:17:27 -07:00
Konrad `ktoso` Malawski
f45f683f24 Merge pull request #76627 from swiftlang/revert-76623-revert-76595-wip-release-dist-execute-return 2024-10-03 19:15:59 +09:00
swift-ci
b8a5d2d6d7 Merge remote-tracking branch 'origin/main' into rebranch 2024-10-03 01:35:42 -07:00
Konrad `ktoso` Malawski
dea3b59331 Merge pull request #76250 from ktoso/wip-experimental-isolated-deinit 2024-10-03 17:19:10 +09:00
swift-ci
143233255c Merge remote-tracking branch 'origin/main' into rebranch 2024-10-02 22:33:49 -07:00
Kuba (Brecka) Mracek
762e7898de Merge pull request #76760 from kubamracek/embedded-asyncstream
[Concurrency] Include more pieces of Concurrency in Embedded (AsyncStream, continuations)
2024-10-02 22:23:17 -07:00
Alex Lorenz
f72ea6526f [stdlib][android] ignore the -Wgnu-offsetof-extensions in ExecutorChecks.cpp
ExecutorChecks.cpp no longer builds for android as -Wgnu -Werror is used for stdlib
2024-10-02 17:31:37 -07:00
swift-ci
78bf2cd399 Merge remote-tracking branch 'origin/main' into rebranch 2024-10-02 14:54:18 -07:00
Mike Ash
4c385e4334 Merge pull request #76797 from mikeash/isequal-nil
[Runtime] Handle nil parameter to -[SwiftObject isEqual:]
2024-10-02 17:51:43 -04:00
Ben Barham
eddc289fd9 Merge pull request #76761 from bnbarham/nostd-for-unicode
[embedded] Skip C++ stdlib for unicode stubs
2024-10-02 14:27:12 -07:00
Egor Zhdan
f37f42fc7e [cxx-interop] Conform std::set to ExpressibleByArrayLiteral
Swift's own `Set` conforms to `ExpressibleByArrayLiteral`. This change conforms instantiations of C++ `std::set` to `ExpressibleByArrayLiteral` as well.

This makes it possible to pass an array literal as an argument to a function that takes a `std::set` as parameter.

rdar://137126325
2024-10-02 19:27:51 +01:00
Kuba (Brecka) Mracek
4b68c3fa6f Merge pull request #76766 from kubamracek/embedded-dont-avoid-any-actor
[Concurrency] Drop the cloned code for Embedded around 'any Actor'
2024-10-02 10:47:49 -07:00
Kuba Mracek
ed441eb1bf [Concurrency] Include more pieces of Concurrency in Embedded (AsyncStream, continuations)
We have been only including a subset of files and functionality on Embedded Concurrency, let's instead include all the
source files, and have a fine grained opt out on things that don't yet work. Namely, this is still avoiding clocks, task
sleeping and custom executors.

Add a test for AsyncStream and continuations on Embedded Concurrency.
2024-10-02 09:22:36 -07:00
Egor Zhdan
7f597c63ae Merge pull request #76726 from swiftlang/egorzhdan/char8_t
[cxx-interop] Support `char8_t` C++20 type
2024-10-02 16:10:17 +01:00
eeckstein
4a069c9926 Merge pull request #76790 from eeckstein/add-ast-module
SwiftCompilerSources: introduce the AST module
2024-10-02 10:50:18 +02:00