Quantcast
Channel: Intel® Software - Intel® Visual Fortran Compiler for Windows*
Viewing all articles
Browse latest Browse all 5691

Static array more then 2Gb

$
0
0

I have a small code for initializing the static array and writing it to file. The size of array is 5000000 of reals. I have the  Visual Fortran Compiler XE 13.1.0 and my Win 10 x64 show “This app can’t run on this PC”. If I made the size array of 490000000 the program runs fine and file for001 have a 1861 Mb size on HDD. If I make the static array allocatable the size my be more large then 490000000. Unfortunately I can make array only static.

   program MemoryTest
!    allocatable f(:)
    dimension f(490000000) 
    real f
    ! Body of MemoryTest
    i=490000000
!    allocate (f(i))
    open (1,file='for001',status='unknown',form='unformatted')
    do j = 1, i
     f(j)=j*1.0d0
    end do 
    write (1) f
    end program MemoryTest

 


Viewing all articles
Browse latest Browse all 5691

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>