Garbage collection change from Java 1.4 to Java 6?
did the way garbage collection behaves changed from Java 1.4 to Java 6?
Definitely!
Java 1.4 to Java 6 is a pretty long timespan (almost 5 years between the initial releases and more than 8 years between the initial 1.4 release and the current Java 6 release, according to this wiki article).
Many changes and optimizations are applied in that time and you should not really care as long as your program still works.
Having more used memory only means that the JVM doesn't waste time with garbage collection when it doesn't need to. If you want it to use less memory, then you should reduce the maximum heap (or otherwise tweak the JVM parameters; this article explains how to do that in Java 5, much of the advice is still applicable).
It's somewhat different if you actually get OutOfMemoryError
that you didn't get previously. Then you should check how you use weak and soft references or as a last resort try to find out if you hit a JVM bug.
There have been several optimizations on garbage collecting between 1.4 and 5 and between 5 and 6.
Oracle/Sun have some whitepapers on the performance differences online:
Java 5 Performance White Paper
Java 6 Performance White Paper
Java SE changed a lot in 8 years.
Concerning the garbage collector, it has been improved a lot with Java SE 6. In Java SE 6 Update 14 the new Garbage First GC was introduced.