File tree Expand file tree Collapse file tree 2 files changed +18
-1
lines changed Expand file tree Collapse file tree 2 files changed +18
-1
lines changed Original file line number Diff line number Diff line change @@ -111,6 +111,15 @@ AsyncContextLayout irgen::getAsyncContextLayout(
111
111
typeInfos.push_back (&ti);
112
112
}
113
113
114
+ // TaskContinuationFunction * __ptrauth_swift_async_context_resume
115
+ // ResumeParent;
116
+ {
117
+ auto ty = SILType ();
118
+ auto &ti = IGF.IGM .getTaskContinuationFunctionPtrTypeInfo ();
119
+ valTypes.push_back (ty);
120
+ typeInfos.push_back (&ti);
121
+ }
122
+
114
123
// SwiftError *errorResult;
115
124
auto errorCanType = IGF.IGM .Context .getExceptionType ();
116
125
auto errorType = SILType::getPrimitiveObjectType (errorCanType);
Original file line number Diff line number Diff line change @@ -94,10 +94,12 @@ namespace irgen {
94
94
private:
95
95
enum class FixedIndex : unsigned {
96
96
Parent = 0 ,
97
- Error = 1 ,
97
+ ResumeParent = 1 ,
98
+ Error = 2 ,
98
99
};
99
100
enum class FixedCount : unsigned {
100
101
Parent = 1 ,
102
+ ResumeParent = 1 ,
101
103
Error = 1 ,
102
104
};
103
105
IRGenFunction &IGF;
@@ -114,6 +116,9 @@ namespace irgen {
114
116
SmallVector<ArgumentInfo, 4 > argumentInfos;
115
117
116
118
unsigned getParentIndex () { return (unsigned )FixedIndex::Parent; }
119
+ unsigned getResumeParentIndex () {
120
+ return (unsigned )FixedIndex::ResumeParent;
121
+ }
117
122
unsigned getErrorIndex () { return (unsigned )FixedIndex::Error; }
118
123
unsigned getFirstIndirectReturnIndex () {
119
124
return getErrorIndex () + getErrorCount ();
@@ -160,6 +165,9 @@ namespace irgen {
160
165
161
166
public:
162
167
ElementLayout getParentLayout () { return getElement (getParentIndex ()); }
168
+ ElementLayout getResumeParentLayout () {
169
+ return getElement (getResumeParentIndex ());
170
+ }
163
171
bool canHaveError () { return canHaveValidError; }
164
172
ElementLayout getErrorLayout () { return getElement (getErrorIndex ()); }
165
173
unsigned getErrorCount () { return (unsigned )FixedCount::Error; }
You can’t perform that action at this time.
0 commit comments