[fa.info-vax] instruction set questions

info-vax@ucbvax.ARPA (11/29/84)

From: Provan@LLL-MFE.ARPA

Isn't

	MovL	foo,baz(r0)

equivalent to (i.e., at least as good as)

	PushAB	baz[r0]
	MovL	foo,@(sp)+

?

And isn't

	DecB	baz[r0]
	BEql	...

equivalent to (i.e., at least as good as)

	CvtBL	baz[r0],r1
	DecL	r1
	MovB	r1,baz[r0]
	TstL	r1
	BEql	...

(other than r1 getting clobbered)?

I'm asking because BLISS surprised me by producing the lower codes
instead of the upper ones.  Since BLISS usually optimizes reasonably
well, I can't figure out why it would go out of its way to make worse
code.  I was particularly upset because in the first case I was
anticipating a MovQ (since I was really moving two adjacent longwords)
and in the second the subtract and check eql has to be AST reentrent.
Anyone have any ideas why BLISS would do this to me?  (By the way, in
the second example, if the size is a longword instead of a byte, BLISS
does the DecL in place as you'd expect it to.)

If anyone wants to persue this more deeply, I'd suggest talking
directly to me, since this is unlikely to be of interest to much of the
list.

info-vax@ucbvax.ARPA (12/08/84)

From: Alan Lehotsky <allegra!linus!apollo!alan@BERKELEY>

You should give the BLISS source as well as the expanded machine
code.  While I'm rusty after 2 years out of the trenches, I'll
admit to being surprised at this.

    blissfully yours,
    Al Lehotsky,  Bliss-Wizard Emeritus