Add some more functions to the math library #213
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hello guys,
To make the porting of the NES emulator possible, I needed a few math operations (log(), sqrt(), pow() and scalbn()) that are not available in the mainline HelenOS tree.
Manuele copied part of the msun math library (BSD-like licensed, very permissive) and then I synced it to a recent version of the FreeBSD src tree.
I am 100% aware that you don't like to merge code coming from other projects, yet this code was rotting in my private branch and I opened this pull request just to make you aware that some work has been done in this area. I'm not asking to merge it right now, it may become useful in future.
Note: I had to fix a "comparison between signed and unsigned integers" warning that prevented the code from successfully building. I think my patch is safe, but requires some careful review... because all of this math code looks like black magic to me.