Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use the retain_mut external library #90

Merged
merged 1 commit into from
Feb 20, 2021
Merged

Use the retain_mut external library #90

merged 1 commit into from
Feb 20, 2021

Conversation

Kerollmops
Copy link
Member

@Kerollmops Kerollmops commented Feb 20, 2021

Related to #87 but do not fix it yet.

Thanks to @upsuper and its retain_mut library, we can remove our internal copy of the std retain function and let it be maintained externally (until retain_mut is merged into the std).

@Kerollmops
Copy link
Member Author

bors r+

bors bot added a commit that referenced this pull request Feb 20, 2021
89: Improve unions between arrays r=Kerollmops a=Kerollmops

I found out that merging two arrays was quite slow while benchmarking our new search engine. Doing unions of array containers needed improvement. I reworked the algorithm to make it easier to read and removed the inserts triggering a lot of useless memory copy, and made it write into a new allocation.

I found out that CRoaring (which is the roaring implementation in c) [was doing a lot SIMD based things to do fast array unions](https://github.com/RoaringBitmap/CRoaring/blob/63a54b15df3bc8fad77a9cc26fbc2dcce5f8da23/src/array_util.c#L1894-L1915), I did not implement them because it would take me a lot of time and that I would prefer using the, soon to be released, [stdsimd library](https://github.com/rust-lang/stdsimd).

90: Use the retain_mut external library r=Kerollmops a=Kerollmops

Related to #87 but do not fix it yet.

Thanks to @upsuper and its [retain_mut library](https://docs.rs/retain_mut), we can remove our internal copy of the [std `retain` function](https://doc.rust-lang.org/std/vec/struct.Vec.html#method.retain) and let it be maintained externally (until `retain_mut` is merged into the std).

Co-authored-by: Clément Renault <clement@meilisearch.com>
@bors
Copy link
Contributor

bors bot commented Feb 20, 2021

Build failed (retrying...):

bors bot added a commit that referenced this pull request Feb 20, 2021
90: Use the retain_mut external library r=Kerollmops a=Kerollmops

Related to #87 but do not fix it yet.

Thanks to @upsuper and its [retain_mut library](https://docs.rs/retain_mut), we can remove our internal copy of the [std `retain` function](https://doc.rust-lang.org/std/vec/struct.Vec.html#method.retain) and let it be maintained externally (until `retain_mut` is merged into the std).

Co-authored-by: Clément Renault <clement@meilisearch.com>
@bors
Copy link
Contributor

bors bot commented Feb 20, 2021

Canceled.

@Kerollmops
Copy link
Member Author

bors r+

@bors
Copy link
Contributor

bors bot commented Feb 20, 2021

Build succeeded:

@bors bors bot merged commit 13d16b3 into master Feb 20, 2021
@bors bors bot deleted the external-retain-mut branch February 20, 2021 19:06
not-jan pushed a commit to not-jan/roaring-rs that referenced this pull request Aug 31, 2022
89: Improve unions between arrays r=Kerollmops a=Kerollmops

I found out that merging two arrays was quite slow while benchmarking our new search engine. Doing unions of array containers needed improvement. I reworked the algorithm to make it easier to read and removed the inserts triggering a lot of useless memory copy, and made it write into a new allocation.

I found out that CRoaring (which is the roaring implementation in c) [was doing a lot SIMD based things to do fast array unions](https://github.com/RoaringBitmap/CRoaring/blob/63a54b15df3bc8fad77a9cc26fbc2dcce5f8da23/src/array_util.c#L1894-L1915), I did not implement them because it would take me a lot of time and that I would prefer using the, soon to be released, [stdsimd library](https://github.com/rust-lang/stdsimd).

90: Use the retain_mut external library r=Kerollmops a=Kerollmops

Related to RoaringBitmap#87 but do not fix it yet.

Thanks to @upsuper and its [retain_mut library](https://docs.rs/retain_mut), we can remove our internal copy of the [std `retain` function](https://doc.rust-lang.org/std/vec/struct.Vec.html#method.retain) and let it be maintained externally (until `retain_mut` is merged into the std).

Co-authored-by: Clément Renault <clement@meilisearch.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant