🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.arch
Article #10651

Re: Three Address vs Two Address Architectures

#10651
From: Randell Jesup
Date: Mon, 06 May 1991 19:28
28 lines
2058 bytes
In article <SPOT.91May5235753@WOOZLE.GRAPHICS.CS.CMU.EDU> spot@CS.CMU.EDU (Scott Draves) writes:
>As far as i can tell, on a typical RISC machine, the biggest (only?)
>advantage to 2-address ops is it saves you instruction bits.

	The RPM-40 did this in order to get 16 bit instructions.

>what if you made a machine with two sorts of every op: one that was
>2-address, and one that was 3-address.  The two address ones could
>access only part of the register file.

	From experience, that can make compiler/backend writing a nightmare.
The other win from a 2-address architecture (or rather a restated win) is
that you can directly address ~1.5 times as many bits of registers in the
same length instruction.  For example, if you can address 16 registers in a
3-address architecture, you can address 64 registers in a two-address
architecture.  Interesting tradeoff - occasional extra instruction versus
more spills.  The weighting of the tradeoff will probably depend on the type
of code being dealt with and the cost of memory accesses (for the spills).
Lots more regs may cause you to change other things like subroutine
interfaces.

-- 
Randell Jesup, Keeper of AmigaDos, Commodore Engineering.
{uunet|rutgers}!cbmvax!jesup, jesup@cbmvax.commodore.com  BIX: rjesup  
Disclaimer: Nothing I say is anything other than my personal opinion.
Thus spake the Master Ninjei: "To program a million-line operating system
is easy, to change a man's temperament is more difficult."
(From "The Zen of Programming")  ;-)
Technical Details
Message-ID: <21296@cbmvax.commodore.com>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!usc!wuarchive!uunet!cbmvax!jesup
References: <22476@shlump.nac.dec.com> <1991May3.142835.9196@webo.dg.com> <SPOT.91May5235753@WOOZLE.GRAPHICS.CS.CMU.EDU>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!usc!wuarchive!uunet!cbmvax!jesup
From: jesup@cbmvax.commodore.com (Randell Jesup)
Newsgroups: comp.arch
Subject: Re: Three Address vs Two Address Architectures
Message-ID: <21296@cbmvax.commodore.com>
Date: 6 May 91 19:28:47 GMT
References: <22476@shlump.nac.dec.com> <1991May3.142835.9196@webo.dg.com> <SPOT.91May5235753@WOOZLE.GRAPHICS.CS.CMU.EDU>
Reply-To: jesup@cbmvax.commodore.com (Randell Jesup)
Organization: Commodore, West Chester, PA
Lines: 28