ocramz / xeno

Fast Haskell XML parser
Other
120 stars 33 forks source link

Swap out `mutable-containers` dependency for `unboxed-ref` #63

Closed mitchellwrosen closed 1 year ago

mitchellwrosen commented 1 year ago

Hi! I've prepared a PR to swap out the mutable-containers dependency for unboxed-ref, in case the maintainers here are interested.

The primary motivation is to reduce the dependency footprint.

Before:

image

After:

image

Although the unboxed-ref source has not been touched in 5+ years, I checked out the implementation and it looks solid. It also doesn't have any out-of-date dependencies on Hackage.

ocramz commented 1 year ago

@mitchellwrosen this is a good change, did you also look at the respective benchmarks? since xeno is supposed to be performance-oriented, I mean.

mitchellwrosen commented 1 year ago

Unfortunately I did not, but I think they should remain unchanged since the implementation of unboxed refs is the same (using a one-element MutableByteArray#).

The benchmarks seem to require an expat system library, and I don't know what that is :sweat_smile:

mitchellwrosen commented 1 year ago

@ocramz Were you waiting to confirm that benchmarks haven't moved before merging?

ocramz commented 1 year ago

I kind of was! TBH haven't even had the time to try this out.

On Fri, 24 Feb 2023 at 21:03, Mitchell Rosen @.***> wrote:

@ocramz https://github.com/ocramz Were you waiting to confirm that benchmarks haven't moved before merging?

— Reply to this email directly, view it on GitHub https://github.com/ocramz/xeno/pull/63#issuecomment-1444378307, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABNBDKAJJJPJFSQMFHC37HDWZEHYBANCNFSM6AAAAAASQ76LWQ . You are receiving this because you were mentioned.Message ID: @.***>

mitchellwrosen commented 1 year ago

Ok. Well, I'm unfortunately not able to run the benchmarks, so feel free to close or merge whenever you are comfortable.