Hi,
Sorry, this question has probably been asked before, but I've run some tests (on small matrices) and i'm confused regarding the matrix dimension constraints, when performing matrix multiply using LEA (dsplib - msp_matrix_mpy_q15). There appears to be some discrepancies with the API documentation.
1) What are the matrix dimension constraints ?
E.g.
When HxW of A and B are : (1x4) * (4x2) and using the following values :
_q15 matA[1][4] = { {_Q15(+0.01), _Q15(+0.02), _Q15(+0.03), _Q15(+0.04)} }; _q15 matB[4][2] = { {_Q15(+0.005), _Q15(+0.01)}, {_Q15(+0.01), _Q15(+0.005)}, {_Q15(+0.005), _Q15(+0.01)}, {_Q15(+0.01), _Q15(+0.005)} };
I get the correct results : 26, 22
But in the dsplib API , the matrix dimensions are supposed to be multiples of 2. If so, how come the above 2 input matrices result is correct ?
Is this an edge case where a 1xW matrix A works fine ? I have tested A(5x4) x B(4x2), this also works fine.
2) Can you confirm if the API documentation is accurate regarding the matrix dimensions needing to be multiples of 2 ?
http://software-dl.ti.com/msp430/msp430_public_sw/mcu/msp430/DSPLib/latest/exports/html/structmsp__matrix__mpy__q15__params.html
3) Does ONLY the ColA = RowB = must be multiple of 2 ? Does ColB also need to be multiple of 2 ?
As msp_matrix_mpy_q15 works like a vector-matrix multiplication (iteratively A_row x MatB), then does the rows of matrix A also need to be a multiple of 2 ?
thanks