Runs fine under IDE1.8.5 but crashes / resets under IDE1.8.9 ??

Hi all!

I have a sketch running on an arduino Mega along with an ethernet shield (W5200 based) along with SD card, EEPROM and RTC
Its a pretty big project with a compiled code of around 100kb but its been working fine for a couple of years 24/7.

I recently replaced the ethernet shield with a separate w5500 based ethernet module and a separate microSD card module.
After making the necessary changes for pin CS allocation and compiled now under IDE 1.8.9, it turns out that the program now crashes and resets endlessly within the setup() function. After ages of troubleshooting I narrowed this down to the SDcard module.
When the sd is powered off or ejected everything is fine again. No resets!

I couldn't pinpoint the source of the issue any further but I then recompiled the sketch under v1.8.5 (whch was the version that the original sketch was compiled and running ok) and the problem disappeared!

Any ideas why this might be happening?