That depends on how you define "safe".
Rooting, whether it is before or after upgrading to 2.3 voids guaranty. But nothing bad will happen will happen to your phone just because it is rooted. Rooting gives you access to the otherwise restricted root folder. So before you root your phone, since you cannot access this folder, you cannot actually damage the phone software. But after rooting, you can (for example) uninstall system apps and while most of them are just trash, some are actually needed for the phone to work.
As long as you know what you are doing, rooting is safe. Even after you root, you can always undo the root in case there is a problem with the phone and you need to take it to the service center. Just make sure you dont leave any evidence of rooting behind.