Backup and restore registers when calling out to user funcs.