java memory主要分heap memory 和 non-heap memory,其计算公式如下: Max memory = [-Xmx] + [-XX:MaxPermSize] + number_of_threads * [-Xss] heap结构 按分代,分young-eden,young-survivor,old 用-Xmn,-Xms,-Xmx来指定. non-heap结构 包括metaspace,thread stacks,compiled native code,memory a…