• Welcome to TechPowerUp Forums, Guest! Please check out our forum guidelines for info related to our community.

AMD Processors No Longer Crippled with Latest MATLAB MKL Update

btarunr

Editor & Senior Moderator
Staff member
Joined
Oct 9, 2007
Messages
38,852 (8.42/day)
Location
Hyderabad, India
Processor AMD Ryzen 7 2700X
Motherboard ASUS ROG Strix B450-E Gaming
Cooling AMD Wraith Prism
Memory 2x 16GB Corsair Vengeance LPX DDR4-3000
Video Card(s) Palit GeForce RTX 2080 SUPER GameRock
Storage Western Digital Black NVMe 512GB
Display(s) BenQ 1440p 60 Hz 27-inch
Case Corsair Carbide 100R
Audio Device(s) Creative Sound Blaster Recon3D PCIe
Power Supply Cooler Master MWE Gold 650W
Mouse ASUS ROG Strix Impact
Keyboard Microsoft Sidewinder X4
Software Windows 10 Pro
MATLAB received an update that no longer cripples users of AMD processors. Back in November 2019, there was quite some controversy when it emerged that MATLAB, a popular computing platform popular with engineering firms, universities, and research institutes, wasn't working optimally with AMD processors. Specifically, the suite's Intel MKL (math kernel library) component was designed such that if it didn't recognize the "GenuineIntel" CPUID string, it would disable fast AVX2 code-paths and fall back to SSE. This would inflict anywhere between 20-300 percent performance penalties on "AuthenticAMD" processors.

Reddit user Nedflanders1976 developed a tweak back in November, which spoofs MKL into thinking AMD processors are "GenuineIntel," enabling it to leverage modern instruction sets such as SSE4, AVX, and AVX2. AMD processors have been supporting SSE4 and AVX since its 2011 FX-series, and AVX2 since 2017 Ryzen. With the latest R2020a version, MATLAB automatically enables AVX2 execution on AMD processors that support the instruction set. A quick set of tests by ExtremeTech confirms that the update does indeed leverage the faster code-path by default, with Ryzen Threadripper 3960X and 3970X gaining over 200% performance and beating the Core i9-10980XE (something that needed the Nedflanders1976 tweak earlier).



View at TechPowerUp Main Site
 
Joined
May 31, 2016
Messages
1,766 (1.21/day)
System Name Bro2
Processor Ryzen 2700X
Motherboard MSI X470 Gaming Carbon
Cooling Corsair h115i pro rgb
Memory G.Skill Flare X 3200 CL14
Video Card(s) RX Vega 64 Red Devil / Sapphire 5600XT pulse
Storage M.2 Samsung Evo 970 250MB/ Samsung 860 Evo 1TB
Display(s) LG 27UD69 UHD
Case Fractal Design G
Audio Device(s) realtec 5.1
Power Supply Corsair AXi 760W / Seasonic 750W GOLD
Mouse Logitech G402
Keyboard Logitech slim
Software Windows 10 64 bit
I remember there have been discussions about this way back and some not long ago on this forum. So it turns out MATLAB was crippling AMD CPUs. Two bad it is a tweak by a guy not genuine software update by the software developer.
 
Joined
Nov 3, 2013
Messages
1,729 (0.72/day)
Location
Tokyo, Ota
Processor i5 - 7300HQ
Memory 8GB DDR4
Video Card(s) 1060 6GB
Storage 180GB m.2 SATA | 250GB 850Evo SATA
Display(s) FHD 15" Gsync IPS + Acer H243H
Mouse Rival 300 with Omron main switches.
Keyboard Apex m500 (mx red)
Soooo it "only" took them 4 months to implement a fix that a random guy from Reddit managed to make in a day or two.
Not to mention Ryzen is here since 2017... talk about lazy.
 
