Commit 17f6e08c authored by Nagy Mostafa's avatar Nagy Mostafa Committed by Scott Cyphers

Enable floating point relu (#3436)

parent 2f918038
......@@ -506,9 +506,6 @@ namespace
NGRAPH_CHECK(lhs->getType().isa<MemRefType>());
Type elemTy = lhs->getType().dyn_cast<MemRefType>().getElementType();
NGRAPH_CHECK(!elemTy.isa<FloatType>(),
"NGReluOp with float element type should not be lowered until MLIR supports "
"lowering !std.CmpF");
LoopNestBuilder(pivs, lbs, ubs, steps)([&] {
ValueHandle val = iLHS(ivs);
......
......@@ -331,19 +331,6 @@ bool MLIRSubgraphExtractionPass::is_supported_mlir_op(std::shared_ptr<Node> node
}
}
// Relu is supported for integer types only until MLIR adds support for lowering !std.CmpF to LLVM dialect
if (TI(ngraph::op::Relu) == TI(*node))
{
if (!node->get_element_type().is_integral())
{
return false;
}
else
{
return true;
}
}
if (TI(ngraph::op::Negative) == TI(*node))
{
return true;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment