Article View: bit.listserv.asm370
Article #347Re: SAVE/RETURN macros in AMODE 64
From: Edward E. Jaffe
Date: Fri, 16 Sep 2005 20:51
Date: Fri, 16 Sep 2005 20:51
60 lines
4063 bytes
4063 bytes
Steve Comstock wrote: > LARL R12,TEST64 > USING *,R12 Ignoring the fact that the above USING is wrong, 64-bit programs are intended to use relative addressing. Thus, the base register would normally cover constants and literals only (for reentrant code) and the work area (for non-reentrant code). That is, under normal circumstances, the LARL would not point to the start of the program. I believe these examples may be somewhat more typical: Reentrant code: | LARL R12,TEST64_Const Point to constants area | USING TEST64_Const,R12 Synchronize base register | STORAGE OBTAIN, Acquire the work area | LENGTH=WKAREA_LEN Acquire work area | STG R1,136(,R13) Chain save areas | STG R13,128(,R1) (same) | LGR R13,R1 Get area address in R13 | USING WKAREA,R13 Synchronize WKAREA | . | . | CNOP 0,8 Align to doubleword |TEST64_Const DC 0D Begin constants area | . | . | LTORG , Define literals | |WKAREA DSECT , Program work area DSECT | DS 18D Program save area | . | . |WKAREA_LEN EQU *-WKAREA Length of work area Non-reentrant code: | LARL R1,TEST64_Const Point to constants area | STG R1,136(,R13) Chain save areas | STG R13,128(,R1) (same) | LGR R13,R1 Get area address in R13 | USING TEST64_Const,R13 Synchronize base register | . | . | CNOP 0,8 Align to doubleword |TEST64_Const DC 0D Begin constants area | DC 18D'0' Define program save area | . | . | LTORG , Define literals -- ----------------------------------------------------------------- | Edward E. Jaffe | | | Mgr, Research & Development | edjaffe@phoenixsoftware.com | | Phoenix Software International | Tel: (310) 338-0400 x318 | | 5200 W Century Blvd, Suite 800 | Fax: (310) 338-0801 | | Los Angeles, CA 90045 | http://www.phoenixsoftware.com | -----------------------------------------------------------------
Technical Details
Message-ID:
<432B306F.4010405@phoenixsoftware.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!news.glorb.com!newspeer.tds.net!sn-xit-03!sn-xit-10!sn-xit-08!sn-xit-14!supernews.com!149.173.6.116.MISMATCH!foggy!vm.sas.com!phoenixsoftware.com!edjaffeReferences:
<432b0ef8$0$29922$ba620e4c@news.skynet.be> <432B1FDD.70706@trainersfriend.com>Show Full Headers
Complete Article Headers
X-Google-Thread: fcdcb,5aef08407a8abe43
X-Google-Attributes: gidfcdcb,public
X-Google-Language: ENGLISH,ASCII-7-bit
Path: arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!news.glorb.com!newspeer.tds.net!sn-xit-03!sn-xit-10!sn-xit-08!sn-xit-14!supernews.com!149.173.6.116.MISMATCH!foggy!vm.sas.com!phoenixsoftware.com!edjaffe
From: "Edward E. Jaffe" <edjaffe@phoenixsoftware.com>
Newsgroups: bit.listserv.asm370
Subject: Re: SAVE/RETURN macros in AMODE 64
Date: Fri, 16 Sep 2005 13:51:59 -0700
Organization: SAS Inc.
Lines: 60
Sender: IBM Mainframe Assembler List <ASSEMBLER-LIST@LISTSERV.UGA.EDU>
Message-ID: <432B306F.4010405@phoenixsoftware.com>
References: <432b0ef8$0$29922$ba620e4c@news.skynet.be>
<432B1FDD.70706@trainersfriend.com>
NNTP-Posting-Host: mozart.unx.sas.com
Mime-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
X-Trace: foggy.unx.sas.com 1126904523 5549 10.19.150.41 (16 Sep 2005 21:02:03 GMT)
X-Complaints-To: usenet@unx.sas.com
NNTP-Posting-Date: Fri, 16 Sep 2005 21:02:03 +0000 (UTC)
Comments: Gated by NETNEWS@VM.SAS.COM
Return-Path: <owner-assembler-list@LISTSERV.UGA.EDU>
User-Agent: Mozilla Thunderbird 1.0.6 (Windows/20050716)
X-Accept-Language: en-us, en
Approved-By: "Edward E. Jaffe" <edjaffe@PHOENIXSOFTWARE.COM>
In-Reply-To: <432B1FDD.70706@trainersfriend.com>
Return-Path: owner-assembler-list@LISTSERV.UGA.EDU
X-OriginalArrivalTime: 16 Sep 2005 21:02:00.0725 (UTC)
FILETIME=[E1C7B450:01C5BB01]
Originator: daemon@mozart.unx.sas.com