-
Notifications
You must be signed in to change notification settings - Fork 4
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
Make whole crate no_std compatible #50
Conversation
There is only one thing currently not working which is f64::log2 not being found by the compiler in no_std mode which is a rather strange bug.
Codecov Report
@@ Coverage Diff @@
## master #50 +/- ##
==========================================
- Coverage 76.03% 75.88% -0.16%
==========================================
Files 22 22
Lines 5345 5340 -5
==========================================
- Hits 4064 4052 -12
- Misses 1281 1288 +7
Continue to review full report at Codecov.
|
It still needs to be turned on whenever building for no_std.
I am pretty sure it is faster and safer to do something like |
Please file a PR to improve upon this PR. But whenever you make performance-PRs please file an associated benchmark to prove that we are not pulling in premature optimizations or even general pessimizations. |
Also, you might want to compare with how I originally updated the rand file. The test also uses an outside crate for pseudorandom tests.
|
Could you please file a single-purpose PR to improve upon this? Thanks! |
There is only one thing currently not working which is
f64::log2
not being found by the compiler inno_std
mode which is a rather strange bug.The error looks like:
Needs further investigation.
edit:
Turns out the above error is a result of rust-lang/rfcs#2505.
So we have several options to continue:
std
-only functions, remove all old code that depends on it which is fortunately just this one instance as far as it seems.libm
to be able to continue depending on these functions. Note thatlibm
does not provide the best possible performance.