Skip to content

[pull] swiftwasm from main #5525

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 31 commits into from
Jun 15, 2023
Merged

[pull] swiftwasm from main #5525

merged 31 commits into from
Jun 15, 2023

Conversation

pull[bot]
Copy link

@pull pull bot commented Jun 15, 2023

See Commits and Changes for more details.


Created by pull[bot]

Can you help keep this open source service alive? 💖 Please sponsor : )

tristanlabelle and others added 30 commits June 9, 2023 16:41
ReflectionContext::allocationMetadataPointer() was reading the
metadata pointer from a wrong offset because of the out-of-sync struct
layouts and dump-generic-metadata was not working correctly.

This change resync's the layouts and adds a static_assert to verify
that the offsets match between GenericMetadataCacheEntry and
GenericCacheEntry.
SyntaxRewriters should use `rewrite` to create a new node, not `visit`.
`lib/swift/host` contains modules/libraries that are built by the host
compiler. Their `.swiftmodule` will never be able to be read, ignore
them entirely.
'self' within init accessor could only be used to refer to
properties listed in `initializes` and `accesses` attributes.
…s within init accessors

Only properties that are listed in 'initializes' and 'accesses'
attributes could be referenced within init accessor. Detect any
and all invalid member references in the solver.
…d before every terminator

This closes a hole where an early return could leave some
properties from `initializes(...)` list uninitialized.

For example:

```swift
init(initialValue) initializes(_a, _b) {
  _a = initialValue.0
  if _a > 0 {
    return
  }

  _b = initialValue.1
}
```

Here `_b` is not initialized when `_a > 0`.
… memberwise init

If init accessor initialize the same properties, let's emit them
in sequence and emit `destroy_addr` in-between to make sure that
there is no double initialization.
… be synthesized

If some of the properties with init accessors have out of order
accesses diagnose that while checking whether memberwise init
could be synthesized.
…tializes` intersect

If some property is initializable by one than one init accessor
let's not sythesize a memberwise initializer in that case because
it's ambiguous what is the best init accessor to use.
…ors should follow field order

Skip stored properties that are initialized via init accessors and
emit parameters/initializations in field order which allows us to
cover more use-cases.
@objcImpl extensions aren’t allowed to declare new conformances; instead, they should either be declared in the header or in an ordinary extensions. (If they were permitted, they’d be ignored.)

Fixes rdar://110669366.
We have two stacks that we set up during crash handling, both of
which were potentially misaligned.  This only tripped us up on
Ubuntu 20.04 on aarch64 - my guess is that maybe `clone()` aligns
the stack pointer on newer kernels which is why we didn't see it
on 22.04.

rdar://110743884
…ows-vs2022

Fix tests on Windows CI with VS2022
[Backtracing][Linux] Properly align the stacks.
Section scans (for metadata, protocols, etc.) can be costly. This change adds tracing calls to those scans so we can more easily see how much time is spent in these scans and where they're initiated.

This adds an os_signpost implementation controlled by SWIFT_STDLIB_TRACING, and a default empty implementation for when that's disabled.

rdar://110266743
…enum (swiftlang#66621)

Instantiating layout strings for generic types reduces code size and is expected to improve performance of generic value witnesses.
[Test] Use SyntaxRewriter.rewrite not visit
[Frontend] Ignore adjacent swiftmodule in compiler host modules
[Sema/SIL] Improve diagnostics related to init accessors
Diagnose conformances on @objcImpl extensions
Fix the swift-inspect dump-generic-metadata operation.
…meterized-protocol

AST: Fix logic error in TypeMatcher::visitParameterizedProtocolType()
@kateinoigakukun kateinoigakukun merged commit 113bf4e into swiftwasm Jun 15, 2023
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.