Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 1 addition & 7 deletions clang/lib/CIR/CodeGen/CIRGenBuiltin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1349,13 +1349,7 @@ RValue CIRGenFunction::emitBuiltinExpr(const GlobalDecl GD, unsigned BuiltinID,
mlir::Type cirTy = convertType(E->getArg(0)->getType());
bool isIntTy = cir::isIntOrIntVectorTy(cirTy);
if (!isIntTy) {
mlir::Type eltTy = cirTy;
if (mlir::isa<cir::VectorType>(cirTy))
eltTy = mlir::cast<cir::VectorType>(cirTy).getEltType();
if (mlir::isa<cir::SingleType, cir::DoubleType>(eltTy)) {
return emitUnaryMaybeConstrainedFPBuiltin<cir::FAbsOp>(*this, *E);
}
llvm_unreachable("unsupported type for BI__builtin_elementwise_abs");
return emitUnaryFPBuiltin<cir::FAbsOp>(*this, *E);
}
mlir::Value arg = emitScalarExpr(E->getArg(0));
auto call = getBuilder().create<cir::AbsOp>(getLoc(E->getExprLoc()),
Expand Down
Loading