Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

what does this assembler code do

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> PL/I & Assembler
View previous topic :: :: View next topic  
Author Message
rammraju

New User


Joined: 05 Mar 2005
Posts: 65
Location: Hyderabad

PostPosted: Tue Oct 09, 2007 12:09 am    Post subject: what does this assembler code do
Reply with quote

Hi,
can anyone please let me know what is happening in the following part of code. I am not finding the explanation for these instructions anywhere.


Code:

EXAMPLE1  START
                 STM       14,12,12(13)
                 LR        3,15
                 USING     EXAMPLE1,3
                 L         4,0(1)
                 L         5,4(1)
                 MVC       0(8,5),=C'11111111'
LBL1             TM        0(4),C'AB'
                 BO        LBL2
                 MVI       0(5),C' '
LBL2             TM        0(4),C'CD'
                 BO        LBL3
                 MVI       1(5),C' '
LBL3             LM        14,12,12(13)
                 BR        14
                 LTORG
                 CSECT
                 DC        CL24'@@@001EXAMPLE2  11/11/11'
                 END       EXAMPLE1




It would be helpful if i can get to know what is happening in each step.
Back to top
View user's profile Send private message

dick scherrer

Site Director


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

PostPosted: Tue Oct 09, 2007 3:04 am    Post subject:
Reply with quote

Hello,

The assembler instructions in the posted code are among the most basic in the language. If these are not yet familiar to you, i'd suggest you do a bit more research.

The first link shows a list of most assembler instructions. The second is to an IBM Introduction for Assembler.

http://www.simotime.com/asmins01.htm

http://ulita.ms.mff.cuni.cz/pub/predn/swi119/AssemblerIBM_390.pdf
Back to top
View user's profile Send private message
CICS Guy

Senior Member


Joined: 18 Jul 2007
Posts: 2150
Location: At my coffee table

PostPosted: Tue Oct 09, 2007 5:03 am    Post subject: Re: what does this assembler code do
Reply with quote

rammraju wrote:
It would be helpful if i can get to know what is happening in each step.

What's 'a matter Dick, couldn't you just try to answer the question?
Code:
EXAMPLE1  START
                 STM       14,12,12(13)
                 LR        3,15
                 USING     EXAMPLE1,3
set up a base reg
                 L         4,0(1)
get the first parm
                 L         5,4(1)
get the second parm
                 MVC       0(8,5),=C'11111111'
Move X'FF' to the second parm
LBL1             TM        0(4),C'AB'
Eww, that's one I gotta look up....Testing the first byte of a passed parm with what should be an immeadiate, but is actually an addtess of X'C1C2' off of zero.....Or do I have it backward....grin....
Beyond this, I'm needing my POP and green card.....
                 BO        LBL2
                 MVI       0(5),C' '
LBL2             TM        0(4),C'CD'
                 BO        LBL3
                 MVI       1(5),C' '
LBL3             LM        14,12,12(13)
                 BR        14
                 LTORG
                 CSECT
                 DC        CL24'@@@001EXAMPLE2  11/11/11'
                 END       EXAMPLE1
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> PL/I & Assembler All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts JCL to Set Return code based on DB2 S... vinu78 DB2 17 Mon Mar 13, 2017 9:47 pm
No new posts IMS region inactive - User abend code... gthmrj IMS DB/DC 5 Tue Mar 07, 2017 12:29 pm
No new posts CA Workload Automation event code help vinu78 CA Products 10 Wed Mar 01, 2017 10:05 am
No new posts MAX-RC 88 and Return code 606 in DFH0... lind sh CICS 2 Tue Jan 24, 2017 1:23 pm
No new posts How to Capture the Max return code of... anilkumar922 All Other Mainframe Topics 2 Thu Jan 12, 2017 12:02 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us