Skip to content

Commit

Permalink
Set initial heap size and reduce stack size
Browse files Browse the repository at this point in the history
  • Loading branch information
fniephaus committed Feb 6, 2023
1 parent 262f7b0 commit 099c1fc
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 5 deletions.
6 changes: 4 additions & 2 deletions mx.trufflesqueak/launchers/trufflesqueak
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,10 @@ while [ -h "$source" ] ; do
done
bin_dir="$( cd -P "$( dirname "$source" )" && pwd )"

# Increase stack size (`-XX:ThreadStackSize=64M` not working)
extra_args=("--vm.Xss64M")
# Set inital heap size
extra_args=("--vm.Xms512M")
# Increase stack size
extra_args+=("--vm.Xss16M")

# Default to polyglot launcher in JVM mode
extra_args+=("--jvm" "--polyglot")
Expand Down
6 changes: 4 additions & 2 deletions mx.trufflesqueak/launchers/trufflesqueak.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,10 @@ if not exist "%tsl_exe%" (
exit /b 1
)

@REM Increase stack size (`-XX:ThreadStackSize=64M` not working)
set extra_args=--vm.Xss64M
@REM Set inital heap size
set extra_args=--vm.Xms512M
@REM Increase stack size
set extra_args=%extra_args% --vm.Xss16M

@REM Default to polyglot launcher in JVM mode
set extra_args=%extra_args% --jvm --polyglot
Expand Down
2 changes: 1 addition & 1 deletion mx.trufflesqueak/mx_trufflesqueak.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
BASE_DIR = os.path.dirname(os.path.dirname(os.path.realpath(__file__)))
VM_ARGS_TESTING = [
# Tweak Runtime
'-Xss64M', # Increase stack size (`-XX:ThreadStackSize=64M` not working)
'-Xss16M', # Increase stack size

# Make ReflectionUtils work
'--add-exports=java.base/jdk.internal.module=ALL-UNNAMED',
Expand Down

0 comments on commit 099c1fc

Please sign in to comment.