Enable large arrays: Build octave such that it can use arrays larger than 2Gb.: Difference between revisions
Jump to navigation
Jump to search
(Take example from Manual, previous one actually works. Minor formatting improvements.) |
(Changed defaults for versions 4.4 and newer) |
||
Line 1: | Line 1: | ||
'''Note: the following only applies to systems that have 64-bit pointers (64bit architecture)''' | '''Note: the following only applies to systems that have 64-bit pointers (64bit architecture)''' | ||
Starting with Octave 4.4.0, 64-bit indexing is the default for targets with 64-bit pointers. You can override that default by specifying <code>--disable-64</code> when configuring Octave. | |||
However, if the configure script determines that the BLAS library uses 32-bit integers, then operations using the following libraries are limited to arrays with dimensions that are smaller than 2^31 elements: | |||
* BLAS | |||
* LAPACK | |||
* QRUPDATE | |||
* SuiteSparse | |||
* ARPACK | |||
Additionally, the following libraries use "int" internally, so maximum problem sizes are always limited: | |||
* glpk | |||
* Qhull | |||
===Versions prior to Octave 4.4=== | |||
On previous versions of Octave, the default is that the size of a single Octave array cannot exceed 2 GB of memory. Trying to create one will produce the following error: | |||
<pre> | <pre> | ||
Line 13: | Line 27: | ||
With this option, Octave will use internally 64-bit integers for array dimensions and indexing. However, '''all numerical libraries''' used by Octave will need to use also 64-bit integers for array dimensions and indexing, and in most cases they need to be compiled from source. | With this option, Octave will use internally 64-bit integers for array dimensions and indexing. However, '''all numerical libraries''' used by Octave will need to use also 64-bit integers for array dimensions and indexing, and in most cases they need to be compiled from source. | ||
For details about how to compile these libraries please read the [http://www.gnu.org/software/octave/doc/interpreter/Compiling-Octave-with-64_002dbit-Indexing.html#Compiling-Octave-with-64_002dbit-Indexing GNU Octave manual], or alternatively you can use [http://wiki.octave.org/MXE MXE] (M Cross Environment) which takes care of the different packages automatically. | For details about how to compile these libraries please read the [http://www.gnu.org/software/octave/doc/interpreter/Compiling-Octave-with-64_002dbit-Indexing.html#Compiling-Octave-with-64_002dbit-Indexing GNU Octave manual], or alternatively you can use [http://wiki.octave.org/MXE MXE] (M Cross Environment) which takes care of the different packages automatically (especially the configure flags <code>--enable-64</code> and <code>--enable-fortran-int64</code>). | ||
[[Category:Building]] | [[Category:Building]] |