Joined
Oct 22, 2014
Messages
7,981 (3.90/day)
Location
Sunshine Coast
System Name Black Box
Processor AMD 3200G
Motherboard MSI X470 Gaming Plus
Cooling Stock
Memory Adata 8Gb 2133Mhz DDR4
Storage Kingston A2000 512Gb NVME
Display(s) AOC 22" Freesync 1m.s. 75Hz
Case Corsair 450D High Air Flow.
Audio Device(s) No need.
Power Supply FSP Aurum 650W
Mouse Yes
Keyboard Of course
Software W10 Pro 64 bit
So how much was Intel paying them?
 
Joined
Jan 31, 2011
Messages
98 (0.03/day)
Soooo it "only" took them 4 months to implement a fix that a random guy from Reddit managed to make in a day or two.
Not to mention Ryzen is here since 2017... talk about lazy.
They make two releases a year, March and September. Not every company panic blows a truckload of patches every week.
 
Joined
Oct 2, 2015
Messages
2,563 (1.51/day)
Location
Argentina
System Name Ciel / Yukino
Processor AMD Ryzen R5 3400G / Intel Core i3 5005U
Motherboard Gigabyte B450 Aorus M / HP 240 G5
Cooling AM3 Wraith + Spire fan / Stock
Memory 2x 8GB Corsair Vengeance LPX DDR4 3200MHz / 2x 4GB Hynix + Kingston DDR3L 1600MHz
Video Card(s) AMD Radeon RX Vega 11 + Nvidia Geforce GT 1030 2GB / Intel HD 5500
Storage SSD WD Green 240GB M.2 + HDD Toshiba 2TB / SSD Kingston A400 120GB SATA
Display(s) Samsung S22F350 @ 75Hz/ Integrated 1366x768 @ 94Hz
Case Generic / Stock
Audio Device(s) Realtek ALC892 / Realtek ALC282
Power Supply Sentey XPP 525W / Power Brick
Mouse Logitech G203 / Elan Touchpad
Keyboard Generic / Stock
Software Windows 10 x64
They make two releases a year, March and September. Not every company panic blows a truckload of patches every week.
That's not an excuse for a simple change on so expensive software.
 
Joined
Nov 3, 2013
Messages
1,729 (0.72/day)
Location
Tokyo, Ota
Processor i5 - 7300HQ
Memory 8GB DDR4
Video Card(s) 1060 6GB
Storage 180GB m.2 SATA | 250GB 850Evo SATA
Display(s) FHD 15" Gsync IPS + Acer H243H
Mouse Rival 300 with Omron main switches.
Keyboard Apex m500 (mx red)
They make two releases a year, March and September. Not every company panic blows a truckload of patches every week.
Lol a panic patch... It's a simple bug fix that has less than 10 lines of code.
The issue has been present since the launch of Zen 1. So your "every week" has actually been 3 years.
 
Joined
Sep 6, 2013
Messages
1,558 (0.63/day)
Location
Athens, Greece
System Name 3 systems: Gaming / Internet / HTPC
Processor Intel i5 4460 / Thuban 1455T(Unlocked 645) @ 3.7GHz @ 1.30V / A6 7400K
Motherboard ASRock Z97 Extreme6 / Gigabyte GA-990XA-UD3 / ASUS FM2+
Cooling Modified AM2 Asetek MicroChill / Noctua U12S / CoolerMaster TX2
Memory 16GB Kingston KHX1866C10D3 / 16GB Adata 2133MHz / 8GB Kingston 2400MHz (DDR3)
Video Card(s) XFX RX 580 8GB + GT 620 (PhysX)/ GT 710 / A6 7400K iGPU
Storage Intel NVMe 500GB, Samsung NVMe 250GB + more / Kingston 240GB + more / Samsung SSD 120GB
Display(s) Samsung LE32D550 32'' TV(2 systems connected) / LG 42''
Case Sharkoon Rebel 12 / Sharkoon Rebel 9 / Xigmatek Midguard
Audio Device(s) onboard
Power Supply Chieftec 850W / Sharkoon 650W / Chieftec 560W
Mouse CoolerMaster / Rapoo / Logitech
Keyboard CoolerMaster / Microsoft / Logitech
Software Windows
So, if someone with an AMD processor, who payed for the program, comes out and say
"Because of what they did, I lost X time that translates to Y money that is way much more than what Matlab costs. So from here on I am going to pitrate this software until I cover up my loses".
How much wrong would he be?
 
