Java 1.5 has many performance enhancements compared to previous versions, it's not specifically because Java 1.5 knows how to handle multiple CPUs better.
See this part of the JDK 5.0 release notes:
[url=http://java.sun.com/j2se/1.5.0/docs/guide/performance/speed.html]Improvements to Program Execution Speed - Enhancements in JDK 5.0[/url]