参数比较多的时候,多线程回测到一半总是 崩溃,pycharm的错误日志如下。
用的 是12核 16G内存的,虚拟内存也改到很大了。 这可怎么破?
There is insufficient memory for the Java Runtime Environment to continue.
Native memory allocation (malloc) failed to allocate 1089456 bytes for Chunk::new
Possible reasons:
The system is out of physical RAM or swap space
The process is running with CompressedOops enabled, and the Java Heap may be blocking the growth of the native heap
Possible solutions:
Reduce memory load on the system
Increase physical memory or swap space
Check if swap backing store is full
Decrease Java heap size (-Xmx/-Xms)
Decrease number of Java threads
Decrease Java thread stack sizes (-Xss)
Set larger code cache with -XX:ReservedCodeCacheSize=
JVM is running with Zero Based Compressed Oops mode in which the Java heap is
placed in the first 32GB address space. The Java Heap base address is the
maximum limit for the native heap growth. Please use -XX:HeapBaseMinAddress
to set the Java Heap base and to place the Java Heap above 32GB virtual address.
This output file may be truncated or incomplete.
#
Out of Memory Error (./src/hotspot/share/memory/arena.cpp:197), pid=3112, tid=4952
#
JRE version: OpenJDK Runtime Environment JBR-11.0.11.9-1504.13-jcef (11.0.11+9) (build 11.0.11+9-b1504.13)
Java VM: OpenJDK 64-Bit Server VM JBR-11.0.11.9-1504.13-jcef (11.0.11+9-b1504.13, mixed mode, tiered, compressed oops, g1 gc, windows-amd64)
No core dump will be written. Minidumps are not enabled by default on client versions of Windows
#