Skip to content

Merge main 2020-10-12 #1990

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 190 commits into from
Oct 14, 2020
Merged

Merge main 2020-10-12 #1990

merged 190 commits into from
Oct 14, 2020

Conversation

kateinoigakukun
Copy link
Member

No description provided.

mikeash and others added 30 commits September 24, 2020 15:28
Introduce availability macros defined by a frontend flag.
This feature makes it possible to set the availability
versions at the moment of compilation instead of having
it hard coded in the sources. It can be used by projects
with a need to change the availability depending on the
compilation context while using the same sources.

The availability macro is defined with the `-define-availability` flag:

swift MyLib.swift -define-availability "_iOS8Aligned:macOS 10.10, iOS 8.0" ..

The macro can be used in code instead of a platform name and version:
@available(_iOS8Aligned, *)
public func foo() {}

rdar://problem/65612624
Availability macros can’t be used in inlinable code
as inlinable is copied textually in the generated
swiftinterface files. Further would could lift this
limitation.
…tion from a target without running the target.

The routine already supports dumping the assembly to file if we are at a
breakpoint using the current frame. This adds a -n option so one can without
running just dump the assembly to a file of a specific function in a binary.
The driver will eventually use this to compute the input status of a merge-modules job.
Plumb the logic necessary to schedule merge-modules incrementally. This means that if any inputs jobs to merge-modules run, merge-modules is run. But, if they are all skipped, merge-modules will be skipped as well.

This requires some light special-casing of the legacy driver's incremental job handling because it assumes in a few places it can always extract a swiftdeps file. This invariant will be further broken when the precompile step for bridging headers is skipped as well.

rdar://65893400
Instead, let's rely on the existing source range assertions.
They will fire if we add two nodes with overlapping or
equal source ranges.
…parse-labeled-params

[Concurrency] Fix parsing bug async function types and labeled parameters
[Sema] Correct lvalue computation in `buildStorageRef` for synthesizing local accessors.
[Sema] Define availability specification macros with a frontend flag
…swift-driver build

This is required in order to build swift-driver using CMake on Linux
xymus and others added 26 commits October 12, 2020 19:13
Report unavailable overrides as a warning to avoid breaking sources.
…12dd582f8fad1c619207575

When converting load [copy] -> load_borrow, do not insert end_borrow if the block insert point is a dead end block.
Moves the declaration of SILParserTUState into a new private header file: SILParserState.h
RCIdentityAnalysis: some refactoring to improve clarity.
…ation

It has been related with `inferBindingsFor` but declaration was
left in the header.
…not be pointers.

Even values of trivial type can contain a Builtin.RawPointer, which can be used to read/write from/to.

To compensate for the removed check, enable the escape-analysis check in MemBehavior (as it was before).

This fixes a recently introduced miscompile.
rdar://problem/70220876
…actor

AST: Refactor SelfReferenceKind in preparation for swiftlang#33767
…lysis

SideEffectAnalysis: don't assume that arguments with trivial type can not be pointers.
…ze_exported

Preliminary support for `_specialize(exported: true, ...)`
[Sema] Fix availability checking in inlinable code
Converts one more doc file from `.rst` to Markdown for consistency.
…da4a2673fee297132b16b8d

[lldb-toolbox] Add the ability to disassemble-to-file a specific function from a target without running the target.
…ng scan-deps result

When building a set of command-line options required to build a Clang module, also add `NonPathCommandLine` from Clang's `ModuleDeps`. These flags are mandatory in order to build modules discovered by the scanner.

Resolves rdar://70212660
…text-finder-for-fallback-completion

[CodeCompletion] Reuse CompletionContextFinder for fallback completion when no typeCheckExpression call is made
The code here used to use the location of the nearest place to insert
attributes, which makes no sense. Use the pattern binding's location
instead to ensure that we actually replace the 'let' part of the
pattern every time.

rdar://69971194
In order to unblock the SwiftWASM project, which relies on an
incremental build of the Swift driver that relies on the merge-modules
job always being run. The situation appears to be something like this:

1) An incremental build is run
2) Temporary swiftmodule outputs are laid down
3) merge-modules is skipped
4) modulewrap is run anyways and reads the empty temp file

We should fix this by skipping modulewrap if we can skip merge-modules.
But for now, be conservative and fall back to the status quo behavior of
always running merge-modules whenever we encounter a modulewrap job.
…currentreadablehashmap

[Runtime] Change SimpleGlobalCache to use ConcurrentReadableHashMap instead of ConcurrentMap.
[Dependency Scanner] Always add NonPathCommandLine arguments from Clang scan-deps result
…ings-from-cs

[ConstraintSystem] NFC: Remove obsolete `getPotentialBindings` declar…
Schedule merge-modules When modulewrap Job is in the Queue
@kateinoigakukun kateinoigakukun marked this pull request as ready for review October 14, 2020 07:32
Copy link

@MaxDesiatov MaxDesiatov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lovely!

@MaxDesiatov MaxDesiatov merged commit d050ae7 into swiftwasm Oct 14, 2020
@kateinoigakukun kateinoigakukun deleted the katei/merge-main-2020-10-12 branch October 30, 2020 00:24
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.