-
Notifications
You must be signed in to change notification settings - Fork 160
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
feat(tfhe): replace asm with rust intrinsics #1491
Conversation
92c4cb5
to
4d6ccfb
Compare
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.
Thanks, just a few questions, I might be misremembering some things
// SAFETY: simd contains an instance of avx512dq, that matches the target feature of | ||
// `implementation` | ||
unsafe { implementation(x) } | ||
_ = simd; | ||
unsafe { _mm512_cvttpd_epi64(x) } |
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 this going to get inlined if we don't have the target feature on the function itself ?
also could we maybe replace our function call by this intrinsics directly ?
last question, I think you said you had an improvement in performance by changing the conversion function ? here it seems it's the same ?
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.
should get inlined if it works like the other intrinsics.
i also figured I'd leave the instruction change for a separate pr
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.
sounds good then !
// SAFETY: simd contains an instance of avx512dq, that matches the target feature of | ||
// `implementation` | ||
unsafe { implementation(x) } | ||
_ = simd; | ||
unsafe { _mm512_cvtepi64_pd(x) } |
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.
same questions here :)
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.
Thanks a lot :)
closes: please link all relevant issues
PR content/description
Check-list: