• Rajesh A R

F1 for Mainframe

F1 for Mainframe

Tag Archives: compiler

AMODE and RMODE

08 Thursday Mar 2012

Posted by rajeshar in COBOL

≈ Leave a comment

Tags

16MB, amode, COBOL, compiler, rmode

When you run COBOL programs, the programs and the data that they use reside in virtual storage. Storage that you use with COBOL can be either below the 16-MB line or above the 16-MB line but below the 2-GB bar. Two modes of addressing are available to address this storage: 24-bit and 31-bit.

Addressing mode (AMODE) is the attribute that tells which hardware addressing mode is supported by your program: 24-bit addressing, 31-bit addressing, or either 24-bit or 31-bit addressing. This attribute is AMODE 24, AMODE 31, or AMODE ANY, respectively. The object program, the load module, and the executing program each has an AMODE attribute. All Enterprise COBOL object programs are AMODE ANY.

Residency mode (RMODE) is the attribute of a program load module that identifies where in virtual storage the program will reside: below the 16-MB line, or either below or above. This attribute is RMODE 24 or RMODE ANY.
Significance of 16MB:
Nothing but 24 ‘1’ in binary format. That is the maximum value that can be stored in a 24-bit (3 byte) area.

With AMODE = 31, the maximum address value will be 2 GB (31 ‘1’ in binary format).

COBOL programs when compiled get translated into assembler first and then the assembler program is compiled to generate the load. Assembler uses something called registers to access memory locations. Each register is 4 bytes long (32-bits). In AMODE=24, only the first 3 bytes of the register are used for addressing. In AMODE=31, all 4 bytes except the leftmost is used for addressing. The extreme left byte is the sign bit.

Now this is conventional 32-bit machines. In 64-bit machines, the size of the register is 8 bytes. But so far, 64-bit OS still allows the programs to be loaded with AMODE=31.

If you would like to Earn Free Stocks, Credit card Points and Bank account Bonuses, Please visit My Finance Blog

You may also like to look at:

Important SQL CODES and ABEND CODES
SORT JOIN – TO JOIN TWO FILES BASED ON A KEY
KNOW YOUR MAINFRAME
REXX – INITIAL SETUP
CA7 – LJOB, LQ, LRLOG
CA7 – ASSIGN PF KEYS TO PERFORM YOUR COMMANDS
CA7 – LEAD TIME CONCEPT (LOOK BACK ISSUE)
CA7 Commonly used Commands
Mainframe Manuals/References/Guides/Documents Download Links
HEX Value 41 – Confused as SPACE (Hex value of 40)
EVER WONDERED WHAT DOES Z MEAN IN Z/OS
Search for a string that is in mixed case inside a PDS
S0C7 ISSUE – FIND THE INVALID (FAULT) DATA
HRECALL – MASS RECALL IN BATCH MODE
Nice Article to answer the myths on Mainframes
MAINFRAME – PS DATASET GETTING NUMBER AT END AUTOMATICALLY
MAINFRAME – GRANT and REVOKE Dataset Access
File Status Key Overview
TSO/E COMMANDS
SDSF; Status panel (ST) Columns
ABEND CODES
Glossary of z/OS terms and abbreviations
AMODE and RMODE
IMS INTERVIEW QUESTIONS
SDSF TIPS
NDM – FASTER MODE
FILEMAXX
BATCH PIPES
What is a Catalog
Conditional processing
Advertisement

Rate this:

Subscribe

  • Entries (RSS)
  • Comments (RSS)

Archives

  • November 2020
  • July 2020
  • February 2020
  • January 2020
  • September 2019
  • August 2019
  • October 2018
  • April 2018
  • March 2018
  • December 2017
  • October 2017
  • August 2017
  • July 2017
  • June 2017
  • April 2017
  • March 2017
  • February 2017
  • January 2017
  • December 2016
  • May 2016
  • March 2016
  • February 2016
  • January 2016
  • May 2015
  • September 2013
  • August 2013
  • July 2013
  • June 2013
  • May 2013
  • January 2013
  • December 2012
  • November 2012
  • April 2012
  • March 2012
  • February 2012
  • January 2012
  • April 2011
  • March 2011
  • August 2009
  • June 2009
  • April 2009

Categories

  • Azure
  • CA7
  • CICS
  • COBOL
    • Keywords
  • DB2
  • EASYTRIEVE
  • FILEAID
  • FILEMAXX
  • IMS
  • ISPF
  • JCL
  • KNOW YOUR MAINFRAME
  • Mainframe Migration
  • MAINFRAMES
  • Others
  • REXX
  • SDSF
  • SORT
  • Training
  • TSQL
  • VSAM

Meta

  • Register
  • Log in

Create a free website or blog at WordPress.com.

  • Follow Following
    • F1 for Mainframe
    • Join 88 other followers
    • Already have a WordPress.com account? Log in now.
    • F1 for Mainframe
    • Customize
    • Follow Following
    • Sign up
    • Log in
    • Report this content
    • View site in Reader
    • Manage subscriptions
    • Collapse this bar