Skip to content

Instantly share code, notes, and snippets.

@HELWATANY
Last active October 25, 2024 04:28
Show Gist options
  • Save HELWATANY/c86ac31128468267c16ff0ef9f740637 to your computer and use it in GitHub Desktop.
Save HELWATANY/c86ac31128468267c16ff0ef9f740637 to your computer and use it in GitHub Desktop.
JetBrains Custom VM Options Configuration Optimized For High Performance... Works with all JetBrains IDEs... JDK 8.x+ Recommended....
# Make sure to modify "-Xms", "Xmx", "CICompilerCount", and "ParallelGCThreads" according to your PC hardware configuration...
#####################
# Default VM Options
#####################
# default value is 128m
-Xms1024m
# default value is 750m
-Xmx4096m
# default value is 512m
-XX:ReservedCodeCacheSize=1024M
-XX:+UseG1GC
# default value is 50
-XX:SoftRefLRUPolicyMSPerMB=250
# default value is 2
-XX:CICompilerCount=4
-XX:+HeapDumpOnOutOfMemoryError
-XX:-OmitStackTraceInFastThrow
-XX:+IgnoreUnrecognizedVMOptions
-XX:CompileCommand=exclude,com/intellij/openapi/vfs/impl/FilePartNodeRoot,trieDescend
-ea
-Dsun.io.useCanonCaches=false
-Dsun.java2d.metal=true
-Djbr.catch.SIGABRT=true
-Djdk.http.auth.tunneling.disabledSchemes=""
-Djdk.attach.allowAttachSelf=true
-Djdk.module.illegalAccess.silent=true
-Dkotlinx.coroutines.debug=off
##################################
# Improved Performance VM OPTIONS
##################################
-server
-Xss64m
-XX:+UseCompressedOops
-XX:NewRatio=2
-Dfile.encoding=UTF-8
-XX:+UseConcMarkSweepGC
-XX:NewSize=512m
-XX:MaxNewSize=512m
-XX:PermSize=512m
-XX:MaxPermSize=1024m
-XX:+UseParNewGC
-XX:ParallelGCThreads=4
-XX:MaxTenuringThreshold=1
-XX:SurvivorRatio=8
-XX:+UseCodeCacheFlushing
-XX:+AggressiveOpts
-XX:+CMSClassUnloadingEnabled
-XX:+CMSIncrementalMode
-XX:+CMSIncrementalPacing
-XX:+CMSParallelRemarkEnabled
-XX:CMSInitiatingOccupancyFraction=65
-XX:+CMSScavengeBeforeRemark
-XX:+UseCMSInitiatingOccupancyOnly
-XX:-TraceClassUnloading
-XX:+AlwaysPreTouch
-XX:+TieredCompilation
-XX:+DoEscapeAnalysis
-XX:+UnlockExperimentalVMOptions
-XX:LargePageSizeInBytes=256m
-XX:+DisableExplicitGC
-XX:+ExplicitGCInvokesConcurrent
-XX:+PrintGCDetails
-XX:+PrintFlagsFinal
-XX:+CMSPermGenSweepingEnabled
-XX:+UseAdaptiveGCBoundary
-XX:+UseSplitVerifier
-XX:CompileThreshold=10000
-XX:+UseCompressedStrings
-XX:+OptimizeStringConcat
-XX:+UseStringCache
-XX:+UseFastAccessorMethods
-XX:+UnlockDiagnosticVMOptions
-Xverify:none
-Djava.net.preferIPv4Stack=true
-XX:ErrorFile=$USER_HOME/java_error_in_idea_%p.log
-XX:HeapDumpPath=$USER_HOME/java_error_in_idea.hprof
##################################
# Enable The Following Option If
# You Want To Disable Updates OR
# Updates Are Managed By ToolBox
##################################
#-Dide.no.platform.update=true
@HELWATANY
Copy link
Author

Updated based on the awesome article by @ScriptedAlchemy

@ScriptedAlchemy
Copy link

I’ll update my JetBrains repo or feel free to send pr if you see any adjustments needed

@HELWATANY
Copy link
Author

Sure, I'm just experimenting the settings performance impact

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment