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
 

 

problem with MVCL

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

New User


Joined: 31 Aug 2012
Posts: 25
Location: Australia

PostPosted: Tue Jan 08, 2013 7:07 pm    Post subject: problem with MVCL
Reply with quote

Hi ,

I am facing a strange problem with MVCL instruction , While execution of a program I found the below behavior of MVCl instruction which ultimately casuing error in output .

Code:
EQU     *                 
 MVCL    R0,R14     


Register values before execution of MVCL :
R0=3B8A8EA4 R1=0000000A
R14=3B8B1079 R15=0000000A

Data at R14 (3B8B1079) = versionabc

Register values after execution of MVCL
R0=3B8A8EAE R1=00000000
R14=3B8B1083 R15=00000000

There was no data copied to R0 location , After execution it has low values at r0 location .

The data for sending register r14 comes from a pds file .

Please throw some light as on why this is happening .

Regards

carol
Back to top
View user's profile Send private message

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10202
Location: italy

PostPosted: Tue Jan 08, 2013 7:19 pm    Post subject: Reply to: problem with MVCL
Reply with quote

not enough info posted!
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


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

PostPosted: Tue Jan 08, 2013 8:08 pm    Post subject: Reply to: problem with MVCL
Reply with quote

I understand your post is regarding MVCL, but the data-length is only 10. Couldn't you use an MVC instead, with a hard-coded length of 10 or as an Executed MVC? Seems like a waste of resources....
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10202
Location: italy

PostPosted: Tue Jan 08, 2013 8:10 pm    Post subject: Reply to: problem with MVCL
Reply with quote

still would be interesting to find out the reason for the not working situation
Back to top
View user's profile Send private message
PeterHolland

Global Moderator


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

PostPosted: Tue Jan 08, 2013 10:33 pm    Post subject:
Reply with quote

And why would you use R14,R15 as source? You got the same result with using another register pair?
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


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

PostPosted: Tue Jan 08, 2013 11:03 pm    Post subject: Reply to: problem with MVCL
Reply with quote

Dick,

An MVCL uses an even/odd set of registers for Operands 1/2.

The OP is correct by loading the RECEIVING address into R0 and the RECEIVING length into R1. R14 contains the SENDING address and R15 contains the SENDING length.

From what was posted, R1 and R15 contain the correct length (F'10') and we can only assume that the addresses in R0 and R14 are correct.

If the R1 length was less than the R15 length, then a pad-character (other than a X'00'), needs to be inserted in the high-order of R15, usually via an ICM, but that's not the case, because they're equal.

MVCL are often used with R0/R1 and R14/R15 (at least, IMHO).
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 Jan 09, 2013 2:49 am    Post subject: Reply to: problem with MVCL
Reply with quote

Thanks Bill,

I don't know what i was thinking but a bit later realized i was out in left field somewhere . . . So i deleted my bit of mis-information . . . icon_redface.gif

Thanks for the clarification icon_smile.gif

d
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


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

PostPosted: Wed Jan 09, 2013 4:50 am    Post subject: Reply to: problem with MVCL
Reply with quote

Carol,

I have to ask the obvious because we don't see anything wrong with your register usage.

After the MVCL, are you looking at address 3B8A8EAE for the expected data?

You need to look at address 3B8A8EA4.... icon_eek.gif
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10202
Location: italy

PostPosted: Wed Jan 09, 2013 5:25 am    Post subject: Reply to: problem with MVCL
Reply with quote

Very good guess Bill icon_wink.gif
Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7228

PostPosted: Wed Jan 09, 2013 6:46 am    Post subject: Reply to: problem with MVCL
Reply with quote

The only way the MVCL wouldn't work would be with "destructive overlap", which you don't have. So it worked. You could check the Condition Code to satisfy yourself.

Good shot Mr Bill.
Back to top
View user's profile Send private message
PeterHolland

Global Moderator


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

PostPosted: Wed Jan 09, 2013 12:42 pm    Post subject:
Reply with quote

Very nice, Bill.
Back to top
View user's profile Send private message
Jimy Carol

New User


Joined: 31 Aug 2012
Posts: 25
Location: Australia

PostPosted: Wed Mar 06, 2013 7:02 pm    Post subject: Re: Reply to: problem with MVCL
Reply with quote

Bill O'Boyle wrote:
Carol,

I have to ask the obvious because we don't see anything wrong with your register usage.

After the MVCL, are you looking at address 3B8A8EAE for the expected data?

You need to look at address 3B8A8EA4.... icon_eek.gif


Sorry for the late reply ..could'nt join the forum to see the discussion . I was wrong then as you correctly pointed the mistake i was doing to see the wrong address in R0 .
Thanks all for joining and Improving my knowledge about assembler .
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 Problem in writing Output file vickey_dw COBOL Programming 5 Mon Nov 14, 2016 11:14 pm
No new posts Problem in Running Query via JCL vickey_dw DB2 3 Tue Oct 18, 2016 11:11 pm
No new posts DB2 Streaming Batch Processing Problem Manshadi DB2 4 Sat Sep 24, 2016 12:14 pm
No new posts Problem with GETMAIN command amitc23 CICS 6 Thu Sep 01, 2016 1:01 pm
No new posts TXT2PDF problem - printing @ in PDF vipul65 All Other Mainframe Topics 9 Thu Aug 25, 2016 12:48 am


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