Xref: utzoo comp.lang.c:38341 alt.folklore.computers:11022 Path: utzoo!utgpu!cs.utexas.edu!sdd.hp.com!spool.mu.edu!news.cs.indiana.edu!ux1.cso.uiuc.edu!news.iastate.edu!du248-09.cc.iastate.edu!mehl From: mehl@iastate.edu (Mark M Mehl) Newsgroups: comp.lang.c,alt.folklore.computers Subject: Re: difference between c++; and ++c; Message-ID: Date: 17 Apr 91 02:00:33 GMT References: <1991Apr08.161444.10025@cs.ruu.nl> <1991Apr11.151933.25867@ingres.Ingres.COM> <1991Apr12.100933.2854@tkou02.enet.dec.com> Sender: news@news.iastate.edu (USENET News System) Followup-To: comp.lang.c Organization: Dept of EE/CprE -- IOWA STATE UNIV Lines: 35 >In article <1991Apr11.151933.25867@ingres.Ingres.COM> mikes@ingres.com (Mike Schilling) writes: >>We old folks use: >> c++; >> --c; In <1991Apr12.100933.2854@tkou02.enet.dec.com> diamond@jit345.swstokyo.dec.com (Norman Diamond) writes: >Some of us older folks didn't want to bother learning PDP-11 machine language, >and DIDN'T learn to do it that way! Note that both the PDP-11 and Motorola 6809 processors do _not_ have a pre-incrementing addressing mode or a post-decrementing addressing mode; however, these processors do support post-inc and pre-dec addressing modes. As a result, it's _likely_ that: c++ maybe much faster than ++c and --c maybe much faster than c-- for these two processors since they lack the required addressing modes for the latter. (Has anyone check this out?) Since the modern CISC processor supports all possible permutations of pre/post inc/decrementation addressing modes, I doubt there would be much difference. RISC processors (like the dual X,Y auto-indexing performed by vector-orientated machines, e.g. DSP processors) maybe a different story of course. Followups back to comp.lang.c -- /\ Mark M Mehl, alias Superticker (Supertickler to some) <><> Internet: mehl@IAstate.edu \/ Preferred UUCP: uunet!iastate.edu!mehl Disclaimer: You got to be kidding; who would want to claim anything I said?