Click here to Skip to main content
15,922,407 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionHuge size files IO- Performance issue? Pin
jayart21-Jun-06 3:53
jayart21-Jun-06 3:53 
AnswerRe: Huge size files IO- Performance issue? Pin
jayart21-Jun-06 3:56
jayart21-Jun-06 3:56 
QuestionRe: Huge size files IO- Performance issue? Pin
David Crow21-Jun-06 4:11
David Crow21-Jun-06 4:11 
AnswerRe: Huge size files IO- Performance issue? Pin
jayart21-Jun-06 6:02
jayart21-Jun-06 6:02 
GeneralRe: Huge size files IO- Performance issue? Pin
David Crow21-Jun-06 6:21
David Crow21-Jun-06 6:21 
GeneralRe: Huge size files IO- Performance issue? Pin
Zac Howland21-Jun-06 4:21
Zac Howland21-Jun-06 4:21 
AnswerRe: Huge size files IO- Performance issue? Pin
Ryan Binns21-Jun-06 4:29
Ryan Binns21-Jun-06 4:29 
AnswerRe: Huge size files IO- Performance issue? Pin
James R. Twine21-Jun-06 6:52
James R. Twine21-Jun-06 6:52 
   I would suggest memory mapping sections of the file, like 5MB at a time, if you are going to be paging through the file.  As you approach the end of a 5MB segment, look for an end of page marker and then reset the map starting at that marker.  You can do the same thing paging backwards, too.

   Remember that if you want to map the entire file in memory, you need a contigious address range available, which starts to get tricky when you get to sizes that are around 1GB+, let alone much larger.

   You will not be able to map files that approach 2GB in size because IIRC, by default a Win32 process only gets 2GB of user address space allocated to it, and your application has likely already used some portion of that space.  To map entire files that are 2GB and above, you will likely have to research the /3GB linker switch and how to write for and work with PAE and/or AWE.  Such things are generally far beyond the scope of this message board! Smile | :)

   Peace!

-=- James
If you think it costs a lot to do it right, just wait until you find out how much it costs to do it wrong!
Avoid driving a vehicle taller than you and remember that Professional Driver on Closed Course does not mean your Dumb Ass on a Public Road!
DeleteFXPFiles & CheckFavorites
(Please rate this post!)
Questionabout FARPROC* Pin
George_George21-Jun-06 3:05
George_George21-Jun-06 3:05 
AnswerRe: about FARPROC* Pin
zouchao111221-Jun-06 3:14
zouchao111221-Jun-06 3:14 
GeneralRe: about FARPROC* Pin
George_George21-Jun-06 17:20
George_George21-Jun-06 17:20 
AnswerRe: about FARPROC* Pin
Sarath C21-Jun-06 3:22
Sarath C21-Jun-06 3:22 
GeneralRe: about FARPROC* Pin
George_George21-Jun-06 17:35
George_George21-Jun-06 17:35 
AnswerRe: about FARPROC* Pin
David Crow21-Jun-06 3:29
David Crow21-Jun-06 3:29 
GeneralRe: about FARPROC* Pin
George_George21-Jun-06 17:40
George_George21-Jun-06 17:40 
GeneralRe: about FARPROC* Pin
David Crow22-Jun-06 2:39
David Crow22-Jun-06 2:39 
GeneralRe: about FARPROC* Pin
George_George24-Jun-06 2:09
George_George24-Jun-06 2:09 
GeneralRe: about FARPROC* Pin
David Crow26-Jun-06 2:44
David Crow26-Jun-06 2:44 
GeneralRe: about FARPROC* Pin
George_George27-Jun-06 2:17
George_George27-Jun-06 2:17 
GeneralRe: about FARPROC* Pin
David Crow27-Jun-06 3:15
David Crow27-Jun-06 3:15 
GeneralRe: about FARPROC* Pin
George_George27-Jun-06 3:43
George_George27-Jun-06 3:43 
GeneralRe: about FARPROC* Pin
David Crow27-Jun-06 3:48
David Crow27-Jun-06 3:48 
GeneralRe: about FARPROC* Pin
George_George27-Jun-06 4:14
George_George27-Jun-06 4:14 
AnswerRe: about FARPROC* Pin
Sarath C21-Jun-06 3:35
Sarath C21-Jun-06 3:35 
GeneralRe: about FARPROC* Pin
George_George21-Jun-06 17:33
George_George21-Jun-06 17:33 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.