aboutsummaryrefslogtreecommitdiff
path: root/src/core/NEON/kernels/arm_gemm/kernels/sve_hybrid_s8s32_dot_6x4VL.hpp
diff options
context:
space:
mode:
authorGeorgios Pinitas <georgios.pinitas@arm.com>2021-07-16 16:16:43 +0100
committerGeorgios Pinitas <georgios.pinitas@arm.com>2021-07-22 02:25:50 +0000
commit4ee8b1599dbaf7634d25607fa5ac96ba3dc6b0f2 (patch)
tree2f8362d33cdad4212f4b96995681c68184c759e1 /src/core/NEON/kernels/arm_gemm/kernels/sve_hybrid_s8s32_dot_6x4VL.hpp
parent59fd7a722e5bc7e85309d6200bc37a772721a719 (diff)
downloadComputeLibrary-4ee8b1599dbaf7634d25607fa5ac96ba3dc6b0f2.tar.gz
Update GEMM assembly kernels
- Introduce Fp32 kernels with internal calculations in Bfloat16 when fast_mode is enabled - Improve kernel selection heuristics Signed-off-by: Georgios Pinitas <georgios.pinitas@arm.com> Change-Id: I68a9e7e862b6fd2721b46e0d7cc791091c4ab279 Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/5965 Tested-by: Arm Jenkins <bsgcomp@arm.com> Comments-Addressed: Arm Jenkins <bsgcomp@arm.com>
Diffstat (limited to 'src/core/NEON/kernels/arm_gemm/kernels/sve_hybrid_s8s32_dot_6x4VL.hpp')
-rw-r--r--src/core/NEON/kernels/arm_gemm/kernels/sve_hybrid_s8s32_dot_6x4VL.hpp38
1 files changed, 35 insertions, 3 deletions
diff --git a/src/core/NEON/kernels/arm_gemm/kernels/sve_hybrid_s8s32_dot_6x4VL.hpp b/src/core/NEON/kernels/arm_gemm/kernels/sve_hybrid_s8s32_dot_6x4VL.hpp
index 37258978d3..b8ca7c5456 100644
--- a/src/core/NEON/kernels/arm_gemm/kernels/sve_hybrid_s8s32_dot_6x4VL.hpp
+++ b/src/core/NEON/kernels/arm_gemm/kernels/sve_hybrid_s8s32_dot_6x4VL.hpp
@@ -22,9 +22,10 @@
* IN THE SOFTWARE.
*/
#pragma once
-#ifdef ARM_COMPUTE_ENABLE_SVE
+#ifdef ARM_COMPUTE_ENABLE_SVE
#include "../std_transforms_sve.hpp"
+#include "../performance_parameters.hpp"
#define ARGLIST \
unsigned int, const unsigned int *, \
@@ -42,7 +43,8 @@ void sve_hybrid_s8s32_dot_6x4VL( ARGLIST );
class cls_sve_hybrid_s8s32_dot_6x4VL
{
public:
- typedef int8_t operand_type;
+ typedef int8_t lhs_operand_type;
+ typedef int8_t rhs_operand_type;
typedef int32_t result_type;
typedef void (*kern_type)( ARGLIST );
@@ -68,7 +70,36 @@ public:
return true;
}
- StdTransformsSVE<operand_type, result_type, 6, 4, 4> transforms = {};
+ StdTransformsSVE<rhs_operand_type, result_type, 6, 4, 4> transforms = {};
+ template<typename T>
+ static inline PerformanceParameters get_performance_parameters(const CPUInfo *ci)
+ {
+
+ if (std::is_same<T, int32_t>::value) {
+ switch (ci->get_cpu_model()) {
+ default:
+ return { 31.56 };
+ case CPUModel::A510:
+ return { 20.92 };
+ case CPUModel::V1:
+ return { 62.24 };
+ }
+ }
+
+
+ if (std::is_same<T, int8_t>::value) {
+ switch (ci->get_cpu_model()) {
+ default:
+ return { 31.60, 15.53, 0.62 };
+ case CPUModel::A510:
+ return { 22.77, 3.90, 0.47 };
+ case CPUModel::V1:
+ return { 62.97, 19.14, 0.92 };
+ }
+ }
+
+ return { 1.0 };
+ }
// Default to the generic kernel
kern_type kernel=sve_hybrid_s8s32_dot_6x4VL;
@@ -80,4 +111,5 @@ public:
} // namespace arm_gemm
#undef ARGLIST
+
#endif // ARM_COMPUTE_ENABLE_SVE