What's the maximum memory that a single COBOL program can address?
QUESTION POSED ON: 24 MAR 2005
QUESTION ANSWERED BY: Tom Ross
Well, you don't specify a compiler or an operating system, or whether you are interested in LINKAGE SECTION, WORKING-STORAGE SECTION, LOCAL-STORAGE, FILE SECTION or all of them together. For IBM Enterprise COBOL on mainframes, the answers are in the "Compiler Limits" appendix of the Language Reference Manual.
The main limiting factor is which compiler (OS/VS COBOL only used 24-bit addresses) and operating system (31-bit mainframes can have 2 GBs of memory, or just over 2 billion) In Enterprise COBOL you could address 2 GBs of files or 2 GBs of WORKING-STORAGE, but you can't address 4 GBs at a time, since the system can't hold that many bytes for an AMODE 31 program.
There is no AMODE 64 COBOL on z/OS yet, and really no need for one, but we are looking at doing it anyway someday. There are many COBOL programs today that run just fine with AMODE 24, so they still have lots of room to expand and still be only AMODE 31. One thing we are looking at closely is expanding the size of a single data item from 16 million to 2 billion bytes; people would be able to use that right away for working with large XML documents.
|
 |
|