Intel® C++ Compiler
Community support and assistance for creating C++ code that runs on platforms based on Intel® processors.

Reading files >4GB.

erling-andersen
Beginner
389 Views
Hi,
On a Windows/Itanium server I am tring to read file of size>4GB.
using
fopen
fgetc
fgets
[the program is build with Intel C v8.]
It seems when it gets around 4GB it starts reading junk. I am not totally
sure because a 4GB file is not so easy to load into an editor.
Is there any known issues with reading such large files?
Erling
0 Kudos
1 Reply
gpi5
Beginner
389 Views

Hi,

you may use Win32 API function MapViewOfFile() to map any part of the file to memory and check what data actually are. This function can be safely used for files larger than 4Gb.

Regards,

Gpi5

0 Kudos
Reply