Commit Graph

27 Commits

Author SHA1 Message Date
swift-ci
6ea9995a81 Merge remote-tracking branch 'origin/main' into rebranch 2024-10-19 18:57:20 -07:00
Allan Shortlidge
cb578172ea Tests: Remove -disable-availability-checking in more tests that use concurrency.
Use the `%target-swift-5.1-abi-triple` substitution to compile the tests for
deployment to the minimum OS versions required for use of _Concurrency APIs,
instead of disabling availability checking.
2024-10-19 12:35:20 -07:00
Shubham Sandeep Rastogi
b14e8f0679 Fixup swift tests for DIExpression folding in Corosplit
The support for DIExpression constant folding has been added to the
Corosplit pass, this patch fixes up the swift tests that need to account
for the changes in the DIExpressions.
2024-09-10 15:02:02 -07:00
Felipe de Azevedo Piovezan
a321b0afe0 [DebugInfo] Update tests to expect new LLVM debug format 2024-07-23 11:06:12 -07:00
Felipe de Azevedo Piovezan
9f81e3ace6 [DebugInfo][NFC] Add 64-bit requirement to async tests
Since https://reviews.llvm.org/D158638, entry values are only produced for
64-bit architectures. As such, related tests need to be guarded by the
appropriate REQUIRES directive.
2023-10-26 08:52:25 -07:00
Felipe de Azevedo Piovezan
73f39af392 Merge remote-tracking branch 'origin/main' into felipe/fix_merge_opaque
The following tests required conflict resolutions, since upstream LLVM did a lot of
work to remove dbg.addr, and this work is not available to swift's main. At the
same time, swift's main changed these tests to enable opaque pointers.

```
both modified:   test/DebugInfo/async-let-await.swift
both modified:   test/DebugInfo/move_function_dbginfo.swift
both modified:   test/DebugInfo/move_function_dbginfo_async.swift
```

The conflicts are fairly easy to fix: we keep the "structure" of the CHECK
lines present in `next`, but replace all pointers with `ptr`.
2023-06-26 17:13:02 -04:00
Felipe de Azevedo Piovezan
1ed9df0a0c [DebugInfo] Update tests to use opaque ptrs 2023-06-16 15:05:44 -04:00
swift_jenkins
c3773953d1 Merge remote-tracking branch 'origin/main' into next 2023-06-15 17:38:08 -07:00
Arnold Schwaighofer
c1a93e0bde Move tests over to use the %use_no_opaque_pointers option 2023-06-14 10:49:48 -07:00
Felipe de Azevedo Piovezan
22aa61f13f [IRGenDebug] Remove generation of dbg.addr
These intrinsics were removed upstream LLVM and are equivalent to a dbg.value +
OP_deref.
2023-05-12 15:52:58 -04:00
Adrian Prantl
8c4dcc7c7d Update debuginfo tests for slightly shuffled i386 output
(cherry picked from commit 259480a7d0)
2021-09-04 19:37:53 -07:00
Adrian Prantl
259480a7d0 Update debuginfo tests for slightly shuffled i386 output 2021-09-04 17:16:01 -07:00
Adrian Prantl
29fd8d3344 Remove an extra load that was generated for coro shadow copies.
emitShadowCopyIfNeeded has some extra code that was added when function
arguments were moved out of the async context to ensure that they are being
lifetime-extended, and there is also code that generates an incorrect load from
the shadow copy. However, emitShadowCopyIfNeeded is supposed return either an
alloca or the value, and IRGenDebugInfo knows to describe the value in the
alloca already. The load is counterproductive it's only valid until whatever
register it ends up in is clobbered, whereas the alloca is valid throughout the
function.

This patch removes the load and updates the tests accordingly.

rdar://81805727
(cherry picked from commit cbb89c78de)
2021-08-13 14:40:04 -07:00
Adrian Prantl
da06fad181 Revert "Updated async debug info tests for upstream IR changes"
This reverts commit 63bd700d70.

(cherry picked from commit ec913af429)
2021-08-13 14:40:04 -07:00
Adrian Prantl
cbb89c78de Remove an extra load that was generated for coro shadow copies.
emitShadowCopyIfNeeded has some extra code that was added when function
arguments were moved out of the async context to ensure that they are being
lifetime-extended, and there is also code that generates an incorrect load from
the shadow copy. However, emitShadowCopyIfNeeded is supposed return either an
alloca or the value, and IRGenDebugInfo knows to describe the value in the
alloca already. The load is counterproductive it's only valid until whatever
register it ends up in is clobbered, whereas the alloca is valid throughout the
function.

This patch removes the load and updates the tests accordingly.

rdar://81805727
2021-08-13 14:39:07 -07:00
Adrian Prantl
ec913af429 Revert "Updated async debug info tests for upstream IR changes"
This reverts commit 63bd700d70.
2021-08-13 14:37:20 -07:00
Adrian Prantl
d623c5c3cd Updated async debug info tests for upstream IR changes
(cherry picked from commit 63bd700d70)
2021-08-13 14:36:21 -07:00
Adrian Prantl
63bd700d70 Updated async debug info tests for upstream IR changes 2021-08-13 14:35:26 -07:00
Doug Gregor
eeeea49764 Remove -enable-experimental-concurrency almost everywhere. 2021-07-26 21:24:43 -07:00
Doug Gregor
1e2012d816 Disable availability checking in tests that use concurrency 2021-07-20 12:46:26 -07:00
Adrian Prantl
3c428b2e47 Re-enable async debuginfo tests on arm64e. 2021-06-03 08:55:55 -07:00
Richard Wei
fb66de6126 Unify mangling operators for async, @Sendable, @differentiable and @noDerivative.
Repurpose mangling operator `Y` as an umbrella operator that covers new attributes on function types. Free up operators `J`, `j`, and `k`.

```
async ::= 'Ya'                             // 'async' annotation on function types
sendable ::= 'Yb'                          // @Sendable on function types
throws ::= 'K'                             // 'throws' annotation on function types
differentiable ::= 'Yjf'                   // @differentiable(_forward) on function type
differentiable ::= 'Yjr'                   // @differentiable(reverse) on function type
differentiable ::= 'Yjd'                   // @differentiable on function type
differentiable ::= 'Yjl'                   // @differentiable(_linear) on function type
```

Resolves rdar://76299796.
2021-04-07 17:49:10 -07:00
Arnold Schwaighofer
f7b4c7df07 Adjust tests to new resume partial function mangling 2021-03-19 07:26:43 -07:00
Arnold Schwaighofer
5b4e0566b9 [IRGen] Fix debug info for direct arguments/return values
Emit shadow copies in async functions and emit a load to get the value.
2021-03-17 07:41:10 -07:00
John McCall
6c879d6fd3 Change the async ABI to not pass the active task and executor.
Most of the async runtime functions have been changed to not
expect the task and executor to be passed in.  When knowing the
task and executor is necessary, there are runtime functions
available to recover them.

The biggest change I had to make to a runtime function signature
was to swift_task_switch, which has been altered to expect to be
passed the context and resumption function instead of requiring
the caller to park the task.  This has the pleasant consequence
of allowing the implementation to very quickly turn around when
it recognizes that the current executor is satisfactory.  It does
mean that on arm64e we have to sign the continuation function
pointer as an argument and then potentially resign it when
assigning into the task's resume slot.

rdar://70546948
2021-03-16 22:52:54 -04:00
Adrian Prantl
1a9992991f Fix test on watch simulator 2021-03-01 14:14:07 -08:00
Adrian Prantl
c2dc87cd6b Debug info support for let await result variables. 2021-02-24 12:55:24 -08:00