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

Merge Mondays updates into rebranch #69224

Merged
merged 44 commits into from
Oct 17, 2023
Merged

Merge Mondays updates into rebranch #69224

merged 44 commits into from
Oct 17, 2023

Conversation

etcwilde
Copy link
Member

Updating rebranch branch with updates from today.

kateinoigakukun and others added 30 commits October 8, 2023 06:56
Instead of emitting an warning to the diagnostic engine, return the
plugin loading error as the result of the request. So that the user
can decide to emit it as a warning or an error.
Update swift cache key computation mechanism from one cache key per
output, to one cache key per primary input file (for all outputs that
associated with that input).

The new schema allows fewer cache lookups while still preserving most of
the flexibility for batch mode and incremental mode.
The primary goal is to fix this warning:

$PROJECT_PATH/swift-project/swift/lib/Markup/LineList.cpp:46:10: warning: variable 'Col' set but not used [-Wunused-but-set-variable]
  size_t Col = 0;

I also rewrote the implementation to use StringRef functionality instead
of manually walking over the characters.
Serialization depended on a longstanding bug in NeedsNewVTableEntryRequest: For a member of a non-class, it always returned `true`, not `false`. It turns out this was because serialization was conflating the concepts of vtable entries and witness table entries, so it needed NeedsNewVTableEntryRequest to return true for members of protocols. Untangle this logic so that NeedsNewVTableEntryRequest can be given the logical behavior.
Introduce a new API to find the AST node that catches or rethrows an
error thrown from the given source location. Use it to determine the
thrown error type to use for type checking a `throw` statement, which
begins as `any Error` within a `do..catch` and is later refined.
…s/etc.

Whenever there is a throwing operation such as a call, subscript, or
property access, check that the error type thrown from that operation
can be caught/rethrown from the current context.
While it is not yet possible for an `AsyncSequence` to specify its
thrown error type (so it always throws `any Error`), check that `any
Error` is a suitable error type to be thrown in context.
…ly checker account for borrow scopes.

When rewriting uses of a noncopyable value, the move-only checker failed to take into account
the scope of borrowing uses when establishing the final lifetimes of values. One way this
manifested was when borrowed values get reabstracted from value to in-memory representations,
using a store_borrow instruction, the lifetime of the original borrow would be ended immediately
after the store_borrow begins rather than after the matching end_borrow. Fix this by, first,
changing `store_borrow` to be treated as a borrowing use of its source rather than an
interior-pointer use; this should be more accurate overall since `store_borrow` borrows the
entire source value for a well-scoped duration balanced by `end_borrow` instructions. That done,
change MoveOnlyBorrowToDestructureUtils so that when it sees a borrow use, it ends the borrow
at the end(s) of the use's borrow scope, instead of immediately after the beginning of the use.
[Markup] Fix warning in measureIndentation
…rework

[Caching] Change swift cache key computation
[embedded] When linking SIL vtables, also link superclass vtables
… interface types

The implementation of `SimpleDidSetRequest` currently depends on a
type-checked body for `didSet`, which in turn depends on the interface
type (for the thrown error type). Break that dependency in a silly way
for now.
…oid CI (apple#69189)

Update the Android doc with info about the latest LTS NDK not working.
…on (apple#69167)

We have some configurations in which we run a preset that only builds
the compiler, and then a few ones to tests such binary, e.g.

```
buildbot_incremental,tools=RA,stdlib=RD,build
buildbot_incremental,tools=RA,stdlib=RD,test=macOS,type=device
buildbot_incremental,tools=RA,stdlib=RD,test=iOS,type=simulator
buildbot_incremental,tools=RA,stdlib=RD,test=watchOS,type=simulator
```

Contrary to the other presets, in the first preset we did not specify
"--lit-args" since it is not necessary -- however that plays a part in
the configuration of compiler-rt, causing an unwanted rebuild when that
parameter is specified in the following preset.

Addresses rdar://116922016
Not every phi with a single incoming value can be coalesced.  Explicitly
check whether it is coalesceable and only coalesce it if so.
…e-cleanups

More associated conformance cleanups
…sting

SIL: Treat store_borrow as borrowing its source, and have the move-only checker account for borrow scopes.
…hecking

Check thrown error types of for applications/subscripts/property access
tshortli and others added 13 commits October 16, 2023 14:19
…echeck.

Until a swiftc with apple/swift-driver#1465 is
available widely, enable -experimental-skip-non-exportable-decls whenever
-experimental-lazy-typecheck is specified.

Resolves rdar://117020908
JSON decoder's error message include the ABI name specified by
'-module-abi-name'.
Add %target-codesign to IRGen/typed_throws_exec.swift
…04580c5b5f8c08e565992a1040

[test][IRGen] Split returnaddress related check into a separate file
[NFC] Correct AFD::needsNewVTableEntry()
…016/1/single-phi-incoming-value

[AddressLowering] Fixed single arg phi edge case.
…5571427

[Macros] Improve macro plugin loading macro definition resolution diagnostics
…kip-non-exportable

Frontend: Temporarily force decl skipping with -experimental-lazy-typecheck
Reapply [CMake] Add module ABI name prefix to swift-syntax libraries
…ibute

[Concurrency] Disallow Sendable annotation on methods of non-Sendable types
@etcwilde
Copy link
Member Author

@swift-ci please smoke test

@etcwilde
Copy link
Member Author

@swift-ci please smoke test

@etcwilde etcwilde merged commit 9aa1772 into apple:rebranch Oct 17, 2023
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet