Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1047237
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T16:16:11+00:00 2026-05-16T16:16:11+00:00

I am using CreateFileMapping and MapViewOfFile to try and map an almost 1 GB

  • 0

I am using CreateFileMapping and MapViewOfFile to try and map an almost 1 GB file. I was having some problems with extending the file so I thought that I would try using CreateFileMapping with a 1 GB size. That is larger than the actual file, but it works well on smaller files.

It seems that I can get almost to a 1 GB mapping, but not all the way. It is about 16 MB short of 1 GB.

I am using SysInternals VMMap program to view the layout of the pieces in my test program. It is very strange to me. VMMap shows me that there is free virtual memory space right after my map!

Why can I not use it?

It looks a bit like this:
0x3F6E0000 <- this piece is allocated to my test program
0x406E0000 <- this piece is free and almost 800 MB in size! Give it to me!

Is there magic about that area of memory over 0x40000000? If so, then why did it let me use up 0x6E0000 of it?

By the way, the test program is using MapViewOfFile in 64 individual segments which is why that 0x3F6E0000 piece is not that big.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T16:16:11+00:00Added an answer on May 16, 2026 at 4:16 pm

    This is a long shot, but it could be that something small is mapped near 0x40000000 (maybe a DLL?), and since the kernel cannot find a contiguous VA space that is the size you want (i.e. you’ve got enough, but it’s split up), it fails. If you want to map in gigantic files, it’s much easier on a modern architecture – as you only get maybe 1.5GB guaranteed VA space for user-mode processes on Windows once you subtract all the DLLs and heap.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I would like to avoid using CreateFileMapping/MapViewOfFile to rewrite part of a file. Does
I currently try to implement some interprocess communication using the Windows CreateFileMapping mechanism. I
How to list all the file mappings that were created/opened using CreateFileMapping()/OpenFileMapping?
Using TortoiseSVN against VisualSVN I delete a source file that I should not have
Using ASIHTTPRequest, I downloaded a zip file containing a folder with several audio files.
I'm concerned about the dangers of using memory-mapped IO, via CreateFileMapping , on FAT
Using Rails 3.2.0 with haml and sass: I Would like to link an external
How can I write from a file to shared memory using the Win32 API?
What is the advantage of using a memory-mapped file backed by the system paging
I tried to list imported DLL of PE file using following code, but it

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.