diff options
author | Patrik Gustavsson <patrik.gustavsson@arm.com> | 2021-08-25 13:49:25 +0200 |
---|---|---|
committer | Patrik Gustavsson <patrik.gustavsson@arm.com> | 2021-09-03 14:37:43 +0200 |
commit | b081d67f3e96896ea0ca7426a18c5fe153419ee0 (patch) | |
tree | a62a36256836b9bebcf318fe71793ad800099267 /ethosu/vela/tosa_mapping.py | |
parent | df99510f04aef99d1b8e9be9bfcde8fc1738b65f (diff) | |
download | ethos-u-vela-b081d67f3e96896ea0ca7426a18c5fe153419ee0.tar.gz |
TOSA: Added support for ADD, SUB and MUL
Added support for ADD, SUB and MUL
Signed-off-by: Patrik Gustavsson <patrik.gustavsson@arm.com>
Change-Id: I52acdc126b16e2cf4096bcf7a77023ea7d204998
Diffstat (limited to 'ethosu/vela/tosa_mapping.py')
-rw-r--r-- | ethosu/vela/tosa_mapping.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/ethosu/vela/tosa_mapping.py b/ethosu/vela/tosa_mapping.py index 5d0dd33d..377f4552 100644 --- a/ethosu/vela/tosa_mapping.py +++ b/ethosu/vela/tosa_mapping.py @@ -166,7 +166,7 @@ rescale_attrs = AttrSerializer( "RescaleAttribute", ("input_zp", "output_zp", ("multiplier", is_vec), ("shift", is_vec), "scale32", "double_round", "per_channel"), ) -mul_attrs = AttrSerializer("MulAttribute", ("shift")) +mul_attrs = AttrSerializer("MulAttribute", ("shift",)) ars_attrs = AttrSerializer("ArithmeticRightShiftAttribute", ("round",)) condif_attrs = AttrSerializer("CondIfAttribute", (("then_branch"), ("else_branch"))) # TODO these are references while_attrs = AttrSerializer("WhileLoopAttribute", (("cond_branch"), ("body_branch"))) # TODO these are references @@ -195,7 +195,6 @@ unsupported_tosa_operators = { TosaOp.LOGICAL_XOR, TosaOp.MAXIMUM, TosaOp.MINIMUM, - TosaOp.MUL, TosaOp.POW, TosaOp.TABLE, TosaOp.ABS, @@ -275,7 +274,7 @@ tosa_operator_map = { # TODO TosaOp.LOGICAL_XOR # TODO TosaOp.MAXIMUM # TODO TosaOp.MINIMUM - # TODO TosaOp.MUL + 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 |