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 UNIT=AFF for Easytrieve code gandikk JCL & VSAM 7 Wed Jul 12, 2017 11:42 pm
No new posts DB2 Program abending without giving a... rahulgarg14 DB2 7 Mon May 29, 2017 8:10 pm
No new posts Job failing with USER = 4093 REASON C... Pradeepa S ABENDS & Debugging 1 Wed May 17, 2017 3:35 pm
No new posts Dump analysis of an assembler module monica1 PL/I & Assembler 4 Tue May 09, 2017 10:05 am
No new posts COBOL Code Parsers and Lineage Establ... balimanja COBOL Programming 2 Tue May 02, 2017 3:30 am


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