image size error


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 2 of 2

Thread: image size error

Hybrid View

  1. #1
    Patrick Guest

    image size error


    I am delcaring an array of a class I wrote:
    CMyClas* myClass[1000][1000][50]

    and am getting the error:

    warning LNK4084: total image size 384471040 exceeds max (268435456); image
    may not run

    What does this error mean? When I decrease the size of the array, it compiles
    and runs. Is there any way around this?

    Thanks in advance,

    -Patrick

  2. #2
    Danny Kalev Guest

    Re: image size error



    Patrick wrote:
    >
    > I am delcaring an array of a class I wrote:
    > CMyClas* myClass[1000][1000][50]
    >
    > and am getting the error:
    >
    > warning LNK4084: total image size 384471040 exceeds max (268435456); image
    > may not run
    >
    > What does this error mean?


    That the size of the executable file is too large for your operating
    system (it's really huge, nearly 400 megabytes!).

    When I decrease the size of the array, it compiles
    > and runs. Is there any way around this?


    Yes, decrease the size of the array and use swapping. In other words,
    use only a portion of the array at any given time and swap the rest to a
    disk file. Do you really need to access 50,000,000 pointers at once,
    which occupy 200 megabytes of memory?

    Danny Kalev

    "The ANSI/ISO C++ Professional Programmer's Handbook"
    http://www.amazon.com/exec/obidos/ASIN/0789720221

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center