本文介绍了是否有任何集合类或支持超过2 ^ 31项.NET 3.5特殊的数据类型?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我目前使用VS 2008 64位版本,3.5框架SP1的我。然而,似乎像列表中的集合类有2 ^ 31(或int的最大值)的限制因素,它可以包含。

I am currently using VS 2008 64 bit edition, 3.5 framework with SP1. However, it appears that the collection classes like List have a limit of 2^31 (or max value of an int) elements that it can contain.

有谁知道,如果有任何真正的64位的集合,可以处理容器内超过2 ^ 31元?如果不是因为VS 2008,那么怎么样VS 2010?任何第三方集合在那里,做到这一点?

Does anyone know if there are any true 64 bit collections that can handle more than 2^31 elements within a container? If not for VS 2008, then what about VS 2010? Any 3rd party collections out there that do this?

推荐答案

我是pretty的确定有没有内置的集合,可以处理超过 Int32.MaxValue 条目。究其原因是因为.NET Framework仍然有〜2GB的限制,即使是64位版本的对象。 一个字节的Int32.MaxValue 项颠簸起来反对这个限制。我相信Mono的内存限制较大,但我不能肯定确认。

I am pretty sure there are no builtin collections that can handle more than Int32.MaxValue entries. The reason is because the .NET Framework still has ~2GB limit for objects even for the 64-bit version. Int32.MaxValue entries of one byte bumps up against this limit. I believe Mono's memory limit is larger, but I cannot definitely confirm that.

您可以解决此限制使用 BigArray 从实行的。

You can work around this limitation using the BigArray implemenation from here.

这篇关于是否有任何集合类或支持超过2 ^ 31项.NET 3.5特殊的数据类型?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-29 04:35