Rename data segment symbols, to avoid system library overrides#1184
Rename data segment symbols, to avoid system library overrides#1184
Conversation
|
Can we be sure that those error conditions can't conflict with existing symbols from |
|
@larskuhtz Ok, I've renamed them all: Also, the |
|
I am somewhat concerned about conflicts when the system Some macros definitions in I think we should at least make sure that the environment can't overwrite definitions in our I am not 100% sure how justified this concern is. It seems that the content of |
|
Also, this PR is an alternative to #1177, at least for fixing the GHC 9.6 build failure. There are other aspects of that PR that we'd like to include, but as a separate step to fixing the underlying issue. |
|
@larskuhtz I don't quite understand your reticence with the locally provided |
|
The definitions in @jwiegley From inspecting the code it seems that unexpected definitions of above headers would likely either be redundant for our code or just cause compilation failures. But I am not an expert regarding these details of C implementations. If you think, that this isn't an issue and doesn't affect us, I am happy to approve this PR. (I think, it would be good to isolate the code into an sub library and also to include the unit tests from #1177 for better maintainability and easier debugging of issues.) |
|
@larskuhtz I'm not very worried about I'd say let's get this in, fix your GHC 9.6 issue, and then once that is done I'd like to look at your restructuring code in more depth. After all, it may be that now is the time to embrace full Haskell implementations of these functions, or move to MPFR, rather than improving Musl. I still don't know why Musl fails Pact tests on Ubuntu/ARM64, but I'm going to try with this patch to see if what you ran into was the cause over there as well. |
On macOS, GHC 9.6 gives incorrect answers for transcendental functions, due to symbol overriding that happens from the math library. This PR fixes that problem with a simple alpha substitution.
Here is the total quantity of symbols in use by the Musl code; all of the rest that were not renamed are error conditions: