cisco / ChezScheme

Chez Scheme
Apache License 2.0
6.97k stars 983 forks source link

provide control over transcoded-port buffer sizes #708

Closed owaddell closed 1 year ago

owaddell commented 1 year ago

This pull request adds two new parameters that provide control over the size of the string buffer and the internal codec bytevector buffer associated with transcoded ports. It also includes changes to reduce allocation and copying in certain cases for bytevector->string, get-bytevector-all, get-bytevector-n, get-string-all, and get-string-n.

One use case for the new parameters is to allow transcoded custom binary ports to take advantage of larger buffer sizes. Previously, such ports were effectively constrained by a fixed 1024-byte internal codec buffer even if created with a large custom-port-buffer-size.

Resolved questions:

jltaylor-us commented 1 year ago

Looks good to me.

owaddell commented 1 year ago

Thanks for the reviews, folks!