Add options to use JFR

This commit is contained in:
Simon Ogorodnik
2018-06-18 16:25:38 +03:00
parent b97e82f604
commit 7531a103a3
+8
View File
@@ -155,6 +155,14 @@ projectTest(taskName = "performanceTest") {
maxHeapSize = "3g"
jvmArgs("-XX:SoftRefLRUPolicyMSPerMB=50")
jvmArgs("-XX:+UnlockCommercialFeatures", "-XX:+FlightRecorder")
if (hasProperty("perf.flight.recorder.override")) {
jvmArgs(property("perf.flight.recorder.override"))
} else {
val settings = if (hasProperty("perf.flight.recorder.settings")) ",settings=${property("perf.flight.recorder.settings")}" else ""
jvmArgs("-XX:StartFlightRecording=delay=15m,duration=5h,filename=perf.jfr$settings")
}
doFirst {
systemProperty("idea.home.path", intellijRootDir().canonicalPath)