File tree 1 file changed +12
-5
lines changed
1 file changed +12
-5
lines changed Original file line number Diff line number Diff line change @@ -271,8 +271,6 @@ mlir::LogicalResult CIRGenFunction::buildCXXTryStmt(const CXXTryStmt &S) {
271
271
});
272
272
273
273
enterCXXTryStmt (S, catchOp);
274
- llvm_unreachable (" NYI" );
275
-
276
274
if (buildStmt (S.getTryBlock (), /* useCurrentScope=*/ true ).failed ())
277
275
return mlir::failure ();
278
276
exitCXXTryStmt (S);
@@ -385,12 +383,20 @@ mlir::Block *CIRGenFunction::buildLandingPad() {
385
383
case EHScope::Catch:
386
384
case EHScope::Cleanup:
387
385
case EHScope::Filter:
388
- llvm_unreachable (" NYI" );
389
386
if (auto *lpad = innermostEHScope.getCachedLandingPad ())
390
387
return lpad;
391
388
}
392
389
393
- llvm_unreachable (" NYI" );
390
+ {
391
+ // Save the current CIR generation state.
392
+ mlir::OpBuilder::InsertionGuard guard (builder);
393
+ assert (!UnimplementedFeature::generateDebugInfo () && " NYI" );
394
+ // FIXME(cir): handle CIR relevant landing pad bits, there's no good
395
+ // way to assert here right now and leaving one in break important
396
+ // testcases. Work to fill this in is coming soon.
397
+ }
398
+
399
+ return nullptr ;
394
400
}
395
401
396
402
mlir::Block *CIRGenFunction::getInvokeDestImpl () {
@@ -433,7 +439,8 @@ mlir::Block *CIRGenFunction::getInvokeDestImpl() {
433
439
LP = buildLandingPad ();
434
440
}
435
441
436
- assert (LP);
442
+ // FIXME(cir): this breaks important testcases, fix is coming soon.
443
+ // assert(LP);
437
444
438
445
// Cache the landing pad on the innermost scope. If this is a
439
446
// non-EH scope, cache the landing pad on the enclosing scope, too.
You can’t perform that action at this time.
0 commit comments