[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

*To*: mitccc!common-lisp%SU-AI%mc@angel.ARPA*Subject*: FIXNUM considered unportable*From*: George Carrette <lmi-angel!gjc%LMI-ANGEL.ARPA>*Date*: Fri, 25 Jul 1986 18:39:00 -0000

What all this discussion says to me as a compiler implementor is that I should give a warning when somebody uses type FIXNUM. Ah, but show now I can think of a use of type FIXNUM from MACSYMA (DOE-MACSYMA, CL-MACSYMA whatever), and it seems quite reasonable. Given that we know that fixnum operations are more efficient than non-fixnum we choose to do our math modulo various prime numbers that fit in a fixnum. Macsyma has a list of the 10 or so bigest primes that fit in a fixnum for each machine it runs on, and/or it can compute these on the fly, using the (LSH -1 -1) idiom (or other more common-lisp ways of finding the greatest fixnum). Well, thats part of the justification, the code would look something like: (COND ((TYPEP *MODULUS* 'FIXNUM) (LET () (DECLARE (FIXNUM *MODULUS*)) ....frob... frob... frob...)) ('ELSE ..... frob ... frob ...))

- Prev by Date:
**Proposal #13: Structure Sharing in Arguments** - Next by Date:
**Re: Proposal #13: Structure Sharing in Arguments** - Previous by thread:
**Proposal #13: Structure Sharing in Arguments** - Next by thread:
**[no subject]** - Index(es):