From our full detailed rules:
5.8. You may purposefully commit suicide, but only if your next flag is at the other base. However, keep in mind that this is rarely your best strategy.
Basically the chances of you spawning ahead are minimal, and you in no way help your team at all (eg. gun a hog) if you are dead with a long respawn time. I would recommend you do not use this tactic at all, but yes it is legal.