profile
viewpoint

tbkka/llvm-project 0

The LLVM Project is a collection of modular and reusable compiler and toolchain technologies. Note: the repository does not accept github pull requests at this moment. Please submit your patches at http://reviews.llvm.org.

tbkka/protobuf 0

Protocol Buffers - Google's data interchange format

tbkka/swift 0

The Swift Programming Language

tbkka/swift-corelibs-foundation 0

The Foundation Project, providing core utilities, internationalization, and OS independence

tbkka/swift-llbuild 0

A low-level build system, used by Xcode and the Swift Package Manager

tbkka/swift-protobuf 0

Plugin and runtime library for using protobuf with Swift

pull request commentapple/swift

RCIdentity: fix another case of not-RC-identity-preserving casts.

I tried testing this PR combined with my PR #33761 on Ubuntu 16.04 and it looks good so far. (There was something strange with the merge, though, so it's possible I wasn't exactly testing what I hoped.)

eeckstein

comment created time in a day

Pull request review commentapple/swift

RCIdentity: fix another case of not-RC-identity-preserving casts.

 static CanType getHashableExistentialType(ModuleDecl *M) {   return hashable->getDeclaredInterfaceType()->getCanonicalType(); } +bool SILDynamicCastInst::isRCIdentityPreserving() const {+  // Casts which cast from a trivial type, like a metatype, to something which+  // is retainable, like an AnyObject, are not RC identity preserving.+  // On some platforms such casts dynamically allocate a ref-counted box for the+  // metatype. Naturally that is the place where a new rc-identity begins.+  // Therefore such a cast is introducing a new rc identical object.+  //+  // If RCIdentityAnalysis would look through such a cast, ARC optimizations+  // would get confused and might eliminate a retain of such an object+  // completely.+  if (getSourceLoweredType().isTrivial(*getFunction()))+    return false;++  CanType source = getSourceFormalType();+  CanType target = getTargetFormalType();++  // Be conservative with generic parameters.+  if (source->is<ArchetypeType>() || target->is<ArchetypeType>())

Oh? AnyObject -> Metatype casts can definitely happen. (Briefly: anything can be stored in an AnyObject via casting and can later be pulled back out with another cast.)

eeckstein

comment created time in 3 days

PullRequestReviewEvent

pull request commentapple/swift

[DynamicCast] Rely on runtime when casts can't be optimized

apple/swift#34383 @swift-ci Please test

tbkka

comment created time in 3 days

pull request commentapple/swift

[DynamicCast] Rely on runtime when casts can't be optimized

I believe #34383 will resolve the last test failure here.

tbkka

comment created time in 3 days

Pull request review commentapple/swift

RCIdentity: fix another case of not-RC-identity-preserving casts.

 static CanType getHashableExistentialType(ModuleDecl *M) {   return hashable->getDeclaredInterfaceType()->getCanonicalType(); } +bool SILDynamicCastInst::isRCIdentityPreserving() const {+  // Casts which cast from a trivial type, like a metatype, to something which+  // is retainable, like an AnyObject, are not RC identity preserving.+  // On some platforms such casts dynamically allocate a ref-counted box for the+  // metatype. Naturally that is the place where a new rc-identity begins.+  // Therefore such a cast is introducing a new rc identical object.+  //+  // If RCIdentityAnalysis would look through such a cast, ARC optimizations+  // would get confused and might eliminate a retain of such an object+  // completely.+  if (getSourceLoweredType().isTrivial(*getFunction()))+    return false;++  CanType source = getSourceFormalType();+  CanType target = getTargetFormalType();++  // Be conservative with generic parameters.+  if (source->is<ArchetypeType>() || target->is<ArchetypeType>())

This change came out of some tests I'm developing to stress the cast machinery. My tests uncovered problems with casts where one side is AnyObject and the other is a pointer type (metatype, class type, existential, etc). These cases were failing because the code was implicitly assuming that such casts simply copied a pointer, but my tests demonstrate cases where the AnyObject references a container structure that in turn holds the pointer in question. In these cases, retain/release of the AnyObject is not equivalent to retain/release on the contained pointer.

In particular, the previous logic could do the wrong thing in cases like the following:

   let source : AnyObject = ....
   // retain source for later use
  let result = source as? ClassType
  // Re-use source here

If source above is just a pointer to a class instance, then it is valid to sink the retain past the cast:

  let source : AnyObject = ClassType(). // <<== Simple case
  let result = source as? ClassType
  // retain source (which is the same pointer as result). <== THIS IS OK
  // Re-use source

But this transformation is not valid if source holds a pointer to a runtime container structure that in turn holds the class reference. In that case, the transformation above releases the container prematurely:

  let source : AnyObject = ... something gotten from somewhere ...
  // MUST retain `source` BEFORE the cast, since source may not be a simple class reference
  let result = source as? ClassType
  // Re-use source

This is primarily a concern when there are complex interactions with Obj-C code. The bridging support wraps Swift types into a variety of heap-allocated containers. The compiler cannot productively reason about these. They are being exchanged with Obj-C code that is not visible to the compiler, so their structure can really only be understood by dynamic inspection in the runtime casting code.

eeckstein

comment created time in 3 days

PullRequestReviewEvent

pull request commentapple/swift-protobuf

Enable module stability support.

What will happen if the application also uses SwiftProtobuf directly? Including a SwiftProtobuf binary along with your library could cause problems in that case.

mingchen

comment created time in 3 days

push eventtbkka/swift

Butta

commit sha 69d04aad08da3245f87c6a2df35869126d48b55e

[linux] remove absolute rpath of /usr/lib/swift/linux added to many shared libraries This was presumably added as a backup, in case the libraries in a toolchain couldn't be found, but will not work well, so take it out.

view details

Joe Groff

commit sha 3364c51b1d53fd22a3adbaf3d406bd6685535221

SIL: Verify invariants of async_continuation instructions. - Enforce types of continuations and resume/error BBargs for await - Can't access the continuation again or exit the function mid-suspend

view details

Pavel Yaskevich

commit sha 17f7ad82cac717a0be4e8417a136348fb0365ca9

[CSBindings] Record all of the protocol requirements (not just literal)

view details

Pavel Yaskevich

commit sha 0c51159228992019f029530844d7c482256b2ed2

[CSBindings] Record constraint associated with a subtype relationship While inferring bindings, let's record not only the fact that current type variable is a subtype of some other type variable but track constraint which establishes this relationship.

view details

Pavel Yaskevich

commit sha a9cce605a4a4062366ce7c4ef2afedd055e79f2c

[CSBindings] Shrink binding "sources" to supertype and equivalence only Instead of recording all of the binding "sources" let's only record subtype, supertype and equivalence relationships which didn't materialize as bindings (because other side is a type variable). This is the only information necessary to infer transitive bindings and protocol requirements.

view details

Pavel Yaskevich

commit sha d011bf3d7d72adc8235d336a202241f8cda62971

[CSBindings] Implement transtive protocol requirement inference Implements iterative protocol requirement inference through subtype, conversion and equivalence relationships. This algorithm doesn't depend on a type variable finalization order (which is currently the order of type variable introduction). If a given type variable doesn't yet have its transitive protocol requirements inferred, algorithm would use iterative depth-first walk through its supertypes and equivalences and incrementally infer transitive protocols for each type variable involved, transferring new information down the chain e.g. T1 T3 \ / T4 T5 \ / T2 Here `T1`, `T3` are supertypes of `T4`, `T4` and `T5` are supertypes of `T2`. Let's assume that algorithm starts at `T2` and none of the involved type variables have their protocol requirements inferred yet. First, it would consider supertypes of `T2` which are `T4` and `T5`, since `T5` is the last in the chain algorithm would transfer its direct protocol requirements to `T2`. `T4` has supertypes `T1` and `T3` - they transfer their direct protocol requirements to `T4` and `T4` transfers its direct and transitive (from `T1` and `T3`) protocol requirements to `T2`. At this point all the type variables in subtype chain have their transitive protocol requirements resolved and cached so they don't have to be re-inferred later.

view details

Pavel Yaskevich

commit sha 5dc9919aff788fc71ab69603db997f0a45ca258e

[ConstraintSystem] NFC: Make `SemaTest` a friend of `ConstraintSystem` This is necessary in order to have access to private members of a `ConstraintSystem` for testing purposes, such as logic related to potential binding computation.

view details

Pavel Yaskevich

commit sha 1aecea17e41bde3508326c9ae72c47b432ed5c15

[unittest/Sema] Add a helper method to infer bindings for a given type variable This mimics what `determineBestBindings` does but without sorting.

view details

Pavel Yaskevich

commit sha a24383112214c2a23a2008f5b704a0acb513b9fe

[unittest/Sema] Add a test-case for a single hop protocol requirement inference In situations like: `$T0 <convertible> $T1` `$T1 <conforms to> P` `$T0` should know about `P` as a transitive protocol requirement.

view details

Pavel Yaskevich

commit sha 8024b7bef3a3907299656eab5c0dc9ac844a5d05

[CSBindings] Improve equivalence class handling in transitive protocol inference Let all of the members of the equivalence class be represented by the first type variable encountered during the depth-first walk. This means that supertypes are inferred from the members and all of the transitive protocol requirements are distributed among the members upon return back to the "representative".

view details

Pavel Yaskevich

commit sha a3c3981a68f9672e48823fda0661c06df5c9fbc3

[unittest/Sema] NFC: Add a way to create a protocol with a given name and parent type

view details

Pavel Yaskevich

commit sha 9598f1984833a76aaa38cdb080bf997e28dacd1b

[unittest/Sema] Cover transitive protocol inference with unit tests

view details

Erik Eckstein

commit sha 007351223eb96a1a0132953a219b12d9b06ec0e7

MemBehavior: handle begin_access when checking for apply side-effects.

view details

Erik Eckstein

commit sha 68db2e7c6ce6f2bf9cdce1add556ef69971bc6a1

TempRValueOpt: don't use collectLoads in tryOptimizeStoreIntoTemp This refactoring removes a lot of special-casing in collectLoads and also makes tryOptimizeStoreIntoTemp simpler. It's a NFC.

view details

Erik Eckstein

commit sha 673b8873ab2930c0497944411a28070877883591

TempRValueOpt: refactoring: simplify the signature of collectLoads It's sufficient to pass the operand instead of the operand, the user and the operand value. NFC.

view details

Erik Eckstein

commit sha d569031f1a367281871ba18c92f385ffa0cafa7d

TempRValueOpt: move the mayWrite-check for applies from collectLoads to checkNoSourceModification ... where it belongs. This is mostly refactoring, but it also fixes a bug: we don't recurse into a begin_access in collectLoads. If there is an apply in such a scope, the mayWrite-check wouldn't be done. In checkNoSourceModification all instructions are visited, so the check is always done.

view details

Erik Eckstein

commit sha 7c293d8de960045fbe2d1717aa21481d801cd036

TempRValueOpt: fix the handling of begin_access Consider the related end_access instructions as uses to correctly mark the end of the lifetime of the temporary. This fixes a miscompile in case there is a modification of the copy-source between an begin_access and end_access.

view details

Erik Eckstein

commit sha 6310dfcc939d88664d1fb63a908f1139e9cf6b47

TempRValueOpt: fix the handling of load [take] load [take] was not considered as a use and it was not detected if it's in a different basic block. This fixes a miscompile in case there is a modification of the copy-source before a load [take]. rdar://problem/69757314

view details

Erik Eckstein

commit sha 9a10ec7d581345cbfcd15990c54848ca1b25dc8c

SILBuilder: add an API to insert _after_ an instruction. ... and use that API in FullApplySite::insertAfterInvocation. Also change FullApplySite::insertAfterInvocation/insertAfterFullEvaluation to directly pass a SILBuilder instead of just an insertion point to the callback. This makes more sense (given the function names) and simplifies the usages. It's a NFC.

view details

Erik Eckstein

commit sha 4557f151b1e90b874f77736bdf4ab20df8affe69

TempRValueOpt: fix the placement of destroy_addr in case of a copy_addr [take] Instead of reusing the existing destroy_addr (or load/copy_addr [take]) of the temporary, insert a new destroy_addr - at the correct location. This fixes a memory lifetime failure in case the copy-source is modified (actually: re-initialized) after the last use of the temporary: E.g. (before copy elimination): copy_addr [take] %src to [initialization] %temp %x = load %temp // last use of %temp store %y to [init] %src destroy_addr %temp The correct location for the destroy_addr is after the last use (after copy elimination): %x = load %src destroy_addr %src store %y to [init] %src rdar://problem/69757314

view details

push time in 4 days

delete branch tbkka/swift

delete branch : tbkka/rpathize-python3

delete time in 5 days

push eventapple/swift

tbkka

commit sha c5176c031594e84726adf4994ef4da864762525b

Update swift-rpathize.py to work with Python 3.8 and Python 2.7 (#34332) * Update swift-rpathize.py to work with Python 3.8 and Python 2.7 In Python 2, str() is also a kind of bytes blob In Python 3, str() is a Unicode string that's unrelated * Avoid `l` as a variable name Python-lint correctly warns about single-character variables that can be confused with numbers

view details

push time in 5 days

PR merged apple/swift

Update swift-rpathize.py to work with Python 3.8 and Python 2.7

Just need to explicitly convert the bytes blob into a real string before trying to pattern-match.

(In Python 2, str() and bytes are basically the same, so it's a lot more forgiving of such mixups.)

+2 -1

13 comments

1 changed file

tbkka

pr closed time in 5 days

push eventtbkka/swift

Butta

commit sha 69d04aad08da3245f87c6a2df35869126d48b55e

[linux] remove absolute rpath of /usr/lib/swift/linux added to many shared libraries This was presumably added as a backup, in case the libraries in a toolchain couldn't be found, but will not work well, so take it out.

view details

Joe Groff

commit sha 3364c51b1d53fd22a3adbaf3d406bd6685535221

SIL: Verify invariants of async_continuation instructions. - Enforce types of continuations and resume/error BBargs for await - Can't access the continuation again or exit the function mid-suspend

view details

Pavel Yaskevich

commit sha 17f7ad82cac717a0be4e8417a136348fb0365ca9

[CSBindings] Record all of the protocol requirements (not just literal)

view details

Pavel Yaskevich

commit sha 0c51159228992019f029530844d7c482256b2ed2

[CSBindings] Record constraint associated with a subtype relationship While inferring bindings, let's record not only the fact that current type variable is a subtype of some other type variable but track constraint which establishes this relationship.

view details

Pavel Yaskevich

commit sha a9cce605a4a4062366ce7c4ef2afedd055e79f2c

[CSBindings] Shrink binding "sources" to supertype and equivalence only Instead of recording all of the binding "sources" let's only record subtype, supertype and equivalence relationships which didn't materialize as bindings (because other side is a type variable). This is the only information necessary to infer transitive bindings and protocol requirements.

view details

Pavel Yaskevich

commit sha d011bf3d7d72adc8235d336a202241f8cda62971

[CSBindings] Implement transtive protocol requirement inference Implements iterative protocol requirement inference through subtype, conversion and equivalence relationships. This algorithm doesn't depend on a type variable finalization order (which is currently the order of type variable introduction). If a given type variable doesn't yet have its transitive protocol requirements inferred, algorithm would use iterative depth-first walk through its supertypes and equivalences and incrementally infer transitive protocols for each type variable involved, transferring new information down the chain e.g. T1 T3 \ / T4 T5 \ / T2 Here `T1`, `T3` are supertypes of `T4`, `T4` and `T5` are supertypes of `T2`. Let's assume that algorithm starts at `T2` and none of the involved type variables have their protocol requirements inferred yet. First, it would consider supertypes of `T2` which are `T4` and `T5`, since `T5` is the last in the chain algorithm would transfer its direct protocol requirements to `T2`. `T4` has supertypes `T1` and `T3` - they transfer their direct protocol requirements to `T4` and `T4` transfers its direct and transitive (from `T1` and `T3`) protocol requirements to `T2`. At this point all the type variables in subtype chain have their transitive protocol requirements resolved and cached so they don't have to be re-inferred later.

view details

Pavel Yaskevich

commit sha 5dc9919aff788fc71ab69603db997f0a45ca258e

[ConstraintSystem] NFC: Make `SemaTest` a friend of `ConstraintSystem` This is necessary in order to have access to private members of a `ConstraintSystem` for testing purposes, such as logic related to potential binding computation.

view details

Pavel Yaskevich

commit sha 1aecea17e41bde3508326c9ae72c47b432ed5c15

[unittest/Sema] Add a helper method to infer bindings for a given type variable This mimics what `determineBestBindings` does but without sorting.

view details

Pavel Yaskevich

commit sha a24383112214c2a23a2008f5b704a0acb513b9fe

[unittest/Sema] Add a test-case for a single hop protocol requirement inference In situations like: `$T0 <convertible> $T1` `$T1 <conforms to> P` `$T0` should know about `P` as a transitive protocol requirement.

view details

Pavel Yaskevich

commit sha 8024b7bef3a3907299656eab5c0dc9ac844a5d05

[CSBindings] Improve equivalence class handling in transitive protocol inference Let all of the members of the equivalence class be represented by the first type variable encountered during the depth-first walk. This means that supertypes are inferred from the members and all of the transitive protocol requirements are distributed among the members upon return back to the "representative".

view details

Pavel Yaskevich

commit sha a3c3981a68f9672e48823fda0661c06df5c9fbc3

[unittest/Sema] NFC: Add a way to create a protocol with a given name and parent type

view details

Pavel Yaskevich

commit sha 9598f1984833a76aaa38cdb080bf997e28dacd1b

[unittest/Sema] Cover transitive protocol inference with unit tests

view details

Erik Eckstein

commit sha 007351223eb96a1a0132953a219b12d9b06ec0e7

MemBehavior: handle begin_access when checking for apply side-effects.

view details

Erik Eckstein

commit sha 68db2e7c6ce6f2bf9cdce1add556ef69971bc6a1

TempRValueOpt: don't use collectLoads in tryOptimizeStoreIntoTemp This refactoring removes a lot of special-casing in collectLoads and also makes tryOptimizeStoreIntoTemp simpler. It's a NFC.

view details

Erik Eckstein

commit sha 673b8873ab2930c0497944411a28070877883591

TempRValueOpt: refactoring: simplify the signature of collectLoads It's sufficient to pass the operand instead of the operand, the user and the operand value. NFC.

view details

Erik Eckstein

commit sha d569031f1a367281871ba18c92f385ffa0cafa7d

TempRValueOpt: move the mayWrite-check for applies from collectLoads to checkNoSourceModification ... where it belongs. This is mostly refactoring, but it also fixes a bug: we don't recurse into a begin_access in collectLoads. If there is an apply in such a scope, the mayWrite-check wouldn't be done. In checkNoSourceModification all instructions are visited, so the check is always done.

view details

Erik Eckstein

commit sha 7c293d8de960045fbe2d1717aa21481d801cd036

TempRValueOpt: fix the handling of begin_access Consider the related end_access instructions as uses to correctly mark the end of the lifetime of the temporary. This fixes a miscompile in case there is a modification of the copy-source between an begin_access and end_access.

view details

Erik Eckstein

commit sha 6310dfcc939d88664d1fb63a908f1139e9cf6b47

TempRValueOpt: fix the handling of load [take] load [take] was not considered as a use and it was not detected if it's in a different basic block. This fixes a miscompile in case there is a modification of the copy-source before a load [take]. rdar://problem/69757314

view details

Erik Eckstein

commit sha 9a10ec7d581345cbfcd15990c54848ca1b25dc8c

SILBuilder: add an API to insert _after_ an instruction. ... and use that API in FullApplySite::insertAfterInvocation. Also change FullApplySite::insertAfterInvocation/insertAfterFullEvaluation to directly pass a SILBuilder instead of just an insertion point to the callback. This makes more sense (given the function names) and simplifies the usages. It's a NFC.

view details

Erik Eckstein

commit sha 4557f151b1e90b874f77736bdf4ab20df8affe69

TempRValueOpt: fix the placement of destroy_addr in case of a copy_addr [take] Instead of reusing the existing destroy_addr (or load/copy_addr [take]) of the temporary, insert a new destroy_addr - at the correct location. This fixes a memory lifetime failure in case the copy-source is modified (actually: re-initialized) after the last use of the temporary: E.g. (before copy elimination): copy_addr [take] %src to [initialization] %temp %x = load %temp // last use of %temp store %y to [init] %src destroy_addr %temp The correct location for the destroy_addr is after the last use (after copy elimination): %x = load %src destroy_addr %src store %y to [init] %src rdar://problem/69757314

view details

push time in 5 days

pull request commentapple/swift

Update swift-rpathize.py to work with Python 3.8 and Python 2.7

@swift-ci Please clean test macOS

tbkka

comment created time in 5 days

pull request commentapple/swift

Update swift-rpathize.py to work with Python 3.8 and Python 2.7

@swift-ci Please test macOS

tbkka

comment created time in 5 days

pull request commentapple/swift

Update swift-rpathize.py to work with Python 3.8 and Python 2.7

@swift-ci Please test macOS

tbkka

comment created time in 5 days

pull request commentapple/swift

[DynamicCast] Rely on runtime when casts can't be optimized

Same cast was in a disabled test in Casts.swift, so I also enabled that unconditionally.

With that, I can now consistently reproduce it on Linux. The root cause seems to be another variation of the ARC issue that @eeckstein fixed for me earlier. As before, it fails on Linux because it triggers __SwiftValue boxing which behaves slightly differently on Linux than on macOS.

tbkka

comment created time in 5 days

PullRequestReviewEvent

pull request commentapple/swift

When parsing floating-point from String, underflow to 0, overflow to ∞

Right now, this is failing only on an invalid JSON parsing test in swift-corelibs-foundation. I've filed apple/swift-corelibs-foundation#2903 to remove the invalid test, at which point this should be fine.

tbkka

comment created time in 8 days

pull request commentapple/swift

Update swift-rpathize.py to work with Python 3.8 and Python 2.7

@swift-ci Please test macOS

tbkka

comment created time in 8 days

pull request commentapple/swift

[DynamicCast] Rely on runtime when casts can't be optimized

Let's see if the test that's been failing on Linux also fails on macOS when you enable it properly.

tbkka

comment created time in 8 days

pull request commentapple/swift

[DynamicCast] Rely on runtime when casts can't be optimized

@swift-ci Please test

tbkka

comment created time in 8 days

push eventtbkka/swift

Tim Kientzle

commit sha 4c3818b895f866fc73259742b62134be91999ffe

Enable another casting test I think this exercises the same optimizer path that's breaking another test I've been staring at.

view details

push time in 8 days

push eventtbkka/swift

push time in 8 days

PR opened apple/swift-corelibs-foundation

Reviewers
Remove an invalid numeric JSON test

The value 2.7976931348623158e+308 is a perfectly valid JSON number and should be accepted. This test is only passing today because the Swift standard library's Double(_ String:) initializer currently has a bug that rejects numbers larger than the maximum Double value.

But we're getting ready to fix that bug in the Swift standard library, (apple/swift#34339) which will break this test when it lands.

(After that PR lands, we should update this again to verify that this value parses to Double.infinity.)

+0 -1

0 comment

1 changed file

pr created time in 8 days

create barnchtbkka/swift-corelibs-foundation

branch : main

created branch time in 8 days

pull request commentapple/swift

[DynamicCast] Rely on runtime when casts can't be optimized

@swift-ci Please test

tbkka

comment created time in 8 days

push eventtbkka/swift

push time in 8 days

push eventtbkka/swift

Mike Ash

commit sha ece0399d601eec1069131f465bdbe7e16f4c6a50

[Runtime] Have ConcurrentReadableHashMap use 1-byte or 2-byte indices when possible.

view details

Alexey Komnin

commit sha 4fa17bf59774ae6543a33b1a29f01320705f4dfe

SR-12022: refactor LiteralExpr to combine common initializer code

view details

Simon Evans

commit sha 960d0e30ee2b70ba3bb7ec076c16045afab01589

Linux: Fix -static-executable and remove swiftImageInspectionShared - Remove references to swiftImageInspectionShared on Linux and dont have split libraries between static/non-static linked executables. - -static-executable now links correctly Linux. Note: swift::lookupSymbol() will not work on statically linked executables but this can be worked around by using the https://github.com/swift-server/swift-backtrace package.

view details

Alexis Laferrière

commit sha c6fc53e844ac4fd542adb0669ac7038c2919d283

[Sema] Define availability via compiler flag 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

view details

Alexis Laferrière

commit sha 5ed261683d5973ef4dd45922b5ac77ba7cefcf43

[Sema] Report availability macros in inlinable code 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.

view details

Nate Chandler

commit sha b90cab6f1b5e7cb2ccb8b123e7fa5a00d022182c

[NFC] Made indexing on AsyncContextLayout private. Previously the methods for getting the index into the layout were public and were being used to directly access the underlying buffer. Here, that abstraction leakage is fixed and field access is forced to go through the appropriate methods.

view details

Nate Chandler

commit sha f6bfd416aba04a75da4ea7ab017e7a07665d4102

[NFC] Use TypeInfo for indirect return storage. Previously a raw CreateLoad was used, which happened to be fine. Here, a TI is used, explicitly clarifying that the indirect return is taken.

view details

Nate Chandler

commit sha d5d65b0dff6a5a027653a84a846baae33c123f55

[NFC] Removed unused method.

view details

Michael Gottesman

commit sha d3e6ffdbad9ed2af857508891a4530b7f11d4c6e

[lldb-toolbox] Add the ability to disassemble-to-file a specific function 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.

view details

Josh Learn

commit sha 5c3814e4dd0f3d0cd0a4776dbaebd3751bc8e985

[OSSignpost] Update apinotes to allow usage of os_signpost ABI entrypoint Currently, the `_os_signpost_emit_with_name_impl` function is not available to be called from Swift. This is the main ABI entrypoint for making os_signpost calls. In order to facilitate more efficient calls to os_signpost in future iterations of the Swift os_signpost API, we need to allow calling this function from Swift. rdar://70015938

view details

Nate Chandler

commit sha eba39cffe6ee2ad3602ac209359c4ffb5065a5b0

[Concurrency] Corrected ordering of indirect results. Previously, the indirect results were claimed from the explosion after the arguments were claimed. That failed to match the order in which arguments actually appear in the explosion. Here the order is reversed.

view details

Nate Chandler

commit sha 7d74a8614db13b3821f85d77c4fdcf511c8cbf15

[Concurrency] Async CC supports witness methods. Previously, the AsyncContextLayout did not make space for the trailing witness fields (self metadata and self witness table) and the AsyncNativeCCEntryPointArgumentEmission could consequently not vend these fields. Here, the fields are added to the layout.

view details

Nate Chandler

commit sha 0a5df673edce66633e41215cc0d2a44891d3d29d

[NFC] Deduped async entry point emission code. Previously the same code was used for loading values from the async context. Here, that same code is extracted into a private method.

view details

Nate Chandler

commit sha 6e0d89432533b29311d7f1afcdae360aa81b1f61

[NFC] Deduped async call emission code. Previously the same code was used for saving values into the async context. Here, that code is extracted into a private method.

view details

Nate Chandler

commit sha 4c298db5297f88f3eba35d03063847494befa41b

[NFC] Extracted async call emission loading. Previously the code for loading indirect returns was inline in the member function where it was performed. Here it is pulled out into a private method.

view details

Dave Lee

commit sha 27330f169df5d2dcb018ab2c6615d66be91d04e2

[build] Remove unused lldb cmake

view details

Egor Zhdan

commit sha 3708e7bbd5f1161121189de7cb201693e2357c8c

WinSDK: extract Security submodule with winscard.h Currently this header gets included into `WinSDK.WinSock2` via windows.h

view details

Slava Pestov

commit sha 824ecdd0aa9da889c13a3266b6f31d8194062707

ASTScope: Fix AttachedPropertyWrapperScope source range The source range needs to contain the argument expression.

view details

Slava Pestov

commit sha 66873b94c9c4adada9cdef3fa4866325f1050b35

ASTScope: Fix SubscriptDeclScope source range The source range needs to contain any attributes on the subscript declaration, since those might create child scopes (@_specialize, property wrappers, etc).

view details

Slava Pestov

commit sha 2e67c135fd286c9b942c79524aad739720f1cf3c

ASTScope: Rework ConditionalClauseScopes The top-level scope for a conditional clause with a pattern is now ConditionalClausePatternUseScope, which introduces the pattern's bindings. Since the patterns are not visible in their own initializer, a new ConditionalClauseInitializerScope is used for the initializer. While it is nested inside of the ConditionalClausePatternUseScope, it's lookup parent skips one level, giving us the desired behavior.

view details

push time in 8 days

push eventtbkka/swift

Luciano Almeida

commit sha 883d583a2fc6e5c74a58b379ba19a5d2907dabdd

[CSSimplify] Make sure visit and record holes recursivelly for dependent member type

view details

Luciano Almeida

commit sha 885815227f6c1321e48fa2a2300171306719c6fc

[tests] Add regression tests for SR-13732

view details

Mishal Shah

commit sha 23cde90b29bb2a0cf02dfee9fe45e7a5c36ec7b4

Update the Xcode version in How to Guides

view details

Mishal Shah

commit sha bd6cc586d5c8d826c798993e21e86477b70805db

Update the Xcode version in Getting Started doc

view details

Luciano Almeida

commit sha 907b06901f4fc114f1295cc3c3547b454c3bc2e9

Merge pull request #34330 from LucianoPAlmeida/SR-13732-crash-invalid [SR-13732] [Sema] Fix crash on simplifyFix constraint for tuple mismatch

view details

push time in 8 days

pull request commentapple/swift

Update swift-rpathize.py to work with Python 3.8 and Python 2.7

@swift-ci Please test macOS

tbkka

comment created time in 8 days

pull request commentapple/swift

Update swift-rpathize.py to work with Python 3.8 and Python 2.7

macOS CI seems to be having problems apparently unrelated to this PR. I'll resubmit.

tbkka

comment created time in 8 days

pull request commentapple/swift

When parsing floating-point from String, underflow to 0, overflow to ∞

@swift-ci Please test

tbkka

comment created time in 8 days

PR opened apple/swift

When parsing floating-point from String, underflow to 0, overflow to ∞

Previously, overflow and underflow both caused this to return nil, which causes several problems:

  • It does not distinguish between a large but valid input and a malformed input. Float("3.402824e+38") is perfectly well-formed but returns nil
  • It differs from how the compiler handles literals. As a result, Float(3.402824e+38) is very different from Float("3.402824e+38")
  • It's inconsistent with Foundation Scanner()
  • It's inconsistent with other programming languages

Note: This is exactly the same as #25313 by @stephentyrone

Fixes rdar://problem/36990878

+9 -22

0 comment

3 changed files

pr created time in 8 days

create barnchtbkka/swift

branch : tbkka/floating-point-parsing-overunder

created branch time in 8 days

push eventtbkka/swift

Arnold Schwaighofer

commit sha 18777bfa94a2eece5ab8e935d5bc539ad3483a24

LoadableByAddress: Make sure that indirect return arguments are at the right type expansion rdar://70220886

view details

Doug Gregor

commit sha 2a3f4f6665df9ca62381faf13b0d50e8b06acf7b

[AST] Allow resolution of the @_typeEraser type when printing.

view details

swift-ci

commit sha dd62ccd99cc13c444854fcb38ecf9737f5c2d742

Merge pull request #34326 from DougGregor/type-eraser-resolution

view details

Slava Pestov

commit sha 1888724166059af496287d0272c21468926a3350

Sema: Disallow protocols from refining less available protocols Concrete types can conform to unavailable protocols because the witness table for the conformance is not required for use with the concrete type itself. However, protocols cannot have unavailable base protocols. I believe this was an oversight of the original implementation here.

view details

Slava Pestov

commit sha 8fd29a57cc8e829587596465ced7de6a88f7d289

Sema: Add some missing checks for where clauses on non-generic declarations Access control, availability and exportability checking missed these because of a baked-in assumption that getGenericParams() == nullptr rules out the presence of a trailing where clause.

view details

Slava Pestov

commit sha 027563733ad68846cea15034032d9d182e8a1154

AST: Disallow @available attributes on generic parameters This was a no-op and it doesn't make sense in the current model.

view details

Arnold Schwaighofer

commit sha b3e9a7f252019c7f0ecf008137f2ca232ac25804

Merge pull request #34324 from aschwaighofer/fix_opaque_indirect_return_results_loadable_by_address LoadableByAddress: Make sure that indirect return arguments are at the right type expansion

view details

Slava Pestov

commit sha 38c8bbd9a729f2aa09570bc51c31b92b68b7c2e2

Merge pull request #34325 from slavapestov/small-availability-fixes Small availability checking fixes

view details

push time in 8 days

push eventtbkka/swift

Tim Kientzle

commit sha a0d1e4e9913c7623f347ed70e00cb9e8aa392534

Avoid `l` as a variable name Python-lint correctly warns about single-character variables that can be confused with numbers

view details

push time in 8 days

pull request commentapple/swift

Update swift-rpathize.py to work with Python 3.8 and Python 2.7

@swift-ci Please test

tbkka

comment created time in 9 days

pull request commentapple/swift

Update swift-rpathize.py to work with Python 3.8 and Python 2.7

@swift-ci Python lint

tbkka

comment created time in 9 days

PR opened apple/swift

Reviewers
Update swift-rpathize.py to work with Python 3.8 and Python 2.7

Just need to explicitly convert the bytes blob into a real string before trying to pattern-match.

(In Python 2, str() and bytes are basically the same, so it's a lot more forgiving of such mixups.)

+2 -1

0 comment

1 changed file

pr created time in 9 days

push eventtbkka/swift

Tim Kientzle

commit sha be4e2a0a8e60018287775c6799e92d9b3242b2bb

Update swift-rpathize.py to work with Python 3.8 and Python 2.7 In Python 2, str() is also a kind of bytes blob In Python 3, str() is a Unicode string that's unrelated

view details

push time in 9 days

create barnchtbkka/swift

branch : tbkka/rpathize-python3

created branch time in 9 days

pull request commentapple/swift

[DynamicCast] Rely on runtime when casts can't be optimized

Still having trouble reproducing this locally. I'll try again with the exact build options used on the CI bot.

tbkka

comment created time in 9 days

delete branch tbkka/swift

delete branch : tbkka/Benchmark-fixes

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka/py3g

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka/py3f

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka/reflection-library-crash-54173375-5.3

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka/require-python3

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka/reflection-library-crash-54173375

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-floatparse-simplify

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-radar31154770

delete time in 9 days

delete branch tbkka/swift

delete branch : SR-5289

delete time in 9 days

delete branch tbkka/swift

delete branch : SR-7732

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-floating-point-printing-C

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka/py3e

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka/py3d

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka/benchmark-py3

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-rdar63392615-punycode

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-SR12486-Any.Protocol-cast-5.3

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-floatparse-simplify-2

delete time in 9 days

delete branch tbkka/swift

delete branch : SR-3871

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-radar59302422

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-radar59302422-swift-5.2

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-floatparse-2-revert

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-validation-test-Sema-sr8209

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-remoteMirror-swiftInOS

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-casting-stringBridgePerf

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-rdar60633988

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-remoteMirror-projectEnum

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-float16-format

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-decodable

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-pr31278-decodable-5.3

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-rdar63128221-demangler-OOB

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-rdar63128307-demangler-NULL

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-rdar63511132-demangler-OOB-5.3

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-rdar63128307-demangler-dmangleArchetype-5.3

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-rdar63342277-variadic-tuple-mangling

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka-SR12486-Any.Protocol-cast

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka/rdar64315441-disable-loaded_module_trace_swiftinterface

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka/py3h-gyb

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka/py3i

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka/py3j

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka/py3k

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka/py3m

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka/py3n

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka/PrintFloat-NaN-printing-SR13354

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka/cmake_on_nonLinux

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka/dynamicCastRework-Specification-c

delete time in 9 days

delete branch tbkka/swift

delete branch : tbkka/dynamicCastRework-optionalInjection

delete time in 9 days

delete branch tbkka/swift

delete branch : master

delete time in 9 days

create barnchtbkka/swift

branch : main

created branch time in 9 days

pull request commentapple/swift

[DynamicCast] Rely on runtime when casts can't be optimized

Re-ran the Linux test locally on Ubuntu 16.04 (required upgrading clang-3.8 to clang-12), and it all passes just fine. I guess I'll try again with the CI preset and see??

tbkka

comment created time in 10 days

pull request commentapple/swift

[DynamicCast] Rely on runtime when casts can't be optimized

Re-ran the full Linux test locally and it's passing for me. Hmmm.... I'll try the CI bot again and see if that still fails before I spend time digging further.

tbkka

comment created time in 12 days

pull request commentapple/swift

[DynamicCast] Rely on runtime when casts can't be optimized

@swift-ci Please test Linux

tbkka

comment created time in 12 days

pull request commentapple/swift

[DynamicCast] Rely on runtime when casts can't be optimized

Linux is crashing on the optimized form of this test:

[ RUN      ] BoxingCasts.test184(): Casting SwiftValueBox(AnyHashable(ClassInt)) to ClassInt
stderr>>> CRASHED: SIGSEGV
the test crashed unexpectedly
[     FAIL ] BoxingCasts.test184(): Casting SwiftValueBox(AnyHashable(ClassInt)) to ClassInt
tbkka

comment created time in 17 days

pull request commentapple/swift

[DynamicCast] Rely on runtime when casts can't be optimized

@swift-ci Please test

tbkka

comment created time in 17 days

pull request commentapple/swift

[DynamicCast] Rely on runtime when casts can't be optimized

Thanks to @eeckstein for fixing the ARC bug I was tripping over. Now let's try those tests again!

tbkka

comment created time in 17 days

push eventtbkka/swift

Slava Pestov

commit sha ab83d907ac4942f4d7bc05fef2d20e414af060ed

Sema: Fix cycle between closure type computation and EmittedMembersRequest EmittedMembersRequest needs a stable order for synthesized members to ensure that vtable layout is computed consistently across frontend jobs. This used to use the mangled name as the sort key. However, the mangling includes the type of all outer contexts, and if an outer type is a closure, we would need to compute the type of the closure. Computing the type of a closure might require type checking its body though, which would in turn type check the local class, which would invoke EmittedMembersRequest, introducing a cycle. Instead, let's use the DeclName and string-ified type as the sort key. This is simpler to compute than th mangled name, and breaks the cycle. Fixes <rdar://problem/67842221>.

view details

Eric Miotto

commit sha 853586fc072d22493116722c61dc57cfa2c363b4

[build] Reinstate CMAKE_CXX_FLAGS_${CFLAGS_BUILD_TYPE} for LLVM (#33745) Set those at the value pre #33388 -- this would avoid regressions of disk space usage (in particular around building Swift LTO) Addresses rdar://68091272

view details

Benjamin Barnard

commit sha 0bc48dea75ce2701ba7a8e43ed85b2f6125905d0

[stdlib] NFC: Fix typo in comment.

view details

Michael Gottesman

commit sha c3d4560819482fb63951e99165122c51f2a95853

Merge pull request #33738 from gottesmm/pr-9efce4c76360c760712e757a0517d02574d48203 [semantic-arc] Split out owned -> guaranteed phi opt into its own file.

view details

Michael Gottesman

commit sha 69eb6ce376b2a514ff264d0b6062c11990c13d15

[opt-remark] Add a new SIL testing option that works around not having decls in SIL for debug_value. Instead, in such a case, we use the name on the debug_value instead and just use as the loc the debug_value itself. This will let me write SIL test cases for opt-remark-gen. I am going to add SIL test cases for future changes (as well as swift ones) using this technique. I am going to in forthcoming commits fill in some tests for the current opt-remark-generation here. I just want to get in this part.

view details

Doug Gregor

commit sha 5665985c0db855f129a15e17a6ec68a1bcb57b2a

Merge pull request #33747 from DougGregor/generalize-get-emitted-members [AST] Generalize and rename ClassDecl::getEmittedMembers()

view details

Owen Voorhees

commit sha 9f2db6cddac0de1a40f2695441eff67f27cc1957

Merge pull request #33706 from owenv/prefix-map-diags [swift-driver-compatibility] Update diagnostic for *-prefix-map args

view details

Kuba (Brecka) Mracek

commit sha 5bf15f81b1b92b79187798a5a4e31f09e7879a60

Add a -ignore-always-inline frontend flag which ignores @inline(__always) attributes. (#33466)

view details

Michael Gottesman

commit sha c2eae53174d2e082c2d88cd1e172aba1519b3020

Merge pull request #33752 from gottesmm/pr-2ccb699f5b58f532d5c793ae1ebc4690b34fd466 [opt-remark] Add a new SIL testing option that works around not having decls in SIL for debug_value.

view details

3405691582

commit sha 38dd7d81922ff764b0f83e501ab748dcbd6694bc

[IRGen] Fix asserting local extern declarations. emitClangDecl interacts with clang and LLVM to achieve C interop. On the LLVM side, CodeGenModule::EmitGlobal asserts if the decl eventually passed to it is not a "file scoped" via VarDecl::isFileVarDecl. LLVM currently asserts on local extern variables in C headers passed to Swift when the definition exists outside that header. To fix this, we need to ensure that we are only passing Decls that do not trip the assertion but not unduly limit local extern variables when the corresponding definition exists inside that header. We can do that fairly simply by checking for isFileVarDecl just before we hand-off to clang. When the definition for the local extern variable exists inside the header, isFileVarDecl is true, and if it exists elsewhere, it is false. This matches up with the assert expectation on the LLVM side exactly. This indirectly addresses #28968, since that contains the only part of the Swift stdlib that uses a local extern variable, but any header that is used with Swift that contains a local extern variable will cause the compiler to assert when built with assertions enabled.

view details

Doug Gregor

commit sha a12963ad9d931138fe1d438bd1b812d97f765ddf

Merge pull request #33750 from slavapestov/fix-emitted-members-request-sorting Sema: Fix cycle between closure type computation and EmittedMembersRequest

view details

Michael Gottesman

commit sha 2daf1d20500f7f879f7ce071568e7f655c6e4504

[opt-remark] When looking for debug_value users, look modulo RC Identity preserving users. A key concept in late ARC optimization is "RC Identity". In short, a result of an instruction is rc-identical to an operand of the instruction if one can safely move a retain (release) from before the instruction on the result to one after on the operand without changing the program semantics. This creates a simple model where one can work on equivalence classes of rc-identical values (using a dominating definition generally as the representative) and thus optimize/pair retain, release. When preparing for late ARC optimization, the optimizer will normalize aggregate ARC operations (retain_value, release_value) into singular strong_retain, strong_release operations on leaf types of the aggregate that are non-trivial. As an example, a retain_value on a KlassPair would be canonicalized into two strong_retain, one for the lhs and one for the rhs. When this is done, the optimizer generally just creates new struct_extract at the point where the retain is. In such a case, we may have that the debug_value for the underlying type is actually on a reformed aggregate whose underlying parts we are retaining: ``` bb0(%0 : $Builtin.NativeObject): strong_retain %0 %1 = struct $Array(%0 : $Builtin.NativeObject, ...) debug_value %1 : $Array, ... ``` By looking through RC identical uses, we can handle a large subset of these cases without much effort: ones were there is a single owning pointer like Array. To handle more complex cases we would have to calculate an inverse access path needed to get back to our value and somehow deal with all of the complexity therein (I am sure we can do it I just haven't thought through all of the details). The only interesting behavior that this results in is that when we emit diagnostics, we just use the rc-identical transitive use debug_value's name without a projection path. This is because the source location associated with that debug_value is with a separate value that is rc-identical to the actual value that we visited during our opt-remark traversal up the def-use graph. Consider the following example below, noting the comments that show in the SIL itself what I attempted to explain above. ``` struct KlassPair { var lhs: Klass var rhs: Klass } struct StateWithOwningPointer { var state: TrivialState var owningPtr: Klass } sil @theFunction : $@convention(thin) () -> () { bb0: %0 = apply %getKlassPair() : $@convention(thin) () -> @owned KlassPair // This debug_value's name can be combined... debug_value %0 : $KlassPair, name "myPair" // ... with the access path from the struct_extract here... %1 = struct_extract %0 : $KlassPair, #KlassPair.lhs // ... to emit a nice diagnostic that 'myPair.lhs' is being retained. strong_retain %1 : $Klass // In contrast in the case below, we rely on looking through rc-identity uses // to find the debug_value. In this case, the source info associated with the // debug_value (%2) is no longer associated with the underlying access path we // have been tracking upwards (%1 is in our access path list). Instead, we // know that the debug_value is rc-identical to whatever value we were // originally tracking up (%1) and thus the correct identifier to use is the // direct name of the identifier alone (without access path) since that source // identifier must be some value in the source that by itself is rc-identical // to whatever is being manipulated. Thus if we were to emit the access path // here for na rc-identical use we would get "myAdditionalState.owningPtr" // which is misleading since ArrayWrapperWithMoreState does not have a field // named 'owningPtr', its subfield array does. That being said since // rc-identity means a retain_value on the value with the debug_value upon it // is equivalent to the access path value we found by walking up the def-use // graph from our strong_retain's operand. %0a = apply %getStateWithOwningPointer() : $@convention(thin) () -> @owned StateWithOwningPointer %1 = struct_extract %0a : $StateWithOwningPointer, #StateWithOwningPointer.owningPtr strong_retain %1 : $Klass %2 = struct $Array(%0 : $Builtin.NativeObject, ...) %3 = struct $ArrayWrapperWithMoreState(%2 : $Array, %moreState : MoreState) debug_value %2 : $ArrayWrapperWithMoreState, name "myAdditionalState" } ```

view details

Arnold Schwaighofer

commit sha 2330e610d0eeafddb8c17eddcad220ea3c9486f3

Merge pull request #33712 from aschwaighofer/irgen_ignore_metadata_fixed_sized_with_opaque_type_param IRGen: Ignore the metadata of fixed sized types with opaque result type parameters

view details

Xi Ge

commit sha 773eec1a713940e8bd9ac97e3ae36fe9908bb024

Merge pull request #33683 from nkcsgexi/clang-importer-options-refactor ClangImporter: refactor ClangImporterOptions to be ASTContext-owned. NFC

view details

Mishal Shah

commit sha bf7c03b1f6cce062e27684abe5018a723a594662

Support cross compile Xcode toolchain for Apple Silicon Support cross compile Xcode toolchain for Apple Silicon * Add CMake flag DCMAKE_OSX_ARCHITECTURES to LLVM * Add CMake flag DCMAKE_OSX_ARCHITECTURES to cmark * Add CMake flag DCMAKE_OSX_ARCHITECTURES to lldb * Add CMake flag DCMAKE_OSX_ARCHITECTURES to llbuild * Add llbuild CMake options array to provide DCMAKE_OSX_ARCHITECTURES * [Build System] Use one install package for cross compile hosts * Remove Lipo before non-build-script-impl products * Add support to only lipo without running installable package tests * [Build System] Support cross compile install prefix for SwiftPM product in Swift Build Support * Use cross compile toolchain path for indexstoredb and swift-driver * Use cross compile toolchain path for swiftpm, swiftsyntax, swiftformat, and skstresstester * Add cross compile toolchain support to Benchmarks, and fix the python lint issue in skstresstester.py * [SwiftPM] Add support for cross-compile-hosts flag to build swiftpm using bootstrap script

view details

Michael Gottesman

commit sha c8d4d168f7981fc0b6cadedd71c2e340c622bcb3

Revert "build-script: remove dead CMake options for Swift" This reverts commit 95102bc258a6b30ba2349d561ef56ea48c601cae. This is actually a dead option that is relied upon for some configurations. I am going to add a note to not touch the option. I talked with compnerd about this and they are cool with this. I think that we can redo this in a nicer way when we are further into the build-script-impl refactoring. I added a note to the code to explain that it isn't dead.

view details

Pavel Yaskevich

commit sha dadf2b47cc7e2e064649ad478d155494c64556d7

[ConstraintSystem] Track invalid function builder bodies to avoid duplicate diagnostics

view details

Pavel Yaskevich

commit sha d2f5e63773b0189e3f07621249c224f9266e20e1

[TypeChecker] NFC: Add test-case for rdar://problem/65983237

view details

Varun Gandhi

commit sha 4350a96303c474812523c1214f50ffda1f2e437a

Merge pull request #33640 from varungandhi-apple/vg-fix-module-trace-cycle [ModuleTrace] Handle cycle detection edge case in module trace emission (ep2).

view details

Rintaro Ishizaki

commit sha aa48494c7480a37e075ed59f9476301dfcf20022

[Serialization] Local allocate ModuleFileSharedCore.ModuleInterfacePath 'ModuleInterfacePath' is passed as 'StringRef' that memory used to reside in ASTContext. But 'ModuleFileSharedCore' should be 'ASTContext' independent. So copy it using its own allocator.

view details

push time in 18 days

issue openedmarcandrysco/Errol

Errol4: Incorrect exponent for values close to a power of 10

In testing a number of optimal formatting implementations for correctness, I've found the following serious error where Errol4 prints the wrong exponent:

Input: 0x1.6789e3750f79p-1017 Correct output: 9.999999999999999E-307 Errol4 prints: 9.999999999999999E-306

Note that the input here is the predecessor of a power of 10. This seems to be a pattern; Errol4 seems to have trouble with other numbers of this form.

created time in 18 days

more