Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.os.msdos.programmer > #1271

Re: DOS memory model confusion...

From pete@nospam.demon.co.uk
Newsgroups comp.os.msdos.programmer
Subject Re: DOS memory model confusion...
Date 2014-02-01 07:39 +0000
Organization PDL
Message-ID <1391240391snz@nospam.demon.co.uk> (permalink)
References <d8aa40e0-2e77-4226-9a17-c5b301fd5e00@googlegroups.com>

Show all headers | View raw


On 31st Jan 2014 at 10:38 "Harry Potter" <rose.joseph12@yahoo.com> wrote:

> I'm sorry for the stupid question :( but I know what the tiny, compact, large 
> and huge DOS memory models look like but not the small and medium.  Which has 
> one code and multiple data segments, and which has one data and multiple code 
> segments?

Tiny: code, data, stack etc. all in 1 segment (so max prog size 64K)
Small: 1 code segment, 1 data segment (usually the default?)
Compact: 1 code seg, multiple data segs (small code, large data)
Medium: multiple code segs, 1 data seg (large code, small data)
Large: multiple code and data segs, max single object/array 64K
Huge: like large but with single object size restriction lifted

> Also, how do I handle memory segments and models in the Turbo C++ 3.0 and Open 
> Watcom 1.9 C compilers?

Read the doc!
Probably specifying -ms, -mc, -ml etc. on the command line.

Pete
-- 
Believe those who are seeking the truth.
Doubt those who find it.  -  André Gide

Back to comp.os.msdos.programmer | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

DOS memory model confusion... Harry Potter <rose.joseph12@yahoo.com> - 2014-01-31 10:38 -0800
  Re: DOS memory model confusion... pete@nospam.demon.co.uk - 2014-02-01 07:39 +0000
    Re: DOS memory model confusion... Harry Potter <rose.joseph12@yahoo.com> - 2014-02-03 06:42 -0800
    Re: DOS memory model confusion... "Gisle Vanem" <gvanem@yahoo.no> - 2014-02-12 17:39 +0100

csiph-web