Subject: Re: Performance tuning
From: Erik Naggum <erik@naggum.net>
Date: 07 Dec 2000 16:16:02 +0000
Newsgroups: comp.lang.lisp
Message-ID: <3185194562763651@naggum.net>

* Dr Nick Levine <n.levine@anglia.ac.uk>
| The language model would have to be changed more than somewhat for the
| value of x to be changed. [Effectively, CL always passes numbers and
| characters "by value" and everything else "by reference".]

  That's not really so.  That's the catch with bignums.  They don't get
  copied (effectively) when you pass them around, and they cons a _lot_
  when they are copied, to there are good reasons to reuse them.  I
  think dpb would be the one operator that it would make sense to let
  reuse the bignum.  Its semantics _is_ to deposit bits into an existing
  number.

| Also, if the zero was destructively modified, how many other zeros
| would also change?  What would happen to zerop? Ouch!

  Zero wouldn't magically become a bignum any time soon, would it?

| It's also unnerving to think of code whose semantics (as opposed to
| efficiency) changes when you pass through the fixnum/bignum boundary.

  And what semantic changes would that really be?  I see fear but little
  technical argumentation, especially considering the weird non-issue
  with zero that you bring up.  What's really on your mind?

#:Erik
-- 
  "When you are having a bad day and it seems like everybody is trying
   to piss you off, remember that it takes 42 muscles to produce a
   frown, but only 4 muscles to work the trigger of a good sniper rifle."
								-- Unknown