Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!linus!decvax!genrad!panda!talcott!harvard!seismo!mcvax!unido!ztivax!david From: david@ztivax.UUCP Newsgroups: net.arch Subject: Re: Addressing modes Message-ID: <2900001@ztivax.UUCP> Date: Tue, 4-Mar-86 10:34:00 EST Article-I.D.: ztivax.2900001 Posted: Tue Mar 4 10:34:00 1986 Date-Received: Sat, 8-Mar-86 07:30:24 EST References: <946@garfield.UUCP> Sender: notes@unido.UUCP Lines: 56 Nf-ID: #R:garfield:-94600:ztivax:2900001:000:2614 Nf-From: ztivax!david Mar 4 15:34:00 1986 /* Written 6:57 am Feb 27, 1986 by clif@intelca in ztivax:net.arch */ I will try to keep from flaming, but clif@intelca, your claims are wrong. I do not work in your high performance processor lab, but I sometimes have to write code for those awful things Intel makes. Do not let your loyalties to your employer cloud your thinking. >> ... What usually happens is >> that the 'high level' instruction is not as efficient as a sequence or >> loop of simpler instructions > I am sure no good RISC designer would include such obscure instructions >as Ascii Adjust for Addition, Subtraction, AAA,AAS etc. or XLAT >(Table Look-up Translation). Yes, you are right. This is a perfect example of a useless instruction. If you code the action in low level 80*86 instructions, you will have a faster loop. You may claim that the intruction itself is fast, but look at all that silly setup which must first be done to even use this obscure example of brain damage. > One disagreement I have with the RISC proponents is the theory that > everyone writes in a HLL. It seems that despite years of trying to force > everyone to write in HLL languages there will always be a few assembly > language programers. Because no matter how much performance Semicoducter and > Computer companies give programmers they always want their programs to run > faster. When optimizing code, I, like most others, ahve found that 1) its in the algorithm, not the instructions, and 2) the super whiz-bang instructions are expensive due to special setup and slow hardware / micro-code implementation. And, if I am going to write assembler, I always find it easier and more maintainable if done using a regular orthogonal instruction set, not using the obscure bells and whistes. > So these CISC instructions while not useful to compiler writers are > useful to assembly language jocks. Really? I have found, as well as many others, that assember programmers are like high level language programmers: they use convenient subsets of the language. And for the quick clock times you quote fpr the 80*86 family, you should include all the time it takes to perform the loads of operands into the specific registers required. You will be suprised, and I hope, enlightened. .... End of flame However, cliff, a good question you have implied: Does anyone do assembler programming on RISC machines? For example: Is UNIX on RISC entirely in C? How do the stack recovery mechanisms work? Interrupted / failed instructions? CPU mode register control manipulation (if applicable)? David Smyth, Free and proud of it.