15% performance-boost and 40% less memory-usage using GraalVM
82 replies
geektrader
4 years ago #257329
Hi đ
I just wanted to share my “new” find. As always, I am exploring options about how to increase the speed of SQX for my daily workflow by tuning parameters, garbage collectors, etc. Lately, I´ve learned about GraalVM, which is a relatively new JIT-compiler that has maximum performance as its goal and has been shown sometimes to be up to 30x faster than if executing code in the standard JRE / OpenJDK runtimes that SQX is using right now. Over here is an excellent video about how it works, why it has been made and with some performance tests: https://www.youtube.com/watch?v=GinNxS3OSi0 For example: Twitter is running all their Java stuff on GraalVM instead of JRE / OpenJDK for a while now and have noticed a considerable drop in CPU and RAM usage.
And now the great part: using it with SQX is as easy as downloading the latest Windows binary from here https://github.com/graalvm/graalvm-ce-builds/releases
Simply unpack the ZIP file into the J64 of SQX (previously delete or rename the folder) and just continue working with SQX as you always did. Personally here is what I have experienced since replacing it and of course, using the same settings in SQX as before:
– about a 15% performance increase in strategy generation speed
– approximately a 40% drop in memory consumption (which is AMAZING given that I can now work with less RAM)
– no errors or crashes of SQX just works the same as with JRE / OpenJDK
As this is open-source, I would highly recommend that SQX is being shipped with GraalVM in its default configuration, as this seems to be amazing! There also is an Enterprise Edition available that seems to be even faster, but it´s 193 Euro/year and I haven´t tested it yet.
Have fun crunching strategies đ
tarrioin
2 years ago #271212
Hi the discord link is not working. You can put another thank you. Regarding the tests. With the enterprise edition there is a performance improvement. With the change of RAM memory for one with lower latency there is an improvement in performance and with the change of a better CPU fan by overclocking there is an improvement in performance. It remains for me to see if in an installation of linux ubuntu there is an improvement compared to the installation in windows.
Karish
2 years ago #271505
Hi the discord link is not working. You can put another thank you. Regarding the tests. With the enterprise edition there is a performance improvement. With the change of RAM memory for one with lower latency there is an improvement in performance and with the change of a better CPU fan by overclocking there is an improvement in performance. It remains for me to see if in an installation of linux ubuntu there is an improvement compared to the installation in windows.
C C
2 years ago #274359
with the new version 135 there are no improvements. Has anyone tested this version? Thanks
FirestarZA
2 years ago #274851
I just tested this on build 135.
I’m getting a nearly 25% improvement in strat gen speed (31 seconds per accepted strat, down from 40s), with nearly half ram usage (4.5gb down to 2.7).
Just the normal open source version downloaded from github. I didn’t yet test the enterprise version (though I downloaded it).
I’ve got an amd ryzen cpu (8 cores) and 16 GB ram.
Alejandro
2 years ago #275292
Has anyone got GraalVM to work with QA4? I have tried multiple and either QA4 closes quickly, or it hangs on Loading Range Axis.
mkjones320
2 years ago #275527
Hi,
I tried it on version 135. Get an error. Different version of Java detected. Program will need to be restarted to recompile snippets. Restart and get the same thing. Any thoughts?
mkjones320
Paul Rogers
2 years ago #275572
Java-17 version works with Build 135.868 – Improvement from 520,000 strat per hour to 595,000 per hr. Ryzen 9 3900x 64Gb RAM
cipher
2 years ago #276081
im also getting java 17 to work on build 135.868, seeing around 20% boost.
one issue i noticed while running it was anytime i need to bring up a file dialog (importing file into symbol, adding existing project, etc), it fails and a java Invocation Exception occurs
currently staying on original until this can be resolved
Marcus Smith
2 years ago #276153
Today I installed a new processor and Intel graphics card. I noticed that the program started working much faster. It has become even more pleasant to use the program.
geektrader
2 years ago #276290
Hi Guys, GraalVM 22.0 is out and I´ve got another 5% boost through their new compiler optimizations for non-counted loops (compared to 21.3). I am referring to the 22.0 Java 11 based Enterprise Version over at: https://www.graalvm.org/downloads/ Once downloaded, you´ll have to delete these files for it to work correctly:
\j64\languages\nfi\builder\svm-none.jar;
\j64\languages\nfi\truffle-nfi-none.jar;
For best performance I´d recommend to launch SQX via the âStrategyQuantX_nocheck.exeâ and previously replace the âStrategyQuantX_nocheck.configâ file with the following content:
option -XX:-ShrinkHeapInSteps
option -XX:+UnlockExperimentalVMOptions
option -XX:+EnableJVMCI
option -XX:+EagerJVMCI
option -XX:-UseJVMCINativeLibrary
option -XX:MaxNodeLimit=100000
option -Dgraal.CompilerConfiguration=enterprise
option -Dgraal.UsePriorityInlining=true
option -Dgraal.Vectorization=true
option -Dgraal.OptDuplication=true
option -Dgraal.TuneInlinerExploration=1
option -Dgraal.LoopRotation=true
Arvid Mock
2 years ago #276694
Hello Geektrader,
can you please write a little handout, how you set graalvm with strategyquant point for point up?
I installed graalvm local on my PC and so far it is running, but what is to do in the directory of strategyquant?
The change of the strategyquant config file and the replace of the directory J64 with the graalvm files is not working by me.
Stragtegyquant will not open.
Thank you.
Greetings.
Enrique
2 years ago #277145
Hello, I am writing to communicate the good performance of GraalVM, my first experiences were exasperating with the issue of RAM memory, with 16GB ddr4 at 3200Ghz (soon I will double to 32GB) with the program at a minimum of configurations, without genetic evolution, without cross-checks, simple strategy, the program gives an error with 60% of RAM memory used, this is not possible!
After installing GraalVM to its latest current version as of this post, there is no memory error even at 98% RAM and browser open right now.
Thanks for the info
OrangeCrush
2 years ago #277226
Tornado VM & Graal VM
Hi to the Geeks out there,
Has anybody tried to combine Tornado VM (https://www.tornadovm.org/technology) with Graal VM?
The advantage would be that Strategy Quant would be running on your GPU and could result in better performance?
I can’t get Graal VM running on Windows so this is clearly above my competency level.
Would be interesting to benchmark the difference between running Strategy Quant on Windows, within Graal VM and Tornado and Graal VM.
Cheers,
Jan Bolek
1 year ago #279489
Last java 19
Boost for me over 30%Â generated strategies 400 -> 460 000
Last graalvn – 360Â -> 390 000
Java 19 and set Java home and path
Henrique Dias
1 year ago #279806