Skip to content

Commit 2dda7a2

Browse files
Back out "Tests failing for exp op in xnnpack"
Differential Revision: D76350728 Pull Request resolved: #11525
1 parent 120eb85 commit 2dda7a2

File tree

10 files changed

+1
-147
lines changed

10 files changed

+1
-147
lines changed

backends/xnnpack/operators/__init__.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@
1919
op_dynamic_dequantize_ops,
2020
op_dynamic_quantize_ops,
2121
op_elu,
22-
op_exp,
2322
op_floor,
2423
op_gelu,
2524
op_hardswish,

backends/xnnpack/operators/op_exp.py

Lines changed: 0 additions & 52 deletions
This file was deleted.

backends/xnnpack/partition/config/__init__.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,10 @@
2525
ConstantPadConfig,
2626
DeQuantizedPerTensorConfig,
2727
DivConfig,
28-
# EluConfig,
29-
# ExpConfig, # Bug in XNNPACK with exp op
3028
FloorConfig,
3129
GeluConfig,
3230
HardswishConfig,
31+
# EluConfig,
3332
HardtanhConfig,
3433
LeakyReLUConfig,
3534
LogConfig,
@@ -81,7 +80,6 @@
8180
ClampConfig,
8281
DivConfig,
8382
# EluConfig, # Waiting for PyTorch Pin Update
84-
# ExpConfig, # Bug in XNNPACK with exp op
8583
FloorConfig,
8684
GeluConfig,
8785
HardtanhConfig,

backends/xnnpack/partition/config/generic_node_configs.py

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -336,13 +336,6 @@ def get_original_aten(self) -> Optional[torch._ops.OpOverload]:
336336
return torch.ops.aten.upsample_bilinear2d.vec
337337

338338

339-
class ExpConfig(GenericNodePartitionerConfig):
340-
target_name = "exp.default"
341-
342-
def supported_precision_types(self) -> List[ConfigPrecisionType]:
343-
return [ConfigPrecisionType.FP32]
344-
345-
346339
class FloorConfig(GenericNodePartitionerConfig):
347340
target_name = "floor.default"
348341

backends/xnnpack/partition/configs.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,6 @@
5959
exir_ops.edge.aten.sigmoid.default,
6060
exir_ops.edge.aten._softmax.default,
6161
exir_ops.edge.aten.cat.default,
62-
# exir_ops.edge.aten.exp.default, # Bug in XNNPACK with exp op
6362
exir_ops.edge.aten.elu.default,
6463
exir_ops.edge.aten.avg_pool2d.default,
6564
exir_ops.edge.aten.leaky_relu.default,

backends/xnnpack/runtime/XNNCompiler.cpp

Lines changed: 0 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1761,36 +1761,6 @@ Error defineELUNode(
17611761
return Error::Ok;
17621762
}
17631763

1764-
/*
1765-
Define serialized exp node into the subgraph, using the remapped ids
1766-
to map the serialized ids, to the new ids generated when defining the
1767-
tensor value
1768-
*/
1769-
Error defineExpNode(
1770-
xnn_subgraph_t subgraph_ptr,
1771-
const std::unordered_map<uint32_t, uint32_t>& remapped_ids,
1772-
const NodePtr node,
1773-
const fb_xnnpack::XNNGraph* graph) noexcept {
1774-
MAYBE_UNUSED(graph);
1775-
1776-
auto graph_node = node->xnode_union_as_XNNExp();
1777-
1778-
xnn_status status = xnn_define_exp(
1779-
subgraph_ptr,
1780-
remapped_ids.at(graph_node->input_id()),
1781-
remapped_ids.at(graph_node->output_id()),
1782-
graph_node->flags());
1783-
1784-
ET_CHECK_OR_RETURN_ERROR(
1785-
status == xnn_status_success,
1786-
Internal,
1787-
"Failed to create exp node %i with code: %s",
1788-
node->debug_handle(),
1789-
xnn_status_to_string(status));
1790-
1791-
return Error::Ok;
1792-
}
1793-
17941764
/*
17951765
Defines absolute value node into subgraph using the remapped ids to map the
17961766
serialized ids to the new ids generated when defining the tensor value
@@ -2151,7 +2121,6 @@ DefineNodeFunc getDefineNodeFunc(fb_xnnpack::XNodeUnion nodeType) {
21512121
_DEFINE(Negate)
21522122
_DEFINE(Square)
21532123
_DEFINE(ELU)
2154-
_DEFINE(Exp)
21552124
_DEFINE(Abs)
21562125
_DEFINE(PReLU)
21572126
_DEFINE(Concatenate2)

backends/xnnpack/serialization/runtime_schema.fbs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,6 @@ union XNodeUnion {
141141
XNNNegate: _XNNNode1x1,
142142
XNNSquare: _XNNNode1x1,
143143
XNNELU,
144-
XNNExp: _XNNNode1x1,
145144
XNNAbs: _XNNNode1x1,
146145
XNNPReLU: _XNNNode2x1,
147146
XNNConcatenate2: _XNNCat,

backends/xnnpack/serialization/schema.fbs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,6 @@ union XNodeUnion {
137137
XNNNegate: _XNNNode1x1,
138138
XNNSquare: _XNNNode1x1,
139139
XNNELU,
140-
XNNExp: _XNNNode1x1,
141140
XNNAbs: _XNNNode1x1,
142141
XNNPReLU: _XNNNode2x1,
143142
XNNConcatenate2: _XNNCat,

backends/xnnpack/serialization/xnnpack_graph_schema.py

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -291,11 +291,6 @@ class XNNCeiling(XNNNode1x1):
291291
pass
292292

293293

294-
@dataclass
295-
class XNNExp(XNNNode1x1):
296-
pass
297-
298-
299294
@dataclass
300295
class XNNGelu(XNNNode1x1):
301296
pass

backends/xnnpack/test/ops/test_exp.py

Lines changed: 0 additions & 45 deletions
This file was deleted.

0 commit comments

Comments
 (0)