Use profiles and trampoline to save memory