File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
mlir/lib/Conversion/XeVMToLLVM Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -423,7 +423,8 @@ class MemfenceToOCLPattern : public OpConversionPattern<MemfenceOp> {
423
423
break ;
424
424
default :
425
425
// GENERIC is not supported in OpenCL
426
- llvm_unreachable (" Fence only supports global and shared address spaces." );
426
+ return rewriter.notifyMatchFailure (
427
+ op, " Fence only supports global and shared address spaces." );
427
428
}
428
429
switch (op.getScope ()) {
429
430
case xevm::MemScope::WORKGROUP:
@@ -434,7 +435,8 @@ class MemfenceToOCLPattern : public OpConversionPattern<MemfenceOp> {
434
435
break ;
435
436
default :
436
437
// CLUSTER and SYSTEM are not supported in OpenCL
437
- llvm_unreachable (" unsupported xevm::MemoryScope" );
438
+ return rewriter.notifyMatchFailure (
439
+ op, " Fence only supports workgroup and device memory scopes." );
438
440
}
439
441
Type i32Type = rewriter.getI32Type ();
440
442
Value acqRel = rewriter.create <LLVM::ConstantOp>(loc, i32Type, 4 );
You can’t perform that action at this time.
0 commit comments