<elemento > gcAllowVeryLargeObjects<gcAllowVeryLargeObjects> Element
En plataformas de 64 bits, habilita matrices con un tamaño total superior a 2 gigabytes (GB).On 64-bit platforms, enables arrays that are greater than 2 gigabytes (GB) in total size.
<configuration> <configuration>
<en tiempo de ejecución > <runtime>
<gcAllowVeryLargeObjects > <gcAllowVeryLargeObjects>
SintaxisSyntax
<gcAllowVeryLargeObjects
enabled="true|false" />
Atributos y elementosAttributes and Elements
En las siguientes secciones se describen los atributos, los elementos secundarios y los elementos primarios.The following sections describe attributes, child elements, and parent elements.
AtributosAttributes
AtributoAttribute | DescripciónDescription |
---|---|
enabled |
Atributo necesario.Required attribute. Especifica si las matrices con un tamaño total superior a 2 GB se habilitan en plataformas de 64 bits.Specifies whether arrays that are greater than 2 GB in total size are enabled on 64-bit platforms. |
Atributo enabledenabled Attribute
ValorValue | DescripciónDescription |
---|---|
false |
Las matrices con un tamaño total superior a 2 GB no están habilitadas.Arrays greater than 2 GB in total size are not enabled. Este es el valor predeterminado.This is the default. |
true |
Las matrices con un tamaño total superior a 2 GB se habilitan en plataformas de 64 bits.Arrays greater than 2 GB in total size are enabled on 64-bit platforms. |
Elementos secundariosChild Elements
Ninguno.None.
Elementos primariosParent Elements
ElementoElement | DescripciónDescription |
---|---|
configuration |
Elemento raíz de cada archivo de configuración usado por las aplicaciones de Common Language Runtime y .NET Framework.The root element in every configuration file used by the common language runtime and .NET Framework applications. |
runtime |
Contiene información sobre las opciones de inicialización del motor en tiempo de ejecución.Contains information about runtime initialization options. |
ComentariosRemarks
El uso de este elemento en el archivo de configuración de la aplicación permite utilizar matrices con un tamaño superior a 2 GB, pero no cambia otros límites de tamaño de objetos o matrices:Using this element in your application configuration file enables arrays that are larger than 2 GB in size, but does not change other limits on object size or array size:
El número máximo de elementos de una matriz es UInt32.MaxValue.The maximum number of elements in an array is UInt32.MaxValue.
El índice máximo de cualquier dimensión única es 2.147.483.591 (0x7FFFFFC7) para matrices de bytes y matrices de estructuras de un solo byte, y 2.146.435.071 (0X7FEFFFFF) para otros tipos.The maximum index in any single dimension is 2,147,483,591 (0x7FFFFFC7) for byte arrays and arrays of single-byte structures, and 2,146,435,071 (0X7FEFFFFF) for other types.
El tamaño máximo de las cadenas y otros objetos que no sean de matriz no varía.The maximum size for strings and other non-array objects is unchanged.
Precaución
Antes de habilitar esta característica, asegúrese de que la aplicación no incluye código no seguro que supone que todas las matrices tienen un tamaño inferior a 2 GB.Before enabling this feature, ensure that your application does not include unsafe code that assumes that all arrays are smaller than 2 GB in size. Por ejemplo, el código no seguro que usa matrices como búferes puede ser susceptible a saturaciones de búfer si se escribe basándose en la suposición de que las matrices no superarán los 2 GB de tamaño.For example, unsafe code that uses arrays as buffers might be susceptible to buffer overruns if it is written on the assumption that arrays will not exceed 2 GB.
EjemploExample
En el ejemplo siguiente se muestra cómo habilitar esta característica para una aplicación.The following example shows how to enable this feature for an application.
<configuration>
<runtime>
<gcAllowVeryLargeObjects enabled="true" />
</runtime>
</configuration>
Compatible conSupported in
.NET Framework 4,5 y versiones posteriores.NET Framework 4.5 and later versions
Vea tambiénSee also
Comentarios
Cargando comentarios...