aboutsummaryrefslogtreecommitdiff
path: root/arm_compute/core
diff options
context:
space:
mode:
authorMichalis Spyrou <michalis.spyrou@arm.com>2022-06-15 19:02:28 +0100
committerMichalis Spyrou <michalis.spyrou@arm.com>2022-06-27 14:05:05 +0000
commitb1fcefddf3f59219a9d7930d607175b7e6c39347 (patch)
tree34e95efded15194b3c8abe4ba3da308c3259301d /arm_compute/core
parent41eb2d92c89274200d59ff97653e2bd66819b310 (diff)
downloadComputeLibrary-b1fcefddf3f59219a9d7930d607175b7e6c39347.tar.gz
Implement new Elementwise Dynamic Fusion Operators: Div, Floor
Resolves: COMPMID-5355 Change-Id: I92f73fbe885f28bbe7b07965b90cfd807c93602f Signed-off-by: Michalis Spyrou <michalis.spyrou@arm.com> Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/7745 Comments-Addressed: Arm Jenkins <bsgcomp@arm.com> Benchmark: Arm Jenkins <bsgcomp@arm.com> Tested-by: Arm Jenkins <bsgcomp@arm.com> Reviewed-by: SiCong Li <sicong.li@arm.com>
Diffstat (limited to 'arm_compute/core')
-rw-r--r--arm_compute/core/experimental/OperatorGraph.h33
1 files changed, 28 insertions, 5 deletions
diff --git a/arm_compute/core/experimental/OperatorGraph.h b/arm_compute/core/experimental/OperatorGraph.h
index fd8fcd5c47..cab83c7f8b 100644
--- a/arm_compute/core/experimental/OperatorGraph.h
+++ b/arm_compute/core/experimental/OperatorGraph.h
@@ -176,17 +176,18 @@ Operator add_op_conv2d(OperatorGraph &graph, const Conv2dDescriptor &desc, OpTen
*/
void force_conv2d_method(OperatorGraph &graph, Operator conv2d, ConvolutionMethod method);
-/** Descriptor for Addition operation
+/** Descriptor for Elementwise binary operation
*
*/
-struct AddDescriptor
+struct ElementwiseDescriptor
{
/* TOSA compliant attribute parameters start */
/* TOSA compliant attribute parameters end */
/* Non-TOSA compliant attribute parameters start */
+ ArithmeticOperation op;
/* Non-TOSA compliant attribute parameters end */
};
-/** Add op Add to @p graph, and optionally describes fusion through passing of intermediate @ref OpTensor s
+/** Add op Elementwise to @p graph, and optionally describes fusion through passing of intermediate @ref OpTensor s
*
* @param[in,out] graph OperatorGraph where the operator is added to
* @param[in] desc Operator descriptor
@@ -196,12 +197,34 @@ struct AddDescriptor
*
* @return Operator
*/
-Operator add_op_elementwise_add(OperatorGraph &graph, const AddDescriptor &desc, OpTensor lhs, OpTensor rhs, OpTensor dst);
+Operator add_op_elementwise_op(OperatorGraph &graph, const ElementwiseDescriptor &desc, OpTensor lhs, OpTensor rhs, OpTensor dst);
+
+/** Descriptor for Floor operation
+ *
+ */
+struct FloorDescriptor
+{
+ /* TOSA compliant attribute parameters start */
+ /* TOSA compliant attribute parameters end */
+ /* Non-TOSA compliant attribute parameters start */
+ /* Non-TOSA compliant attribute parameters end */
+};
+/** Add op Floor to @p graph, and optionally describes fusion through passing of intermediate @ref OpTensor s
+ *
+ * @param[in,out] graph OperatorGraph where the operator is added to
+ * @param[in] desc Operator descriptor
+ * @param[in] src Source OpTensor
+ * @param[in] dst Destination OpTensor
+ *
+ * @return Operator
+ */
+Operator add_op_floor(OperatorGraph &graph, const FloorDescriptor &desc, OpTensor src, OpTensor dst);
bool operator==(const OpTensor &t0, const OpTensor &t1);
bool operator==(const Padding2D &pad0, const Padding2D &pad1);
bool operator==(const Conv2dDescriptor &conv2d0, const Conv2dDescriptor &conv2d1);
-bool operator==(const AddDescriptor &, const AddDescriptor &);
+bool operator==(const ElementwiseDescriptor &, const ElementwiseDescriptor &);
+bool operator==(const FloorDescriptor &, const FloorDescriptor &);
} // namespace dynamic_fusion
} // namespace experimental