Article View: comp.sys.ibm.pc.programmer
Article #478Re: Group DGROUP exceeds 64K
From: Paul Penrod
Date: Sat, 05 Sep 1992 18:06
Date: Sat, 05 Sep 1992 18:06
49 lines
2233 bytes
2233 bytes
In article <rdippold.715665099@cancun> rdippold@cancun.qualcomm.com (Ron Dippold) writes:
>lars_s@gemini.ldc.lu.se (Lars Sigebo) writes:
>>I'm using Borland C++ version 3.0 in large memory model and are trying to
>>link a couple of modules. I got this message from TLINK:
>
>> Error: Group DGROUP exceeds 64K
>
>Move your "static" declarations in functions out to the top level of
>the file, from:
>
>main()
>{
> static int big[30000];
> /* lotsa stuff */
>}
>
>to
>
>static int big[30000];
>main()
>{
> /* lotsa stuff */
>}
>
>The same thing happens under Microsloth C. Pain in the ass, and nasty
>for scoping, but Intel real mode is Intel real mode...
>--
>Q: Why did the tachyon cross the road? A: Because it was on the other side.
One other suggestion is to declare any large structures of arrays
to be far. This will force them into their own data segment and
allow the Large Model to link without incident. Under Large Model,
far pointers are the rule, but they only operate 16 bit offsets, so
the largest structure or declaration(s) you can have must not total
more than 64K per segment . Also be aware that storage space is required for
arrays and structures so you can not legally declare something
like:
char foo[65535];
because of the storage space required to declare and utilize the
array at runtime. If you need to have larger structures, then use
Huge Model, which uses true 32 bit (normalized) pointers.
--
--------------------------------------------------------------------
Bureaucracy: noun, plural - Bureaucracies.
The process of turning energy into solid waste.
---------------------------------------------------------------------
Technical Details
Message-ID:
<1992Sep5.180634.3637@sequent.com>Path:
arc1-ca.pugleaf.net!sparky!uunet!sequent!muncher.sequent.com!furballsReferences:
<1992Sep4.213550.13151@pollux.lu.se> <rdippold.715665099@cancun>Show Full Headers
Complete Article Headers
Newsgroups: comp.sys.ibm.pc.programmer,comp.os.msdos.programmer Path: arc1-ca.pugleaf.net!sparky!uunet!sequent!muncher.sequent.com!furballs From: furballs@sequent.com (Paul Penrod) Subject: Re: Group DGROUP exceeds 64K Message-ID: <1992Sep5.180634.3637@sequent.com> Sender: usenet@sequent.com (usenet ) Nntp-Posting-Host: crg8.sequent.com Organization: Sequent Computer Systems Inc. References: <1992Sep4.213550.13151@pollux.lu.se> <rdippold.715665099@cancun> Date: Sat, 5 Sep 92 18:06:34 GMT Lines: 49