Re: big strings

[email protected] (Raymond Toy (RT/EUS))
Newsgroups gmane.lisp.cmucl.general
Message-ID <[email protected]>
>>>>> "WP" == Walter C Pelissero <[email protected]> writes:

    WP> Raymond Toy (RT/EUS) writes:
    >> Thanks for the replacement.  The only possible issue with the
    >> replacement would be performance.  BIT-BASH-COPY tries pretty hard
    >> to do word copies.  And BIT-BASH-COPY is intended to be able to
    >> copy arbitrary bit strings.  I don't know why it's limited to
    >> (unsigned-byte 27) offsets.  Perhaps to make sure the bit index
    >> stays as a 32-bit int?

    WP> This is what came to mind reading the error.  What I didn't understand
    WP> is why we get an error at all, being:

    WP>  2^27 > 17M   (way larger)

But the 17M is converted to a bit index and the bit index is greater
than 2^27.

As an experiment, I changed the constant max-bits in
code/bit-bash.lisp from 2^27 to most-positive-fixnum.  The comment
there says it's the maximum number of bits that can be delt [sic] with
during a single call.  I don't see why it can't really handle at least
most-positive-fixnum number of bits or even #xffffffff number of bits.

This compiles everything and your test function finishes fine.

I think I'll do a few more tests on this.

Ray
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.