Joined
Oct 2, 2015
Messages
2,563 (1.51/day)
Location
Argentina
System Name Ciel / Yukino
Processor AMD Ryzen R5 3400G / Intel Core i3 5005U
Motherboard Gigabyte B450 Aorus M / HP 240 G5
Cooling AM3 Wraith + Spire fan / Stock
Memory 2x 8GB Corsair Vengeance LPX DDR4 3200MHz / 2x 4GB Hynix + Kingston DDR3L 1600MHz
Video Card(s) AMD Radeon RX Vega 11 + Nvidia Geforce GT 1030 2GB / Intel HD 5500
Storage SSD WD Green 240GB M.2 + HDD Toshiba 2TB / SSD Kingston A400 120GB SATA
Display(s) Samsung S22F350 @ 75Hz/ Integrated 1366x768 @ 94Hz
Case Generic / Stock
Audio Device(s) Realtek ALC892 / Realtek ALC282
Power Supply Sentey XPP 525W / Power Brick
Mouse Logitech G203 / Elan Touchpad
Keyboard Generic / Stock
Software Windows 10 x64
So, if someone with an AMD processor, who payed for the program, comes out and say
"Because of what they did, I lost X time that translates to Y money that is way much more than what Matlab costs. So from here on I am going to pitrate this software until I cover up my loses".
How much wrong would he be?
Legally? Very.
 
Joined
Sep 6, 2013
Messages
1,558 (0.63/day)
Location
Athens, Greece
System Name 3 systems: Gaming / Internet / HTPC
Processor Intel i5 4460 / Thuban 1455T(Unlocked 645) @ 3.7GHz @ 1.30V / A6 7400K
Motherboard ASRock Z97 Extreme6 / Gigabyte GA-990XA-UD3 / ASUS FM2+
Cooling Modified AM2 Asetek MicroChill / Noctua U12S / CoolerMaster TX2
Memory 16GB Kingston KHX1866C10D3 / 16GB Adata 2133MHz / 8GB Kingston 2400MHz (DDR3)
Video Card(s) XFX RX 580 8GB + GT 620 (PhysX)/ GT 710 / A6 7400K iGPU
Storage Intel NVMe 500GB, Samsung NVMe 250GB + more / Kingston 240GB + more / Samsung SSD 120GB
Display(s) Samsung LE32D550 32'' TV(2 systems connected) / LG 42''
Case Sharkoon Rebel 12 / Sharkoon Rebel 9 / Xigmatek Midguard
Audio Device(s) onboard
Power Supply Chieftec 850W / Sharkoon 650W / Chieftec 560W
Mouse CoolerMaster / Rapoo / Logitech
Keyboard CoolerMaster / Microsoft / Logitech
Software Windows
Legally? Very.
Legally will always be wrong. I was thinking about ethically. A company deliberately(?) chooses(?) to not fix an easy bug that slows performance in very specific hardware. This is probably not legally wrong, but ethically?
 

ARF

Joined
Jan 28, 2020
Messages
865 (7.15/day)
System Name ARF System 1 (retro build) | Portable 1 (energy efficient and portable)
Processor AMD Athlon 64 4400+ X2 | AMD Ryzen 5 2500U
Motherboard ASRock 939A790GMH 790GX SATA2 |
Cooling Arctic Freezer 13 | Dual-fan, dual heat-pipe Acer inbuilt
Memory 4 x 1GB DDR-400 | 2 x 8GB DDR4-2400
Video Card(s) Radeon ASUS EAH4670/DI/512MD3 | Radeon RX 560X 4G & Vega 8
Storage ADATA XPG SX900 128GB SATA3@SATA2 SSD | Western Digital Blue 3D NAND M.2 SSD 500GB
Display(s) | LG 24UD58-B & Panasonic TX-50CX670E
Case Cooler Master HAF 912 Plus | 15-inch notebook chassis
Audio Device(s) Superlux HD681 EVO
Mouse Genius NetScroll 100X | Genius NetScroll 100X
Keyboard | Logitech Wave
Software Windows 7U SP1| Windows 10 Pro 2004
Legally will always be wrong. I was thinking about ethically. A company deliberately(?) chooses(?) to not fix an easy bug that slows performance in very specific hardware. This is probably not legally wrong, but ethically?
Technically, it's like inserting a rod in a rotating wheel, so that it helps to stop the progress.

