Skip to content

Commit a5ab682

Browse files
committed
Outdated comment and turn check+failure into assert
1 parent 69721c0 commit a5ab682

File tree

2 files changed

+1
-3
lines changed

2 files changed

+1
-3
lines changed

mlir/include/mlir/Target/LLVMIR/LLVMImportInterface.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -167,8 +167,7 @@ class LLVMImportInterface
167167
// Lookup the dialect interface for the given intrinsic.
168168
// Verify the intrinsic identifier maps to an actual intrinsic.
169169
llvm::Intrinsic::ID intrinId = inst->getIntrinsicID();
170-
if (intrinId == llvm::Intrinsic::not_intrinsic)
171-
return failure();
170+
assert(intrinId != llvm::Intrinsic::not_intrinsic);
172171

173172
// First lookup intrinsic across different dialects for known
174173
// supported converstions, examples include arm-neon, nvm-sve, etc

mlir/lib/Target/LLVMIR/Dialect/LLVMIR/LLVMIRToLLVMTranslation.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,6 @@ convertUnregisteredIntrinsicImpl(OpBuilder &odsBuilder, llvm::CallInst *inst,
6363
LLVM::ModuleImport &moduleImport) {
6464
StringRef intrinName = inst->getCalledFunction()->getName();
6565

66-
// Sanity check the intrinsic ID.
6766
SmallVector<llvm::Value *> args(inst->args());
6867
ArrayRef<llvm::Value *> llvmOperands(args);
6968

0 commit comments

Comments
 (0)