In assembler, how can we initialize the register to 0000?

HLASM for MVS. PL/I for MVS & Enterprise PL/I for z/OS.
Previous topicNext topic

Topic Author
RoyW
New Member
Posts: 7
Joined: Sun Jun 21, 2015 11:00 pm

In assembler, how can we initialize the register to 0000?

Post by RoyW » Wed Jul 01, 2015 12:08 pm

Hi,

In assembler, how can we initialize the register to 0000? Are there some best practices to choose from? Appreicate your help.




enrico-sorichetti
Global Moderator
Global Moderator
Posts: 892
Joined: Wed Sep 11, 2013 3:57 pm

Re: In assembler, how can we initialize the register to 0000

Post by enrico-sorichetti » Wed Jul 01, 2015 3:14 pm

Code: Select all

         SR    <your-reg>,<your-reg>
         ...
         XR    <your-reg>,<your-reg>
once upon a time
( when people looked at the smallest details to squeeze everything out of the CPU available )
XR was preferred for being slightly faster

nowadays the issue is probably irrelevant


cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort 8-)


Topic Author
RoyW
New Member
Posts: 7
Joined: Sun Jun 21, 2015 11:00 pm

Re: In assembler, how can we initialize the register to 0000

Post by RoyW » Tue Jul 21, 2015 10:22 pm

enrico thanks for your help.



Previous topicNext topic

Return to “Assembler & PL/I.”