Re: declare 64 bit integers?
- From: David Lichteblau <usenet-2006@xxxxxxxxxxxxxx>
- Date: 29 Sep 2007 11:44:58 GMT
On 2007-09-29, Alex Mizrahi <udodenko@xxxxxxxxxxxxxxxxxxxxx> wrote:
NF> The original poster didn't specify what the target machine was
NF> (although it
NF> sounds like he's using a 32-bit machine), but for the record, SBCL on
NF> x86-64
NF> can do unboxed operations on 64-bit integers just like Java or C++.
just of curiosity -- this is how?
* (log most-positive-fixnum 2)
60.0
so fixnums are just 61 bit wide, that's not interesting. how to declare
64-bit interger value?
Matthias Benkard already answered your question in this thread, but I
will give you the benefit of the doubt and assume that you are asking
about how unboxed operations on 64-bit integers work, rather than the
type declaraton itself.
Here is what SBCL can do:
- The compiler can perform unboxed operations on register-sized
integers within a function, given suitable type declarations.
- Specialized arrays store their elements unboxed.
- With a suitable type declaration, structure slots are also stored "raw".
The complications, on the other hand, are:
- no unboxed arguments across full function calls
- type declarations are often good enough as "hints" for
representation selection about your data, but sometimes things go
wrong and the compiler will end up converting between tagged and
untagged representation for no good reason, which can end up being
more expensive than doing a tagged operation would have been
.
- Follow-Ups:
- Re: declare 64 bit integers?
- From: Alex Mizrahi
- Re: declare 64 bit integers?
- References:
- declare 64 bit integers?
- From: jrwats
- Re: declare 64 bit integers?
- From: Alex Mizrahi
- Re: declare 64 bit integers?
- From: Nathan Froyd
- Re: declare 64 bit integers?
- From: Alex Mizrahi
- declare 64 bit integers?
- Prev by Date: ANNOUNCE: CL-SQS, an interface to Amazon SQS
- Next by Date: Re: declare 64 bit integers?
- Previous by thread: Re: declare 64 bit integers?
- Next by thread: Re: declare 64 bit integers?
- Index(es):
Relevant Pages
|