IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Question: Why can't I specify AMODE 24 and RMODE ANY?


IBM Mainframe Forums -> COBOL Programming
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
applestu

New User


Joined: 07 Aug 2008
Posts: 3
Location: China

PostPosted: Sat Sep 06, 2008 3:51 pm
Reply with quote

Hi everyone.
as the subject shows "Why can't I specify AMODE 24 and RMODE ANY?"

In my understanding, the RMODE just indicates the location where the program can be loaded in the virtual storage. Isn't the program using "offset address" to process the functions? icon_confused.gif So if the program's working storage is less than 16M, I think the program could run well regardless the program is loaded above or below the line Virtual Storage.

By the way, how big central memory could S/390 CP use, 2G, 4G or other values?

Thanks in advance! icon_smile.gif
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Sat Sep 06, 2008 5:37 pm
Reply with quote

Quote:

Every program that runs in MVS/ESA is assigned two attributes,
an AMODE (addressing mode) and an RMODE (residency mode):

AMODE Specifies the addressing mode in which the program is
designed to receive control. Generally, the program is also designed to run
in that mode, although a program can switch modes and can have different
AMODE attributes for different entry points within a program module.
MVS/ESA uses a program's AMODE attribute to determine whether a
program invoked using ATTACH, LINK, or XCTL is to receive control in
24-bit or 31-bit addressing mode.

RMODE Indicates where the program can reside in virtual storage.
MVS/ESA uses the RMODE attribute to determine whether a program
must be loaded into virtual storage below 16 megabytes, or can reside
anywhere in virtual storage (above or below 16 megabytes).

Code:
Valid AMODE and RMODE specifications are:
Attribute                      Meaning

AMODE=24                 24-bit addressing mode

AMODE=31                 31-bit addressing mode

AMODE=ANY               Either 24-bit or 31-bit addressing mode


RMODE=24                 The module must reside in virtual storage below
                                 16 megabytes.  Use RMODE=24 for programs that
                                 have 24-bit dependencies.

RMODE=ANY              Indicates that the module can reside anywhere in
                                storage, which includes addresses above the 16
                                megabyte line.
Back to top
View user's profile Send private message
applestu

New User


Joined: 07 Aug 2008
Posts: 3
Location: China

PostPosted: Sat Sep 06, 2008 7:31 pm
Reply with quote

dbzTHEdinosauer,
Thanks, but you're not answering my questions.

What I meant is "The attribute of AMODE(24) does not conflict with the program's residence above the 16M line which is RMODE(ANY)".
Back to top
View user's profile Send private message
MBabu

Active User


Joined: 03 Aug 2008
Posts: 400
Location: Mumbai

PostPosted: Sat Sep 06, 2008 8:15 pm
Reply with quote

How is an amode 24 program at a 31 bit, >16M address line supposed to refer to parts of itself. Where would a Branch instruction branch to?
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Sun Sep 07, 2008 12:07 am
Reply with quote

Hello,

An analogy. . .

Let's suppose there is an array/spreadsheet (x,y) that is ten by ten.

Where would coordinates 15,23 be located?

Some coordinates might work and others would be "off che chart" if AMODE 24 and RMODE ANY were specified, so this is prohibited.
Back to top
View user's profile Send private message
applestu

New User


Joined: 07 Aug 2008
Posts: 3
Location: China

PostPosted: Sun Sep 07, 2008 11:29 am
Reply with quote

Thanks every one.
I got it.

I thought the AMODE(24) means the program can handle 16M space from the begining of the program in the virtual storage. But now from what you said, the AMODE(24) just mean the virtual address below the 16M, not the offset from the begining of the program.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> COBOL Programming

 


Similar Topics
Topic Forum Replies
No new posts Question for file manager IBM Tools 7
No new posts question for Pedro TSO/ISPF 2
No new posts question on Outrec and sort #Digvijay DFSORT/ICETOOL 20
No new posts panel creation question TSO/ISPF 12
No new posts Sort w/OUTREC Question DFSORT/ICETOOL 2
Search our Forums:

Back to Top