在哪里设置<gcAllowVeryLargeObjects>?

Dom*_*omi 8 c# arrays mono

我正在研究一个关于排序列表的小程序.现在,我需要一个需要超过2GB RAM的阵列.在我的研究期间,我找到了这个属性,但我不知道在哪里设置它.我正在使用Mono.

Sus*_*ver 8

对于非常大的ArrayList对象,通过在运行时环境中将gcAllowVeryLargeObjects配置元素的enabled属性设置为true,可以将64位系统上的最大容量增加到20亿个元素.

MyCustomApp.config

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <runtime>
    <gcAllowVeryLargeObjects enabled="true" />
  </runtime>
</configuration>
Run Code Online (Sandbox Code Playgroud)

用法:

mono64 --config MyCustomApp.config Foobar.exe
Run Code Online (Sandbox Code Playgroud)