Newsgroups: comp.lang.asm370
Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!sdd.hp.com!news.cs.indiana.edu!ux1.cso.uiuc.edu!phil
From: phil@ux1.cso.uiuc.edu (Phil Howard KA9WGN)
Subject: Re: MVCL (was Re: why code in 370 Assembler)
Message-ID: <1991Apr29.041733.17108@ux1.cso.uiuc.edu>
Organization: University of Illinois at Urbana
References: <9104261626.AA19688@ucbvax.Berkeley.EDU>
Distribution: inet
Date: Mon, 29 Apr 1991 04:17:33 GMT
Lines: 31

PERSHNG@YKTVMH3.BITNET ("John A. Pershing Jr.  784-7167", 914) writes:

>Invariably, registers 0, 1, 14, and 15 are available for use in an MVCL
>instruction -- with no saving/restoring of previous contents.  In fact,
>I rarely see Real Programmers using any other registers with an MVCL!

Mostly I use R2/3 and R4/5 and sometimes R6/7.  Occaisionally I use
R14/15 but very rarely R0/1 because R0 is pretty useless for addresses.

The reason I may be different than what you see usually done is because
of the ways I go about assigning register usage.  I usually do it, and
the coding, backwards.

>Note that MOVE LONG cannot handle strings that are longer than 16 Megs
>(the length fields are only the bottom 24 bits of the odd registers).
>However, if you are dealing with objects whose sizes are measured in
>megabytes, you probably shouldn't be moving them around, anyway...

Where this might end up being a problem is where resultant usage of a
program ends up exceeding 16 megabytes by a user of the program who
needed to really stuff the program in ways the original programmer
never thought of.  I agree on the advice of not moving so much data.
Doing things like exchanging addresses would be far better.  Still
there are times it cannot be avoided, and it would be good advice to
always test lengths when they come from circumstances where you cannot
be sure they are under the 16 megabyte limit.
-- 
 /***************************************************************************\
/ Phil Howard -- KA9WGN -- phil@ux1.cso.uiuc.edu   |  Guns don't aim guns at  \
\ Lietuva laisva -- Brivu Latviju -- Eesti vabaks  |  people; CRIMINALS do!!  /
 \***************************************************************************/
