-
Notifications
You must be signed in to change notification settings - Fork 450
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[libm] Fix Building For ARM64 & Add Stubs
It really sucks that Apple no longer open sources `libm`... I'm not sure if we should replace `libm` with another macOS friendly math library, or try to implement the math stubs...
- Loading branch information
1 parent
ad810d3
commit 10552e4
Showing
6 changed files
with
111 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
double scalbn(double x, int exp) { | ||
__builtin_trap(); | ||
return 0.0; | ||
} | ||
|
||
float scalbnf(float x, int exp) { | ||
__builtin_trap(); | ||
return 0.0; | ||
} | ||
|
||
long double scalbnl(long double x, int exp) { | ||
__builtin_trap(); | ||
return 0.0; | ||
} | ||
|
||
long double logbl(long double x) { | ||
__builtin_trap(); | ||
return 0.0; | ||
} | ||
|
||
long double nanl(const char *tagp) { | ||
__builtin_trap(); | ||
return 0.0; | ||
} | ||
|
||
double cos(double x) { | ||
__builtin_trap(); | ||
return 0.0; | ||
} | ||
|
||
float cosf(float x) { | ||
__builtin_trap(); | ||
return 0.0; | ||
} | ||
|
||
double pow(double x, double y) { | ||
__builtin_trap(); | ||
return 0.0; | ||
} | ||
|
||
double sin(double x) { | ||
__builtin_trap(); | ||
return 0.0; | ||
} | ||
|
||
float sinf(float x) { | ||
__builtin_trap(); | ||
return 0.0; | ||
} | ||
|
||
double acos(double x) { | ||
__builtin_trap(); | ||
return 0.0; | ||
} | ||
|
||
double asin(double x) { | ||
__builtin_trap(); | ||
return 0.0; | ||
} | ||
|
||
double atan(double x) { | ||
__builtin_trap(); | ||
return 0.0; | ||
} | ||
|
||
double atan2(double y, double x) { | ||
__builtin_trap(); | ||
return 0.0; | ||
} | ||
|
||
double log(double x) { | ||
__builtin_trap(); | ||
return 0.0; | ||
} | ||
|
||
double modf(double value, double *iptr) { | ||
__builtin_trap(); | ||
return 0.0; | ||
} | ||
|
||
double tan(double x) { | ||
__builtin_trap(); | ||
return 0.0; | ||
} | ||
|
||
double fmod(double x, double y) { | ||
__builtin_trap(); | ||
return 0.0; | ||
} | ||
|
||
double log2(double x) { | ||
__builtin_trap(); | ||
return 0.0; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../../../Source/ARM/fenv.h |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../../../Source/ARM/math.h |