This is exactly why Intel is a so dislikable corp. Meh!
 
Joined
Sep 17, 2014
Messages
12,123 (5.83/day)
Location
Mars
Processor i7 8700k 4.7Ghz @ 1.26v
Motherboard AsRock Fatal1ty K6 Z370
Cooling beQuiet! Dark Rock Pro 3
Memory 16GB Corsair Vengeance LPX 3200/C16
Video Card(s) MSI GTX 1080 Gaming X @ 2100/5500
Storage Samsung 850 EVO 1TB + Samsung 830 256GB + Crucial BX100 250GB + Toshiba 1TB HDD
Display(s) Eizo Foris FG2421
Case Fractal Design Define C TG
Power Supply EVGA G2 750w
Mouse Logitech G502 Protheus Spectrum
Keyboard Sharkoon MK80 (Brown)
Software W10 x64
Lol a panic patch... It's a simple bug fix that has less than 10 lines of code.
The issue has been present since the launch of Zen 1. So your "every week" has actually been 3 years.
Maybe this is them panicking!

They can't stay behind now that Ryzen is gaining market share. You can bet that is why they just had to release now :) Yesterday we could read about a certain 4900HS CPU.
 

Frick

Fishfaced Nincompoop
Joined
Feb 27, 2006
Messages
16,199 (3.11/day)
Location
Piteå
System Name Black MC in Tokyo
Processor Ryzen 5 2600x
Motherboard Asrock B450M-HDV
Cooling AMD Wraith Spire I think
Memory 2 x 8GB G-skill Aegis 3000 or somesuch
Video Card(s) Asus GTX 760 DCU2OC 2GB
Storage Kingston A400 240GB | WD Blue 1TB x 2
Display(s) BenQ GL2450HT
Case Some old Antec
Audio Device(s) Line6 UX1 + slightly modded Sony DR-ZX302
Power Supply Fractal Design Effekt 400W
Mouse Logitech G602
Keyboard Dell Sk3205
Software Windows 10 Pro
Benchmark Scores I once had +100 dorfs in DF, so yeah pretty great
They make two releases a year, March and September. Not every company panic blows a truckload of patches every week.
Lol a panic patch... It's a simple bug fix that has less than 10 lines of code.
The issue has been present since the launch of Zen 1. So your "every week" has actually been 3 years.
Yeah, hotfixes has been a thing for a really long time.
 

Fourstaff

Moderator
Staff member
Joined
Nov 29, 2009
Messages
9,541 (2.49/day)
Location
Home
System Name Orange!
Processor 3570K
Motherboard ASRock z77 Extreme4
Cooling Stock
Memory 2x4Gb 1600Mhz CL9 Corsair XMS3
Video Card(s) Sapphire Nitro+ RX 570
Storage Samsung 840 250Gb + Toshiba DT01ACA300 3Tb
Display(s) LG 22EA53VQ
Case NZXT Phantom 410 Black/Orange
Power Supply Corsair CXM500w
Yeah, hotfixes has been a thing for a really long time.
Hotfixes for regular software like Chrome? Push one update every day no problem. Hotfixes for Nuclear Reactors? Make sure they check every damn interaction before pushing the updates through. This one lies somewhere in between, I think they are likely to err towards the side of caution. Laziness probably played a big part, along with prioritization.
 
