[r6rs-discuss] [Formal] bytevector aliasing severely impedes
William D Clinger
will at ccs.neu.edu
Mon Mar 5 10:36:48 EST 2007
I am posting this as an individual member of the Scheme
community. I am not speaking for the R6RS editors, and
this message should not be confused with the editors'
eventual formal response.
Brad Lucier wrote:
> I presume that many people might want to use bytevectors as described
> in this report to increase computational speed and decrease memory
> requirements by avoiding boxing/unboxing of objects that might
> otherwise be boxed when held in generic vectors.
Me too. I have been assuming that someone would write
a SRFI for type-specific numeric vectors together with
a portable R6RS reference implementation using bytevectors
encapsulated within records.
If you or I were to write that SRFI, it would solve the
aliasing problem without even having to mention it. In
theory, compilers could optimize the portable reference
implementation; in practice, it might be easier for a
compiler to optimize the SRFI using the compiler's own
representation, but the reference implementation would
still have conceptual value and would reduce the burden
on implementors who don't care to optimize such things.
So I'm wondering why this needs to be part of the R6RS
instead of being a SRFI.
More information about the r6rs-discuss