Skip to content

Commit 01fe421

Browse files
committed
Revert "Merge pull request #80695 from mikeash/move-priority-escalation-define"
This reverts commit 1e96466, reversing changes made to cb0e1da.
1 parent 08bb8dd commit 01fe421

File tree

2 files changed

+11
-11
lines changed

2 files changed

+11
-11
lines changed

include/swift/ABI/Task.h

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -29,17 +29,6 @@
2929
#include "bitset"
3030
#include "queue" // TODO: remove and replace with our own mpsc
3131

32-
// Does the runtime provide priority escalation support?
33-
#ifndef SWIFT_CONCURRENCY_ENABLE_PRIORITY_ESCALATION
34-
#if SWIFT_CONCURRENCY_ENABLE_DISPATCH && \
35-
__has_include(<dispatch/swift_concurrency_private.h>) && __APPLE__ && \
36-
(defined(__arm64__) || defined(__x86_64__))
37-
#define SWIFT_CONCURRENCY_ENABLE_PRIORITY_ESCALATION 1
38-
#else
39-
#define SWIFT_CONCURRENCY_ENABLE_PRIORITY_ESCALATION 0
40-
#endif
41-
#endif /* SWIFT_CONCURRENCY_ENABLE_PRIORITY_ESCALATION */
42-
4332
namespace swift {
4433
class AsyncTask;
4534
class AsyncContext;

include/swift/Runtime/Concurrency.h

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,17 @@
4545
#define SWIFT_CONCURRENCY_ENABLE_DISPATCH 0
4646
#endif
4747

48+
// Does the runtime provide priority escalation support?
49+
#ifndef SWIFT_CONCURRENCY_ENABLE_PRIORITY_ESCALATION
50+
#if SWIFT_CONCURRENCY_ENABLE_DISPATCH && \
51+
__has_include(<dispatch/swift_concurrency_private.h>) && __APPLE__ && \
52+
(defined(__arm64__) || defined(__x86_64__))
53+
#define SWIFT_CONCURRENCY_ENABLE_PRIORITY_ESCALATION 1
54+
#else
55+
#define SWIFT_CONCURRENCY_ENABLE_PRIORITY_ESCALATION 0
56+
#endif
57+
#endif /* SWIFT_CONCURRENCY_ENABLE_PRIORITY_ESCALATION */
58+
4859
namespace swift {
4960
class DefaultActor;
5061
class TaskOptionRecord;

0 commit comments

Comments
 (0)