Merge STEM optimisations into Elysium