TOSA: Support for TABLE operator (int8)
Added support to map TABLE operator to LUT.
Limitations:
-Only supported for int8
-TABLE input must be constant
This also adds the support for TFLite legalisation of
Tanh/Sigmoid (int8/uint8).
Signed-off-by: Patrik Gustavsson <patrik.gustavsson@arm.com>
Change-Id: I1a95f61fb02fdd42c4a690494418cc0765c8b275
diff --git a/ethosu/vela/tosa_mapping.py b/ethosu/vela/tosa_mapping.py
index ebbaa0a..f80a915 100644
--- a/ethosu/vela/tosa_mapping.py
+++ b/ethosu/vela/tosa_mapping.py
@@ -196,7 +196,6 @@
TosaOp.MAXIMUM,
TosaOp.MINIMUM,
TosaOp.POW,
- TosaOp.TABLE,
TosaOp.ABS,
TosaOp.BITWISE_NOT,
TosaOp.CEIL,
@@ -274,7 +273,8 @@
TosaOp.MUL: (Op.Mul, mul_attrs, None, TOSA_IFM_IFM2_INDICES),
# TODO TosaOp.POW
TosaOp.SUB: (Op.Sub, None, None, TOSA_IFM_IFM2_INDICES),
- # TODO TosaOp.TABLE
+ # TODO is table content in input[1] always constant?
+ TosaOp.TABLE: (Op.Table, None, None, TOSA_IFM_INDICES),
# TODO TosaOp.ABS
# TODO TosaOp.BITWISE_NOT
# TODO TosaOp.CEIL