The G5 still uses Altivec, only supercharged - I think code that was already optimized for Altivec (G4) will still retain that advantage. The effectiveness of "just a recompile" is very dependent on the type of application.
Now, things that were hand-optimized in assembly for G4 may need some work I'm guessing after a quick look at some of Apple's knowledge base docs. A small number of the rules for assembly programming are different, eg. one or two instructions mean different things or are no longer available. But anything that was totally C or Java will be almost instantly ported to G5.
As far as taking advantage of 64-bit, some people are going to be doing lots of work on that I bet (Adobe, Steinberg, eLogic, etc). Even with the compiler's smarts at optimizing, 64-bit might only speed up code that is written in a certain way. Never fear, even if your app doesn't take advantage of 64-bit, there are lots of things about the G5 that give it more bang for the GHz than the G4, for example the number of in-flight instructions and the larger L2 cache. And that's just the processor ... :drool: