09 Sep 2026 Test of modified glibc sin(x) and cos(x) library function source files, modified for use with standalone programs compiled with gcc and in sc.exe (Digital Mars C/C++ v8.51n). See build instructions in the respective src/gcc and src/sc directories. glibc source files: https://github.com/bminor/glibc glibc version: 2.42.9000 Test wrapper output (test_sincos.c) for sin(x) and cos(x) from gcc and sc.exe compilers is given below for comparison. We use hex output for comparison of the double-precision sin() and cos() outputs because sc.exe only provides accuracy to 17 decimal digits for double-precision (binary64) values. All arguments, x, used in these tests are exactly represented in IEEE 754 double-precision format. sin(x) comparisons x sin(x) gcc Linux sin(x) sc.exe Win32 ----------------------------------------------------------- 7.62939453125e-06 fffeaaab 3edfffff fffeaaab 3edfffff 6.103515625e-05 ffaaaaab 3f0fffff ffaaaaab 3f0fffff 2.44140625e-04 faaaaaab 3f2fffff faaaaaab 3f2fffff 3.90625e-03 aaaaeeef 3f6ffffa aaaaeeef 3f6ffffa 3.125e-02 aeeee86f 3f9ffeaa aeeee86f 3f9ffeaa 1.25e-01 ee86ee36 3fbfeaae ee86ee36 3fbfeaae x sin(x) gcc Linux sin(x) sc.exe Win32 -------------------------------------------------- 1e+00 8f090cee 3feaed54 8f090cee 3feaed54 1e+01 f5f34f52 bfe1689e f5f34f52 bfe1689e 1e+02 b78c4db8 bfe03425 b78c4db8 bfe03425 1e+03 150a206b 3fea75cc 150a206b 3fea75cc 1e+04 a75d9289 bfd38f2f a75d9289 bfd38f2f 1e+05 9c527e96 3fa24daa 9c527e96 3fa24daa 1e+06 2568d867 bfd6664b 2568d867 bfd6664b 1e+07 4a8a3352 3fdaea41 4a8a3352 3fdaea41 1e+08 a623a20b 3fedcffc a623a20b 3fedcffc 1e+09 ae83c69b 3fe1778c ae83c69b 3fe1778c 1e+10 7896a4e3 bfdf334c 7896a4e3 bfdf334c 1e+11 c47abb83 3fedb7db c47abb83 3fedb7db 1e+12 77984352 bfe38f44 77984352 bfe38f44 1e+13 bf625778 bfd27d18 bf625778 bfd27d18 1e+14 341a9ee7 bfcacde4 341a9ee7 bfcacde4 1e+15 8136ceba 3feb76f8 8136ceba 3feb76f8 1e+16 432ebba5 3fe8f334 432ebba5 3fe8f334 1e+17 7a119fc8 bfddbadc 7a119fc8 bfddbadc 1e+18 98d05d2e bfefc667 98d05d2e bfefc667 1e+19 5f702a5c bfedaa80 5f702a5c bfedaa80 1e+20 05fd6450 bfe4a5e6 05fd6450 bfe4a5e6 1e+21 69e0cddf bfe5590c 69e0cddf bfe5590c 1e+22 b76bf397 bfeb453a b76bf397 bfeb453a cos(x) comparisons x cos(x) gcc Linux cos(x) sc.exe Win32 ----------------------------------------------------------- 7.62939453125e-06 fffc0000 3fefffff fffc0000 3fefffff 6.103515625e-05 ff000000 3fefffff ff000000 3fefffff 2.44140625e-04 f0000001 3fefffff f0000001 3fefffff 3.90625e-03 00015555 3feffff0 00015555 3feffff0 3.125e-02 155527d3 3feffc00 155527d3 3feffc00 1.25e-01 527d5bd3 3fefc015 527d5bd3 3fefc015 x cos(x) gcc Linux cos(x) sc.exe Win32 -------------------------------------------------- 1e+00 0fb5068c 3fe14a28 0fb5068c 3fe14a28 1e+01 890c6b1f bfead9ac 890c6b1f bfead9ac 1e+02 bf665fdf 3feb981d bf665fdf 3feb981d 1e+03 6793f1bb 3fe1ff02 6793f1bb 3fe1ff02 1e+04 88ec4409 bfee780e 88ec4409 bfee780e 1e+05 841b3da7 bfeffac3 841b3da7 bfeffac3 1e+06 9906d32c 3fedf9df 9906d32c 3fedf9df 1e+07 e7a8f4a1 bfed085b e7a8f4a1 bfed085b 1e+08 88a8c029 bfd741b3 88a8c029 bfd741b3 1e+09 c7364234 3feacff8 c7364234 3feacff8 1e+10 901c931a 3febf098 901c931a 3febf098 1e+11 60c90a11 3fd7bbf8 60c90a11 3fd7bbf8 1e+12 31dff223 3fe95387 31dff223 3fe95387 1e+13 3bceea60 3feea2b9 3bceea60 3feea2b9 1e+14 8cbdb66a bfef4a5e 8cbdb66a bfef4a5e 1e+15 4609d33f bfe06c15 4609d33f bfe06c15 1e+16 e398dbfc bfe40991 e398dbfc bfe40991 1e+17 5278afcb bfec567c 5278afcb bfec567c 1e+18 72c0759a 3fbe4da0 72c0759a 3fbe4da0 1e+19 40949636 bfd7fe72 40949636 bfd7fe72 1e+20 0fc60d3d 3fe87272 0fc60d3d 3fe87272 1e+21 9e03cfa6 3fe7d6a1 9e03cfa6 3fe7d6a1 1e+22 ef01c8f4 3fe0be2c ef01c8f4 3fe0be2c