Minecraft Settings update - Arguments, Allocation Minimum RAM. Metaspace, etc.
Both Minecraft and Java have changed a lot over the years and things have changed.
When you launch a minecraft modpack through the Twitch Client, it will automatically assign a couple of flags a user has no control over. One of them being the -xms flag which is always set to 256m and the -XX:PermSize flag which is also set to 256m.
First of all, PermSize has been deprecated with the release of Java 8, meaning it has been ignored since even before Amazon acquired Curse and fused it with Twitch.
PermSize has been replaced with the new Metaspace. I highly recommend setting the flag -XX:MetaspaceSize and tuning it to 256m instead.
I also recommend allowing a user to choose to set the -xms flag.
There are a couple of reasons for this:
When Java Virtual Machines periodically garbage clean, they attempt to scan and reduce anything towards the set xms value. This can cause seconds long freezes if it involves a modpack.
Modern minecraft requires 2G RAM to play, so it will even affect vanilla. Even if you don't want users to set the flag exactly, I highly recommend raising it to 1 or 2G since this will reduce lag experienced during these global gc scans. (though some users may want to raise it to 4G if the pack is very large and thus requires a lot of stuff to remain loaded in memory)
You can, like you did with the xmx value, limit the amount a user can set it to, if programmed properly. Your client is capable of detecting how much RAM is installed, you can use this to for example define what the limit of the slider will be on the xms as well.
I also need to inform you that minecraft vanilla itself has jvm arguments set by mojang. These arguments are: -XX:+UnlockExperimentalVMOptions -XX:+UseG1GC -XX:G1NewSizePercent=20 -XX:G1ReservePercent=20 -XX:MaxGCPauseMillis=50 -XX:G1HeapRegionSize=32M
None of them appear (by default) in the 'additional arguments' tab and in fact if you don't fill any in, these will be removed completely when the game is launched. This can cause a lot of issues. I recommend adding these (and allowing users to change them if nessecary) in the additional arguments tab if the additional arguments option is empty.
I also recommend adding the -version:1.8+ flag to additional arguments by default. This way, if the client has a java 8 version installed that is in version higher than the included one, JVM will prefer to use that one instead.
If you have questions about the arguments, please have a look here:
Thank you for your time, reading and understanding.