Joined
May 31, 2016
Messages
1,766 (1.21/day)
System Name Bro2
Processor Ryzen 2700X
Motherboard MSI X470 Gaming Carbon
Cooling Corsair h115i pro rgb
Memory G.Skill Flare X 3200 CL14
Video Card(s) RX Vega 64 Red Devil / Sapphire 5600XT pulse
Storage M.2 Samsung Evo 970 250MB/ Samsung 860 Evo 1TB
Display(s) LG 27UD69 UHD
Case Fractal Design G
Audio Device(s) realtec 5.1
Power Supply Corsair AXi 760W / Seasonic 750W GOLD
Mouse Logitech G402
Keyboard Logitech slim
Software Windows 10 64 bit
Hotfixes for regular software like Chrome? Push one update every day no problem. Hotfixes for Nuclear Reactors? Make sure they check every damn interaction before pushing the updates through. This one lies somewhere in between, I think they are likely to err towards the side of caution. Laziness probably played a big part, along with prioritization.
I agree to all of that except one thing. This updates you mentioned are released by the company which made the application. In case of MATLAB a random guy made a tweak to avoid Genuine Intel CPU recognition or simply fools the software engine to recognize AMD CPU as Intel's.
 

Fourstaff

Moderator
Staff member
Joined
Nov 29, 2009
Messages
9,541 (2.49/day)
Location
Home
System Name Orange!
Processor 3570K
Motherboard ASRock z77 Extreme4
Cooling Stock
Memory 2x4Gb 1600Mhz CL9 Corsair XMS3
Video Card(s) Sapphire Nitro+ RX 570
Storage Samsung 840 250Gb + Toshiba DT01ACA300 3Tb
Display(s) LG 22EA53VQ
Case NZXT Phantom 410 Black/Orange
Power Supply Corsair CXM500w
I agree to all of that except one thing. This updates you mentioned are released by the company which made the application. In case of MATLAB a random guy made a tweak to avoid Genuine Intel CPU recognition or simply fools the software engine to recognize AMD CPU as Intel's.
Mr Random guy probably didn't check all interactions before pushing his spoof through.
 
Joined
May 31, 2016
Messages
1,766 (1.21/day)
System Name Bro2
Processor Ryzen 2700X
Motherboard MSI X470 Gaming Carbon
Cooling Corsair h115i pro rgb
Memory G.Skill Flare X 3200 CL14
Video Card(s) RX Vega 64 Red Devil / Sapphire 5600XT pulse
Storage M.2 Samsung Evo 970 250MB/ Samsung 860 Evo 1TB
Display(s) LG 27UD69 UHD
Case Fractal Design G
Audio Device(s) realtec 5.1
Power Supply Corsair AXi 760W / Seasonic 750W GOLD
Mouse Logitech G402
Keyboard Logitech slim
Software Windows 10 64 bit
Mr Random guy probably didn't check all interactions before pushing his spoof through.
If you take it as a spoof fine but it actually works.
 
Joined
Jun 28, 2016
Messages
3,595 (2.51/day)
If you take it as a spoof fine but it actually works.
This is not how enterprise production software is made. Matlab is not a game.
They release twice a year. Testing probably takes a month.
 
Joined
May 31, 2016
Messages
1,766 (1.21/day)
System Name Bro2
Processor Ryzen 2700X
Motherboard MSI X470 Gaming Carbon
Cooling Corsair h115i pro rgb
Memory G.Skill Flare X 3200 CL14
Video Card(s) RX Vega 64 Red Devil / Sapphire 5600XT pulse
Storage M.2 Samsung Evo 970 250MB/ Samsung 860 Evo 1TB
Display(s) LG 27UD69 UHD
Case Fractal Design G
Audio Device(s) realtec 5.1
Power Supply Corsair AXi 760W / Seasonic 750W GOLD
Mouse Logitech G402
Keyboard Logitech slim
Software Windows 10 64 bit
This is not how enterprise production software is made. Matlab is not a game.
They release twice a year. Testing probably takes a month.
Who said it's a game? That's not the issue here. The update wasn't done by the company. There is no update but instead a random guy made a tweak in the software.
Did you even read OP's post?
 
