Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/18/84 exptools; site ihwpt.UUCP Path: utzoo!watmath!clyde!burl!ulysses!mhuxr!mhuxn!ihnp4!ihwpt!knudsen From: knudsen@ihwpt.UUCP (mike knudsen) Newsgroups: net.micro.6809 Subject: Don't use C "register" Message-ID: <593@ihwpt.UUCP> Date: Sat, 30-Nov-85 15:54:25 EST Article-I.D.: ihwpt.593 Posted: Sat Nov 30 15:54:25 1985 Date-Received: Sun, 1-Dec-85 03:40:54 EST Distribution: net Organization: AT&T Bell Laboratories Lines: 20 The dhrystone benchmarks just posted have re-discovered what I've suspected all along: namely "registers" do no good, and may do harm, in MW C for the 6809! Reason: the U Reg is simply substituted for a RAM location, so the LD's and STD's become TFR's. TFR is the slowest instruction in the 6809 set. It is quicker to move to/from RAM (in almost any addressing mode) than to TFR between two regs. If you "reg" a *int, MW C still TFR's it to X to do the indexing. (And incrementing, if needed). Then TFRs back to U. AAAgh! No ethinic jokes, please-- but you've been warned! You want speed -- declare everything "direct extern" except arrays! mike k PS: My own "sieve" tests last year made me suspicious enough to look at the assembly code.