Toni Gorrengourt, TERRA Basel                    18-Feb-92, Ref. TB-920218.2
============================================================================

Subject: M2 V4.00 / Bad Stack Check Code is Generated When Using /DATA:L
------------------------------------------------------------------------

When compiling a module with stack check enabled (/CHECK:S) and using
the large data model (/DATA:L), bad code/fixup info (segment instead of
DGROUP relative offset?) is generated for calling the stack test
procedure (procedure variable SYSTEM_StackCheck).

This applies to the module init code as well as to any procedure in
the module. In particular, it even happens if the init code is empty,
unless its generation is prevented by means of /NOMODINIT.

Workaround: Compile with stack test off. If you dislike this, separate
the large data into a module that does not contain any code. Compile
that new module with stack test off and /DATA:L, and compile the
modified original module using the medium data model /DATA:M (default)
and with stack tests.

                                * * *
