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 fma in SimdOps.cosineSimilarity sum vector #363

Merged
merged 1 commit into from
Oct 9, 2024
Merged

Conversation

jkni
Copy link
Collaborator

@jkni jkni commented Oct 9, 2024

This better matches the structure we use in other places, and I suspect it may make work slightly easier for C2 in some cases that I'm debugging.

@jkni jkni requested a review from jbellis October 9, 2024 15:49
@jkni jkni merged commit fc708af into main Oct 9, 2024
6 checks passed
@jkni jkni deleted the use-fma-in-cosine branch October 9, 2024 16:40
@AbhijitKulkarni1
Copy link

Hi @jkni, to ensure code consistency, suggest to apply the same code change to the cosineSimilarity method in VectorSimdOps.java (io.github.jbellis.jvector.vector.VectorSimdOps#cosineSimilarity) as well.

@jkni
Copy link
Collaborator Author

jkni commented Nov 4, 2024

@AbhijitKulkarni1 that's a good suggestion -- I'll put up a PR. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants