PRB: F1050: Code Segment Too Large

Last reviewed: July 18, 1995
Article ID: Q49515
The information in this article applies to:
  • Microsoft FORTRAN for MS-DOS, versions 3.3, 3.31, 4.0, 4.01, 4.1, 5.0, 5.1
  • Microsoft FORTRAN for OS/2, versions 4.1, 5.0, 5.1

SYMPTOMS

An attempt to compile an application fails and the compiler generates the following message:

   F1050: CODE SEGMENT TOO LARGE

CAUSE

The amount of code in one module exceeds 64K. Microsoft FORTRAN places the code from each "module," or compiled source file, into its own segment. Therefore, each module is restricted to 64K or less in both MS-DOS and OS/2 (unless using flat model).

RESOLUTION

To avoid this problem, break the source file into separate source files, compile each source file separately, and link the application into an EXE file. If the original source file contains subroutines or functions, place some of them into a separate source file. Otherwise, first break the source code into subroutines or functions and apply the methods listed above.


Additional reference words: 3.30 4.00 4.10 5.00 5.10 VAX port
KBCategory: kbtool kberrmsg kbprb
KBSubcategory: FLIss


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: July 18, 1995
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.