mirror of
https://frontier.innolan.net/github/amigaos-cross-toolchain6.git
synced 2024-10-19 10:29:55 +00:00
@T more tests
This commit is contained in:
Executable
+14
@@ -0,0 +1,14 @@
|
||||
typedef float SFtype __attribute__ ((mode (SF)));
|
||||
SFtype
|
||||
__powisf2 (SFtype x, int m)
|
||||
{
|
||||
unsigned int n = m < 0 ? -m : m;
|
||||
SFtype y = n % 2 ? x : 1;
|
||||
while (n >>= 1)
|
||||
{
|
||||
x = x * x;
|
||||
if (n % 2)
|
||||
y = y * x;
|
||||
}
|
||||
return m < 0 ? 1/y : y;
|
||||
}
|
||||
Reference in New Issue
Block a user