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

Assembler - loading the register


IBM Mainframe Forums -> PL/I & Assembler
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
sabarikanth

New User


Joined: 07 Jun 2010
Posts: 59
Location: coimbatore

PostPosted: Fri Jun 11, 2010 11:44 am
Reply with quote

Is this instruction valid?
loading the register. How it works explain in detail plz.

Code:

 L     R11,=F'20'   
Back to top
View user's profile Send private message
PeterHolland

Global Moderator


Joined: 27 Oct 2009
Posts: 2481
Location: Netherlands, Amstelveen

PostPosted: Fri Jun 11, 2010 12:26 pm
Reply with quote

Principles of Operation SA22-7832-02
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


Joined: 14 Jan 2008
Posts: 2501
Location: Atlanta, Georgia, USA

PostPosted: Fri Jun 11, 2010 4:17 pm
Reply with quote

You could also issue one of the following, which will save a LTORG addition -

Code:

         LA    R11,20        LOAD R11 WITH X'00000014'

-O R-

Code:

         LHI   R11,20        LOAD R11 WITH X'00000014'

The "LA" instruction (Load Address) can load a maximum value of 4095 (X'0FFF') into a register, whereas, the "LHI" instruction (Load Halfword Immediate) can load a maximum value of 32767 (X'7FFF').

If you need to load a value of more than 32767 into a register, use the "L" (Load) instruction, with which you provided.

All values loaded into a general purpose, 32-bit register, use the full four-bytes.

Bill
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 -> PL/I & Assembler

 


Similar Topics
Topic Forum Replies
No new posts Build dataset list with properties us... PL/I & Assembler 4
No new posts Finding Assembler programs PL/I & Assembler 5
No new posts How Can I Recall a Migrated Data Set ... PL/I & Assembler 3
No new posts step by step trace 4 ISPF dialog call... TSO/ISPF 17
No new posts Getting SOC4 while calling a Cobol DB... PL/I & Assembler 4
Search our Forums:

Back to Top