-
Notifications
You must be signed in to change notification settings - Fork 18k
math: add ARM64 implementation of frexp #47589
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
base: master
Are you sure you want to change the base?
Conversation
This PR (HEAD: 9e4a3d8) has been imported to Gerrit for code review. Please visit https://go-review.googlesource.com/c/go/+/340629 to see it. Tip: You can toggle comments from me using the |
This PR (HEAD: bf0f19f) has been imported to Gerrit for code review. Please visit https://go-review.googlesource.com/c/go/+/340629 to see it. Tip: You can toggle comments from me using the |
src/math/frexp_arm64.s
Outdated
SUB $(52), R1, R1 // set R1 to -52 | ||
FMOVD F0, R0 | ||
// tmp = int((x>>shift)&mask) | ||
UBFX $52, R0, $11, R0 |
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.
I am not familiar with it but is it a wrong indent?
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.
Thank you for pointing out. This style twist was causing by space. I have replaced it by tab. Thank you.
This PR (HEAD: 9d8f0be) has been imported to Gerrit for code review. Please visit https://go-review.googlesource.com/c/go/+/340629 to see it. Tip: You can toggle comments from me using the |
This PR (HEAD: 2b942c1) has been imported to Gerrit for code review. Please visit https://go-review.googlesource.com/c/go/+/340629 to see it. Tip: You can toggle comments from me using the |
This PR (HEAD: 24f4cf6) has been imported to Gerrit for code review. Please visit https://go-review.googlesource.com/c/go/+/340629 to see it. Tip: You can toggle comments from me using the |
This PR (HEAD: 544bfa2) has been imported to Gerrit for code review. Please visit https://go-review.googlesource.com/c/go/+/340629 to see it. Tip: You can toggle comments from me using the |
The implementation of Frexp on ARM64 has been implemented in this PR. The following benchmark was run on Apple Silicon M1 chips. BenchmarkArchFrexp-8 1.581 ns/op 0 B/op 0 allocs/op BenchmarkFrexpGO-8 2.079 ns/op 0 B/op 0 allocs/op The time spent on each iteration drop 23.95%.
This PR (HEAD: 92fe95f) has been imported to Gerrit for code review. Please visit https://go-review.googlesource.com/c/go/+/340629 to see it. Tip: You can toggle comments from me using the |
The implementation of Frexp on ARM64 has been implemented in this PR.
The following benchmark was run on Apple Silicon M1 chips.
BenchmarkArchFrexp-8 1.581 ns/op 0 B/op 0 allocs/op
BenchmarkFrexpGO-8 2.079 ns/op 0 B/op 0 allocs/op
The time spent on each iteration drop 23.95%.