Skip to content

Commit

Permalink
Set MaxRAM and MaxRAMPercentage in launcher for native-image driver
Browse files Browse the repository at this point in the history
Closes graalvm/mandrel#557

(cherry picked from commit 6c406e3)
  • Loading branch information
zakkak committed Sep 15, 2023
1 parent b2e26df commit ef934b9
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions build.java
Original file line number Diff line number Diff line change
Expand Up @@ -390,6 +390,8 @@ private static void patchNativeImageLauncher(Path nativeImage, String mandrelVer
logger.debugf("launcherMatcher.group(1): %s", launcherMatcher.group(1));
logger.debugf("launcherMatcher.group(2): %s", launcherMatcher.group(2));
final String launcherLine = launcherMatcher.group(1) +
" -XX:MaxRAM=256m" +
" -XX:MaxRAMPercentage=80" +
" -Dorg.graalvm.version=\"" + mandrelVersion + "\"" +
" -Dorg.graalvm.vendorversion=\"Mandrel-" + mandrelVersion + "\"" +
" -Dorg.graalvm.vendor=\"" + (vendor != null ? vendor : defaultVendor) + "\"" +
Expand Down

0 comments on commit ef934b9

Please sign in to comment.