forked from Archive/PX4-Autopilot
jmavsim_run.sh: add more aggressive GC option
This reduces memory usage by roughly 100MB on my laptop
This commit is contained in:
parent
083a59ebc0
commit
44839208f7
|
@ -43,4 +43,12 @@ fi
|
|||
|
||||
ant create_run_jar copy_res
|
||||
cd out/production
|
||||
java -Djava.ext.dirs= -jar jmavsim_run.jar $device $extra_args
|
||||
|
||||
java -XX:GCTimeRatio=20 -Djava.ext.dirs= -jar jmavsim_run.jar $device $extra_args
|
||||
ret=$?
|
||||
if [ $ret -ne 0 -a $ret -ne 130 ]; then # 130 is Ctrl-C
|
||||
# if the start of java fails, it's probably because the GC option is not
|
||||
# understood. Try starting without it
|
||||
java -Djava.ext.dirs= -jar jmavsim_run.jar $device $extra_args
|
||||
fi
|
||||
|
||||
|
|
Loading…
Reference in New Issue