Joined
Jun 28, 2016
Messages
3,595 (2.51/day)
Who said it's a game? That's not the issue here. The update wasn't done by the company. There is no update but instead a random guy made a tweak in the software.
Did you even read OP's post?
I try not to spend much time reading his posts.
Have you checked the ExtremeTech source he linked (thankfully)?

"A random guy" provided a workaround few months ago.

The reason we're discussing this today is that Matlab 2020a now runs AVX2 on AMD CPUs. So yes, it's an update made by MathWorks.
 
Joined
Apr 12, 2013
Messages
3,189 (1.22/day)
An update which could have easily come a year, heck 2 years back but of course for reasons $$$ :rolleyes:
 
Joined
Jan 30, 2018
Messages
154 (0.18/day)
System Name Dreamstation2
Processor Ryzen 7 3700X
Motherboard MSI X470 Gaming Plus
Cooling Hyper 212 Black Edition
Memory 32GB DDR4 3200 CL16
Video Card(s) EVGA GTX1080 Hybrid
Storage 1TB M.2 NVME + 480GB M2 SATA + 1TB 2.5" SSD
Display(s) 24" IPS 2560x1440
Case NZXT H500i
Audio Device(s) Asus Xonar U3
Power Supply Corsair TX650M
Mouse Corsair Scimitar Pro RGB
Keyboard Cooler Master Masterkeys Lite L
So how much was Intel paying them?
As much as I dislike Intel, it's not their fault. Intel developed the MKL, so they made it fallback on non-Intel CPUs. They didn't have to test it on competitor's CPUs and enable the AVX2 mode.
It's entirely the software company that makes Matlab. "Yeah we know our laziness is bad for you, just wait for next release cycle."
 
Joined
May 31, 2016
Messages
1,766 (1.21/day)
System Name Bro2
Processor Ryzen 2700X
Motherboard MSI X470 Gaming Carbon
Cooling Corsair h115i pro rgb
Memory G.Skill Flare X 3200 CL14
Video Card(s) RX Vega 64 Red Devil / Sapphire 5600XT pulse
Storage M.2 Samsung Evo 970 250MB/ Samsung 860 Evo 1TB
Display(s) LG 27UD69 UHD
Case Fractal Design G
Audio Device(s) realtec 5.1
Power Supply Corsair AXi 760W / Seasonic 750W GOLD
Mouse Logitech G402
Keyboard Logitech slim
Software Windows 10 64 bit
I try not to spend much time reading his posts.
Have you checked the ExtremeTech source he linked (thankfully)?

"A random guy" provided a workaround few months ago.

The reason we're discussing this today is that Matlab 2020a now runs AVX2 on AMD CPUs. So yes, it's an update made by MathWorks.
You just joined in the conversation. Now it works and has been proven. I'll focus on that.
You could have shared the source link though.
What extremetech mentions is they have covered the topic that MatLab didn't run the the workloads with fools speed few months ago not that the tweak was found.
Here's the link BTW: https://www.extremetech.com/computing/308501-crippled-no-longer-matlab-2020a-runs-amd-cpus-at-full-speed
The article came out yesterday mentioning "the guy". I didn't find anything that he had done it months ago.
 
Joined
Jun 28, 2016
Messages
3,595 (2.51/day)
An update which could have easily come a year, heck 2 years back but of course for reasons $$$ :rolleyes:
Every fix ever done could have happened earlier. The whole point of fixing issues is that someone has to notice the issue first.
For better part of a decade no one used AMD CPUs for Matlab. Simple as that.

Ad BTW: keep that in mind next time you'll write a post about how great ARM is and how easy it will be to migrate form x86.
 
Joined
Apr 12, 2013
Messages
3,189 (1.22/day)
Weird you're making it sound as if Intel & AMD both don't use the same x86-64 ISA, as for the ARM port you must find where exactly I said it was easy? I simply said for those, like major enterprises or Apple, switching is relatively easy because they mostly have the resources & the knowhow to make it work, not for consumers in the retail space though. So no I've never said porting or switching or migrating is easy, I've always said that ARM (ISA) isn't inherently inferior because forum dwellers say so.
 
Top