-
Notifications
You must be signed in to change notification settings - Fork 81
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
add dot_product example #128
Conversation
Failure on |
I think this is good to merge. Any objections @workingjubilee ? |
Todo:
|
With #138 that is now unblocked~ |
I believe this can proceed if it is rebased/updated, with a minimal effort. @miguelraz Would you like to do so? |
cc78a1c
to
ab8eec7
Compare
Alright, I think I have some bandwidth now... once more unto the breach my friends! 🎉 |
I've addressed all of my |
@calebzulawski This should be good to go now. |
Would you kindly rebase commit miguelraz@340491b out of existence? |
cleanup dot_product and README.md
allocating fold with std::ops::Add::add
ddbc8a8
to
64247a3
Compare
// TODO handle remainder when a.len() % 4 != 0 | ||
a.array_chunks::<4>() | ||
.map(|&a| f32x4::from_array(a)) | ||
.zip(b.array_chunks::<4>().map(|&b| f32x4::from_array(b))) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this could use slice::as_simd
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is that better codegen?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
probably, but i was more thinking that it's the function designed to split a slice into simd chunks, so we should use it instead of going through arrays.
Scratching this off the #110 list.
Special thanks to @Lokathor, @workingjubilee and the Zulip chat for answering questions on this one.