# Can we use Intel MKL libraries on systems with new AMD processors ?

+1 vote
asked

Will Intel MKL libraries, work in non-intel hardwares?

I am about to buy a new system/laptop. I currently have intel processor on my system but just wished to ask about new AMDs so, that I don't face any issue when using and compiling tensor networks codes on those systems. Needed some help/suggestion, etc.

## 1 Answer

+1 vote
answered by (9.7k points)

Yes, I believe that MKL does work on AMD processors. However, by default it may not be as fast on AMD processors. My understanding is that you can set the following environment variable (in Linux):

export MKL_DEBUG_CPU_TYPE=5


and then MKL should run as fast on AMD as it does on Intel processors, but this is an undocumented option in MKL and may not be guaranteed to work for different versions of MKL (and I have not personally tried it). Here are some more discussions about it:

https://sites.google.com/a/uci.edu/mingru-yang/programming/mkl-has-bad-performance-on-an-amd-cpu

https://www.reddit.com/r/matlab/comments/dxn38s/howto_force_matlab_to_use_a_fast_codepath_on_amd

https://github.com/flame/blis/issues/312

commented by (180 points)
Thank you Matt for your response.