I've been trying to solve a bug in my C code for some time and I ended up discovering that dgemm_() doesn't seem to use the beta value :S. According to Intel's MKL Documentation and BLAS reference documentation, the expected behaviour for this function is:
C = alpha*A*B + beta*C
If beta is set to 0, then it's not expected to give C as input of the operation and will only work as output. But if beta is set to another value (e.g., -1.0), the product will take place and the result will be added to alpha*A*B.
For some reason, I can set beta to any value and it's like dgemm_() never uses it. Have you tested this function using the latest version of the MKL?
To check if it was me calling this function in a wrong way, I manually did alpha*A*B product and the result was equivalent to the one given by dgemm_() with a random beta value.
Thank you in advance.