[ad_1]
hello, I’ve efficiently put in MKL2024 and VS2022, however when working the next code, an error is reported:
#embrace <iostream>
#embrace <mkl.h>
int predominant() {
const int n = 100;
float* x, * y;
float consequence;
x = (float*)mkl_malloc(n * sizeof(float), 64);
y = (float*)mkl_malloc(n * sizeof(float), 64);
for (int i = 0; i < n; i++) {
x[i] = i + 1;
y[i] = 2 * (i + 1);
}
consequence = cblas_sdot(n, x, 1, y, 1);
std::cout << "consequence: " << consequence << std::endl;
mkl_free(x);
mkl_free(y);
return 0;
}
then i acquired this:
( There may be an unhandled exception at: 0x00007FF60ED22453 (in take a look at.exe): 0xC0000005: An entry battle occurred whereas studying location 0x000009567EFEE7C4. )
stack:
The above is simply an instance, in truth, I get this error with any calculation operate(reminiscent of cblas_saxpy cblas_saxpby and extra…) I enable and do not get a lot detailed hints from the compiler.
thanks.
[ad_2]