-vmargs -Xms40m -Xmx256mThis is ok for most users, but users can tweak these settings by editing eclipse.ini or via the command line, e.g.
eclipse -vmargs -Xms128m -Xmx512m
-vmargs -Xms128m -Xmx512mThe above line is simply ignored (or just not parsed correctly) by eclipse and hence the JVM is just started with the Sun VM default memory settings and the user thinks everything is fine. The *correct* way of using eclipse.ini is to put each command line argument on individual lines:
-vmargs -Xms128m -Xmx512mThe best way to know if your command line arguments actually has been passed in correctly is to go to Help/About [Product Name] and click "Configuration Details" and check that the property "eclipse.vmargs" contain the values you expected.
eclipse.vmargs=-Xms512m -Xmx512m -jar /opt/eclipse32-3.2.2/startup.jar
-XX:MaxPermSize=128mto make sure I don't run out of PermGen space.
eclipse -vmargs -Xms128m -Xmx512m -XX:MaxPermSize=128m
-vmargs -Xms128m -Xmx512m -XX:MaxPermSize=128m