@@ -38,7 +38,7 @@ arrangeFreeFunctionLikeCall(LowerTypes <, LowerModule &LM,
38
38
cir_assert_or_abort (!::cir::MissingFeatures::isVarArg (), " NYI" );
39
39
40
40
if (::cir::MissingFeatures::extParamInfo ())
41
- llvm_unreachable (" NYI" );
41
+ cir_unreachable (" NYI" );
42
42
}
43
43
44
44
// TODO(cir): There's some CC stuff related to no-proto functions here, but
@@ -61,7 +61,7 @@ static void appendParameterTypes(SmallVectorImpl<Type> &prefix, FuncType fnTy) {
61
61
}
62
62
63
63
cir_tl_assert (MissingFeatures::extParamInfo ());
64
- llvm_unreachable (" NYI" );
64
+ cir_unreachable (" NYI" );
65
65
}
66
66
67
67
// / Arrange the LLVM function layout for a value of the given function
@@ -104,9 +104,9 @@ void LowerModule::constructAttributeList(StringRef Name,
104
104
CallingConv = FI.getCallingConvention ();
105
105
// FIXME(cir): No-return should probably be set in CIRGen (ABI-agnostic).
106
106
if (MissingFeatures::noReturn ())
107
- llvm_unreachable (" NYI" );
107
+ cir_unreachable (" NYI" );
108
108
if (MissingFeatures::csmeCall ())
109
- llvm_unreachable (" NYI" );
109
+ cir_unreachable (" NYI" );
110
110
111
111
// TODO(cir): Implement AddAttributesFromFunctionProtoType here.
112
112
// TODO(cir): Implement AddAttributesFromOMPAssumes here.
@@ -153,31 +153,31 @@ void LowerModule::constructAttributeList(StringRef Name,
153
153
case ABIArgInfo::Ignore:
154
154
break ;
155
155
default :
156
- llvm_unreachable (" Missing ABIArgInfo::Kind" );
156
+ cir_unreachable (" Missing ABIArgInfo::Kind" );
157
157
}
158
158
159
159
if (!IsThunk) {
160
160
if (MissingFeatures::qualTypeIsReferenceType ()) {
161
- llvm_unreachable (" NYI" );
161
+ cir_unreachable (" NYI" );
162
162
}
163
163
}
164
164
165
165
// Attach attributes to sret.
166
166
if (MissingFeatures::sretArgs ()) {
167
- llvm_unreachable (" sret is NYI" );
167
+ cir_unreachable (" sret is NYI" );
168
168
}
169
169
170
170
// Attach attributes to inalloca arguments.
171
171
if (MissingFeatures::inallocaArgs ()) {
172
- llvm_unreachable (" inalloca is NYI" );
172
+ cir_unreachable (" inalloca is NYI" );
173
173
}
174
174
175
175
// Apply `nonnull`, `dereferencable(N)` and `align N` to the `this` argument,
176
176
// unless this is a thunk function.
177
177
// FIXME: fix this properly, https://reviews.llvm.org/D100388
178
178
if (MissingFeatures::funcDeclIsCXXMethodDecl () ||
179
179
MissingFeatures::inallocaArgs ()) {
180
- llvm_unreachable (" `this` argument attributes are NYI" );
180
+ cir_unreachable (" `this` argument attributes are NYI" );
181
181
}
182
182
183
183
unsigned ArgNo = 0 ;
@@ -190,7 +190,7 @@ void LowerModule::constructAttributeList(StringRef Name,
190
190
191
191
// Add attribute for padding argument, if necessary.
192
192
if (IRFunctionArgs.hasPaddingArg (ArgNo)) {
193
- llvm_unreachable (" Padding argument is NYI" );
193
+ cir_unreachable (" Padding argument is NYI" );
194
194
}
195
195
196
196
// TODO(cir): Mark noundef arguments and return values. Although this
@@ -212,18 +212,18 @@ void LowerModule::constructAttributeList(StringRef Name,
212
212
[[fallthrough]];
213
213
case ABIArgInfo::Direct:
214
214
if (ArgNo == 0 && ::cir::MissingFeatures::chainCall ())
215
- llvm_unreachable (" ChainCall is NYI" );
215
+ cir_unreachable (" ChainCall is NYI" );
216
216
else if (AI.getInReg ())
217
- llvm_unreachable (" InReg attribute is NYI" );
217
+ cir_unreachable (" InReg attribute is NYI" );
218
218
// Attrs.addStackAlignmentAttr(llvm::MaybeAlign(AI.getDirectAlign()));
219
219
cir_tl_assert (!::cir::MissingFeatures::noFPClass ());
220
220
break ;
221
221
default :
222
- llvm_unreachable (" Missing ABIArgInfo::Kind" );
222
+ cir_unreachable (" Missing ABIArgInfo::Kind" );
223
223
}
224
224
225
225
if (::cir::MissingFeatures::qualTypeIsReferenceType ()) {
226
- llvm_unreachable (" Reference handling is NYI" );
226
+ cir_unreachable (" Reference handling is NYI" );
227
227
}
228
228
229
229
// TODO(cir): Missing some swift and nocapture stuff here.
@@ -243,7 +243,7 @@ void LowerModule::constructAttributeList(StringRef Name,
243
243
// / definition of the given function.
244
244
const LowerFunctionInfo &LowerTypes::arrangeFunctionDeclaration (FuncOp fnOp) {
245
245
if (MissingFeatures::funcDeclIsCXXMethodDecl ())
246
- llvm_unreachable (" NYI" );
246
+ cir_unreachable (" NYI" );
247
247
248
248
cir_tl_assert (!MissingFeatures::qualifiedTypes ());
249
249
FuncType FTy = fnOp.getFunctionType ();
@@ -283,7 +283,7 @@ const LowerFunctionInfo &LowerTypes::arrangeFreeFunctionType(FuncType FTy) {
283
283
const LowerFunctionInfo &LowerTypes::arrangeGlobalDeclaration (FuncOp fnOp) {
284
284
if (MissingFeatures::funcDeclIsCXXConstructorDecl () ||
285
285
MissingFeatures::funcDeclIsCXXDestructorDecl ())
286
- llvm_unreachable (" NYI" );
286
+ cir_unreachable (" NYI" );
287
287
288
288
return arrangeFunctionDeclaration (fnOp);
289
289
}
@@ -316,9 +316,9 @@ LowerTypes::arrangeLLVMFunctionInfo(Type resultType, FnInfoOpts opts,
316
316
317
317
// Compute ABI information.
318
318
if (CC == llvm::CallingConv::SPIR_KERNEL) {
319
- llvm_unreachable (" NYI" );
319
+ cir_unreachable (" NYI" );
320
320
} else if (::cir::MissingFeatures::extParamInfo ()) {
321
- llvm_unreachable (" NYI" );
321
+ cir_unreachable (" NYI" );
322
322
} else {
323
323
// NOTE(cir): This corects the initial function info data.
324
324
getABIInfo ().computeInfo (*FI); // FIXME(cir): Args should be set to null.
0 commit comments