Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!decvax!bellcore!ulysses!burl!clyde!cbatt!cbosgd!ihnp4!inuxc!pur-ee!ecn-pc!sandersr From: sandersr@ecn-pc.UUCP (Robert C Sanders) Newsgroups: net.micro Subject: Re: 8086 large model compiler? Message-ID: <617@ecn-pc.UUCP> Date: Sun, 3-Aug-86 05:18:14 EDT Article-I.D.: ecn-pc.617 Posted: Sun Aug 3 05:18:14 1986 Date-Received: Sun, 3-Aug-86 23:54:49 EDT References: <2794@sdcc6.ucsd.EDU> Reply-To: sandersr@ecn-pc.UUCP (Robert C Sanders) Distribution: na Organization: Electrical Engineering Department , Purdue University Lines: 57 In article <2794@sdcc6.ucsd.EDU> ix264@sdcc6.ucsd.EDU (ix264) writes: > .... It develops, however, that the >Microsoft C compiler limits me to 64k of data in any program. >That is, in words I didn't understand until yesterday, it >produces only small or middle model code executable on the 8086. ... > > Is there any way around this? I am willing to pay for >software, but not for a new machine. I don't know about >computer architecture or assembly language programming, and I >don't want to learn (how's that for a hardened user? :-). If >there's no alternative to that, though, I'm willing. What >I hope to find would be either > >1. Some sort of software letting my existing compiler and >operating system use the memory it seems to me is right in front >of their faces (is my frustration showing?), or > >2. Another compiler which can produce code executable on the >8086 using lots of memory for data, either static or dynamic or >both, I don't care. Ideally it would run under Xenix, but >MS-DOS is fine. I'd prefer C, but am willing to look at other >languages. Do such compilers exist, or are they impossible >under the constraints of the 8086? > > Tim McLarnan Are you absolutely sure about this? I think that it DOES allow large model data. My experience is with Computer Innovations C86 C compiler over MS C (they are fairly similar), but I know that all I have to do is change the default #defines at the front of my code, and I can increase the stack/heap up to the limits of memory (they are normally set for 96K to allow for the system() call the call up command.com and whatever program). This means I have to malloc() or calloc() memory for the array, but that is no problem; I just read it in from a file. I too have a program that utilizes a HUGE data array, and I do use all 476K of main memory I have left after the program loads. Remember, you can't declare the array directly; declare a pointer instead, and calloc the memory required -- MS C should also have a function the tests whether there is any memory left, and return how much like CII C86 does. I even created an OBJ file that I link in front of the program that resets all of CI-C86 default values to use all of the rest of the memory -- it just asks for FFFF segments (I even included an option in my "cc" executive for the various-passes-of-the-compiler/MASM/LINK, -H, for "huge" model that just links the OBJs in order). I think MS C can do this too; but if not, I *KNOW* CII C86 does. -- Continuing Engineering Education Telecommunications Purdue University ...!ihnp4!pur-ee!pc-ecn!sandersr Let's make like a BSD process, and go FORK-OFF !! -- bob (and "make" a few children while we're at it ...)