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
 

 

Clarification required in ASSEMBLER Instructions

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

New User


Joined: 02 Apr 2007
Posts: 1
Location: India

PostPosted: Tue May 15, 2007 1:09 pm    Post subject: Clarification required in ASSEMBLER Instructions
Reply with quote

Iam working on an asembler program. assembler is very new to me.I have strucked at some assembler instructions.Please clarify the following instructions
1. BNH -- what is the meaning of Branch on high instruction?
2 BNL
3 ANOP
4 MVC WSAFCDI,12(R2)-- what 12 signifies here?
5. USING SWAFCDST,R1 --- What does this using instruction signifies?
6. LM RE,RC,ILCSVRGR-- How does this multiple load instruction works?
7. OI TIMEKEY+L'TIMEKEY-1
8. MVC 250(250,R8),0(R8) how does this instruction works?
9. MVCL RE,R0
10. LTR R1,R1
11. S R1, R1 -- Why do we subtract registers?
Back to top
View user's profile Send private message

William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3158
Location: Tucson AZ

PostPosted: Tue May 15, 2007 2:43 pm    Post subject:
Reply with quote

Start with High Level Assembler for MVS & VM & VSE IBM Programmer?s Guide. Refer to the Bibliography for additional pointers and download a copy of the Principles of Operation.
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: Wed May 16, 2007 12:52 am    Post subject:
Reply with quote

Hello,

There is a book from Murach Publishing written by Kevin McQuillen that is very good for people just starting in assembler. It begins from knowing nothing of assembler syntax and the instructions. Once you complete that book, the ibm reference manuals have more detail.

The ibm manuals are excellent for resolviing a question, but i do not believe them to be a good way to learn from scratch.
Back to top
View user's profile Send private message
bengtpelle

New User


Joined: 28 Aug 2006
Posts: 24
Location: St. Petersburg, FL

PostPosted: Wed May 16, 2007 3:46 am    Post subject: Re: Clarification required in ASSEMBLER Instructions
Reply with quote

1. BNH -- what is the meaning of Branch on high instruction?
Branch if NOT High same as Low or Equal.
2 BNL
Branch if NOT Low same as High or Equal.
3 ANOP
A simple way to set a label on this instruction. It does nothing.
4 MVC WSAFCDI,12(R2)-- what 12 signifies here?
12 bytes after the address in R2
5. USING SWAFCDST,R1 --- What does this using instruction signifies?
It tells the assembler which base register to use.
6. LM RE,RC,ILCSVRGR-- How does this multiple load instruction works?
It wraps around, start ting with register RE-RF Then R0-RC
7. OI TIMEKEY+L'TIMEKEY-1,X'F0"
Invalid instruction. You need one byte after the -1. I added the X'F0'
Basically it it sets a numerical zone in the last byte of a field.
8. MVC 250(250,R8),0(R8) how does this instruction works?
It moves the 250 bytes pointed to by R8 to an area 250 bytes after the address in R8.
9. MVCL RE,R0
10. LTR R1,R1
Used to test if R1 is zero or not.
11. S R1, R1 -- Why do we subtract registers?
This is an invalid instruction. It should be an SR R1,R1.
It is a way to set the register to zero.
Back to top
View user's profile Send private message
UmeySan

Active Member


Joined: 22 Aug 2006
Posts: 757
Location: Germany

PostPosted: Tue May 22, 2007 5:42 pm    Post subject:
Reply with quote

Hi !

There is only one quest open, nr. 9, MVCL RE,R0

Just to complete:

MVCL = Move Character Long

This instruction is the same as MVC. But it can be used to move fields greater than 255 bytes.

Format is MVCL R2,R4

First operand and second operand are register-pairs.
So R2 and R3, R4 and R5

Each of the specified registers in the command must be an even register that is used to designate an even-odd pair of registers. The contents of the field specified by R4 are moved to the field specified by R2.

R2 EVEN register - the last 3 bytes specify the address of the destination field. Adress in R2

R2 ODD register - the last 3 bytes specify the length of the destination field. Length in R3

R4 EVEN register - the last 3 bytes specify the address of the source field
Adress in R4

R4 ODD register - the last 3 bytes specify the length of the source field. The first byte is used as a pad character if the source field is shorter than the destination field. Length in R5

Regards , UmeySan
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 Dump analysis of an assembler module monica1 PL/I & Assembler 4 Tue May 09, 2017 10:05 am
No new posts A not very Christmassy PL/I tale, wit... prino PL/I & Assembler 3 Mon Dec 26, 2016 1:01 am
No new posts Online Assembler Program Starting point Aditya.Srivastava PL/I & Assembler 4 Fri Jul 08, 2016 6:48 pm
No new posts FTP help required amitc23 All Other Mainframe Topics 3 Thu Apr 28, 2016 12:02 pm
No new posts Why Newcopy is required when we have ... DIXINSH CICS 5 Thu Apr 28, 2016 9:47 am


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