Problem Statement
Sometimes with 64-bit support on the .NET Framework is the limitation on arrays, which cannot exceed 2 GB. One of the main reasons you move to 64-bit platforms is to access more than 2 GB, and this limitation was a big problem for those of us trying to work with large matrices and vectors. No matter the amount of available RAM available, it was very common to have a System.OutOfMemoryException
Solution
.NET Framework 4.5 introduces a configuration attribute in the run-time schema that enables arrays larger than 2 GB in total size on 64-bit applications. You need only enable the gcAllowVeryLargeObjects element that controls the behavior of the .NET garbage-collection system.
<configuration>
< startup>
< supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" />
< /startup>
< runtime>
< gcAllowVeryLargeObjects enabled="true" />
< /runtime>
< /configuration>
http://bytes.com/topic/net/insights/952845-array-support-more-than-two-gigabyte-size-net-4-5-a#post3760563
Sometimes with 64-bit support on the .NET Framework is the limitation on arrays, which cannot exceed 2 GB. One of the main reasons you move to 64-bit platforms is to access more than 2 GB, and this limitation was a big problem for those of us trying to work with large matrices and vectors. No matter the amount of available RAM available, it was very common to have a System.OutOfMemoryException
Solution
.NET Framework 4.5 introduces a configuration attribute in the run-time schema that enables arrays larger than 2 GB in total size on 64-bit applications. You need only enable the gcAllowVeryLargeObjects element that controls the behavior of the .NET garbage-collection system.
<configuration>
< startup>
< supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" />
< /startup>
< runtime>
< gcAllowVeryLargeObjects enabled="true" />
< /runtime>
< /configuration>
http://bytes.com/topic/net/insights/952845-array-support-more-than-two-gigabyte-size-net-4-5-a#post3760563
No comments:
Post a Comment