From ... Path: archiver1.google.com!newsfeed.google.com!sn-xit-02!supernews.com!newsfeed.direct.ca!look.ca!newsfeed.icl.net!newsfeed.esat.net!nslave.kpnqwest.net!nloc2.kpnqwest.net!nmaster.kpnqwest.net!nreader2.kpnqwest.net.POSTED!not-for-mail Newsgroups: comp.lang.lisp Subject: Re: EQ and FIXNUMS References: <3BAEF9CF.8AD3D2CB@eurocom.od.ua> <9opk64$mk5tp$1@fido.engr.sgi.com> <87g09bpejg.fsf@kometknut.neitileu.no> Mail-Copies-To: never From: Erik Naggum Message-ID: <3210416436649880@naggum.net> Organization: Naggum Software, Oslo, Norway Lines: 19 User-Agent: Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Tue, 25 Sep 2001 14:20:37 GMT X-Complaints-To: newsmaster@Norway.EU.net X-Trace: nreader2.kpnqwest.net 1001427637 193.90.207.32 (Tue, 25 Sep 2001 16:20:37 MET DST) NNTP-Posting-Date: Tue, 25 Sep 2001 16:20:37 MET DST Xref: archiver1.google.com comp.lang.lisp:16896 * Erik Haugan > Anyway, since EQ is so cheap, I'm not sure it matters. eq is so cheap that it makes sense to inline a call to eq (i.e., make the direct machine-word comparison) and then call out to a function like eql-not-eq, which knows the values are not eq, to make the more complex comparison. However, since the only relevant point of difference between eql and eq in the usual modern implementations is when comparing numbers with eachother, it might also make sense to limit testing to them and avoid the cost of a function call for other types. I imagine that an implementation could optimize this very heavily with clever use of type codes if it really wanted to. /// -- Why did that stupid George W. Bush turn to Christian fundamentalism to fight Islamic fundamentalism? Why use terms like "crusade", which only invokes fear of a repetition of that disgraceful period of Christianity with its _sustained_ terrorist attacks on Islam? He is _such_ an idiot.