SGEMMKERNELPOWER10 GemmKernel is not giving proper output #25434
Unanswered
BODAPATIMAHESH
asked this question in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
test code :
_float ptr_C = (float)C;
int update;
float alpha=1;
bool ZeroMode =0;
#if 1
update = MlasSgemmKernelPOWER10 ((const float)A, (const float)BT,(float*) C, K, M, N, K, N, alpha, ZeroMode);_
compiling : g++ sgemm_use_builtin_onnx.c -L build/Linux/RelWithDebInfo -lonnxruntime_mlas
Running:
./a.out M=4 N=4 K=4
**** Matrix A****
| 1.0000 2.0000 3.0000 4.0000 |
| 5.0000 6.0000 7.0000 8.0000 |
| 9.0000 10.0000 11.0000 12.0000 |
| 13.0000 14.0000 15.0000 16.0000 |
**** Matrix B****
| 1.0000 2.0000 3.0000 4.0000 |
| 5.0000 6.0000 7.0000 8.0000 |
| 9.0000 10.0000 11.0000 12.0000 |
| 13.0000 14.0000 15.0000 16.0000 |
**** Matrix BT****
| 1.0000 5.0000 9.0000 13.0000 |
| 2.0000 6.0000 10.0000 14.0000 |
| 3.0000 7.0000 11.0000 15.0000 |
| 4.0000 8.0000 12.0000 16.0000 |
rows handled is 4
**** Matrix C****
| 10.0000 29.0000 48.0000 67.0000 |
| 26.0000 85.0000 144.0000 203.0000 |
| 42.0000 141.0000 240.0000 339.0000 |
| 58.0000 197.0000 336.0000 475.0000 |
B is transposed during prepacking so I have passed BT in the arguments. the output is not matching with the actual mutiplication result.
**** Matrix C****
| 90.0000 100.0000 110.0000 120.0000 |
| 202.0000 228.0000 254.0000 280.0000 |
| 314.0000 356.0000 398.0000 440.0000 |
| 426.0000 484.0000 542.0000 600.0000 |
Beta Was this translation helpful? Give feedback.
All reactions