more stuff moved to before-init